Getting the latest version via script?

HI

Is there a link to the latest binaries without versioning? I cant update syncthing under arm on Android because it seems like Go has issues with dns therefor cant update itselfs so I want to script it out but I all the links I see are versioned which makes it hard to guess the current version.

thanks

If you are running the Android app, there is no way to update Syncthing seperately. You will have to wait for the next app update.

Also, our DNS patch for Android does not support IPv6, which means you can’t connect to IPv6 announce servers. But this shouldn’t be a problem in practice.

I am not using the Android app, I am using the arm build binary (from Github release) on Android.

Then you’re probably running into the same problem we have, Go doesn’t support DNS on Android. You can extract the patched binary from an apk, or build it yourself.

You’ll need to parse some JSON to get at the latest version.

https://docs.syncthing.net/users/faq.html#where-do-i-find-the-latest-release

We proxy the API for the internal upgrades, so https://upgrades.syncthing.net/meta.json always contains the description of the latest few releases.

thanks guys. I think I will go with calmh’s solution.

How do I use the json method? It seems binary :frowning:

Ok I devised a homebrew script and it seems to work for me. This is for Termux on Android.

PARSE=`curl https://api.github.com/repos/syncthing/syncthing/releases/latest |grep -i arm- |grep -i download |egrep -o 'https?://[^ ")]+'`

killall syncthing 
pkill syncthing

cd "/data/data/com.termux/files/opt/syncthings"

rm -fv *tar.gz* 
aria2c $PARSE 
tar --overwrite --strip-components=1 -xvf *.tar.gz 
rm -fv *tar.gz* && 
chmod 777 syncthing

try jq to address json_path to your json

example: https://github.com/lkwg82/h2o.docker/blob/master/check_releases.sh#L29

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.