mirror of
https://github.com/mudler/LocalAI.git
synced 2024-12-25 23:31:04 +00:00
10 lines
223 B
Bash
10 lines
223 B
Bash
|
#!/bin/bash
|
||
|
set -xe
|
||
|
REPO=$1
|
||
|
BRANCH=$2
|
||
|
VAR=$3
|
||
|
|
||
|
LAST_COMMIT=$(curl -s -H "Accept: application/vnd.github.VERSION.sha" "https://api.github.com/repos/$REPO/commits/$BRANCH")
|
||
|
|
||
|
sed -i Makefile -e "s/$VAR?=.*/$VAR?=$LAST_COMMIT/"
|