aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scripts/install4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/install b/scripts/install
index ebe4569..1634c52 100644
--- a/scripts/install
+++ b/scripts/install
@@ -95,9 +95,11 @@ CLONECOMMANDS
# Switch branch to tagged release
cd $final_path/live
+url=$(curl -s https://api.github.com/repos/tootsuite/mastodon/releases/latest | sort -r | head -1 | cut -d\" -f4)
+version=$(echo $url | cut -d/ -f8)
sudo su - $app <<SWITCHCOMMANDS
pushd ~/live
-git checkout $(git tag | tail -n 1)
+git checkout $version
SWITCHCOMMANDS
# Be king rewind (/var/cache/yunohost/from_file/scripts)