mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-04-27 07:50:16 +00:00
GoMFT: Fix release archive naming (#3483)
* Fix release archive naming * No uses curl to fetch release * typo * Update * Update
This commit is contained in:
parent
121577c2fd
commit
09e7593734
@ -28,7 +28,7 @@ function update_script() {
|
|||||||
msg_error "No ${APP} Installation Found!"
|
msg_error "No ${APP} Installation Found!"
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/StarFleetCPTN/GoMFT/releases/latest | grep "tag_name" | awk '{print substr($2, 4, length($2)-5) }')
|
RELEASE=$(curl -fsSL https://api.github.com/repos/StarFleetCPTN/GoMFT/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
if ! dpkg -l | grep -q "^ii.*build-essential"; then
|
if ! dpkg -l | grep -q "^ii.*build-essential"; then
|
||||||
$STD apt-get install -y build-essential
|
$STD apt-get install -y build-essential
|
||||||
fi
|
fi
|
||||||
@ -41,9 +41,9 @@ function update_script() {
|
|||||||
msg_info "Updating $APP to ${RELEASE}"
|
msg_info "Updating $APP to ${RELEASE}"
|
||||||
rm -f /opt/gomft/gomft
|
rm -f /opt/gomft/gomft
|
||||||
temp_file=$(mktemp)
|
temp_file=$(mktemp)
|
||||||
wget -q "https://github.com/StarFleetCPTN/GoMFT/archive/refs/tags/v${RELEASE}.tar.gz" -O $temp_file
|
curl -fsSL "https://github.com/StarFleetCPTN/GoMFT/archive/refs/tags/v.${RELEASE}.tar.gz" -o $temp_file
|
||||||
tar -xzf $temp_file
|
tar -xzf $temp_file
|
||||||
cp -rf GoMFT-${RELEASE}/* /opt/gomft
|
cp -rf GoMFT-v.${RELEASE}/* /opt/gomft
|
||||||
cd /opt/gomft
|
cd /opt/gomft
|
||||||
$STD go mod download
|
$STD go mod download
|
||||||
$STD go install github.com/a-h/templ/cmd/templ@latest
|
$STD go install github.com/a-h/templ/cmd/templ@latest
|
||||||
|
@ -34,10 +34,10 @@ msg_ok "Setup Golang"
|
|||||||
|
|
||||||
msg_info "Setup ${APPLICATION} (Patience)"
|
msg_info "Setup ${APPLICATION} (Patience)"
|
||||||
temp_file=$(mktemp)
|
temp_file=$(mktemp)
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/StarFleetCPTN/GoMFT/releases/latest | grep "tag_name" | awk '{print substr($2, 4, length($2)-5) }')
|
RELEASE=$(curl -fsSL https://api.github.com/repos/StarFleetCPTN/GoMFT/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
wget -q "https://github.com/StarFleetCPTN/GoMFT/archive/refs/tags/v${RELEASE}.tar.gz" -O $temp_file
|
curl -fsSL "https://github.com/StarFleetCPTN/GoMFT/archive/refs/tags/v.${RELEASE}.tar.gz" -o $temp_file
|
||||||
tar -xzf $temp_file
|
tar -xzf $temp_file
|
||||||
mv GoMFT-${RELEASE}/ /opt/gomft
|
mv GoMFT-v.${RELEASE}/ /opt/gomft
|
||||||
cd /opt/gomft
|
cd /opt/gomft
|
||||||
$STD go mod download
|
$STD go mod download
|
||||||
$STD go install github.com/a-h/templ/cmd/templ@latest
|
$STD go install github.com/a-h/templ/cmd/templ@latest
|
||||||
|
Loading…
x
Reference in New Issue
Block a user