Skip to content

Commit

Permalink
base: allow untagged module installation.
Browse files Browse the repository at this point in the history
`download_github_module` no longer allows only tags for download from
GitHub, but also versions specified by branches or commit hashes. This
makes it possible to download an unreleased (untagged) version of a
module, which applies (a series of) useful bug fixes and patches for our
deploy. Modules that do not use tags for versioning can also be
downloaded with this function now.

When specifying a version through its hash, the complete hash string (41
characters) must be provided due to the default name of directory inside
the archive provided by GitHub.
  • Loading branch information
henriquesimoes authored and ericonr committed Nov 29, 2023
1 parent d569244 commit 9a63e04
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions base/install-functions.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
download_github_module() {
github_org=$1
module_name=$2
tag=$3
commit=$3

lnls-get-n-unpack -l https://github.com/$github_org/$module_name/archive/refs/tags/$tag.tar.gz
lnls-get-n-unpack -l https://github.com/$github_org/$module_name/archive/$commit.tar.gz

mv $module_name-$tag $module_name
mv $module_name-$commit $module_name
}

install_module() {
Expand Down

0 comments on commit 9a63e04

Please sign in to comment.