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

system version fix #829

Merged
merged 1 commit into from
Feb 12, 2025
Merged

system version fix #829

merged 1 commit into from
Feb 12, 2025

Conversation

dayne
Copy link
Contributor

@dayne dayne commented Feb 12, 2025

Checking out dagu and tried using the scripts/installer.sh to download latest release from Dagu Releases

Ran into a few bugs. First, a syntax error, then issues getting the correct URL to download the release file.

Debugging/tested on an Ubuntu 24.10 system.

Syntax issue:

./installer.sh
Downloading the latest binary to the current directory...
Downloading Dagu v1.16.1...
./installer.sh: 43: Bad substitution

Current URL build method

"$RELEASES_URL/download/$VERSION/${FILE_BASENAME}_${VERSION:1}_$(uname -s)_${ARCHITECTURE}.tar.gz" 

The tweaks to get rid of syntax issue & the correct URL for the file on the releases page:

  • $(uname -s) is giving Linux but we need linux (lowercase)
  • ${VERSION:1} is cause of Bad substitution` error.
  • The second VERSION in the file name, not folder, needs to be just the version number without v prefixed, like so: v1.16.1 for folder, but 1.16.1 for the filename.

So, the tweaks are summarized as follows:

SYSTEM=$(uname -s | awk '{print tolower($0)}')
"$RELEASES_URL/download/$VERSION/${FILE_BASENAME}_${VERSION#v}_${SYSTEM}_${ARCHITECTURE}.tar.gz"

Copy link
Collaborator

@yottahmd yottahmd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dayne LGTM, thanks for improving the installation script!

Please let us know if you encounter any issues or find missing features while trying out Dagu!

@yottahmd yottahmd merged commit c449058 into dagu-org:main Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants