Skip to content

Commit

Permalink
Move downloaded file to expected location
Browse files Browse the repository at this point in the history
  • Loading branch information
sarg3nt committed May 25, 2024
1 parent b5d7f20 commit 51f1dda
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
matrix:
os:
- ubuntu-latest
- macos-latest
#- macos-latest
runs-on: ${{ matrix.os }}
steps:
- name: asdf_plugin_test
Expand Down
4 changes: 3 additions & 1 deletion bin/download
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,7 @@ source "${plugin_dir}/lib/utils.bash"

mkdir -p "$ASDF_DOWNLOAD_PATH"

release_file="$ASDF_DOWNLOAD_PATH/$TOOL_NAME-$ASDF_INSTALL_VERSION"

# Download tar.gz file to the download directory
download_release "$ASDF_INSTALL_VERSION"
download_release "$ASDF_INSTALL_VERSION" "$release_file"
3 changes: 2 additions & 1 deletion lib/utils.bash
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ get_platform() {
download_release() {
local version filename url platform extension
version="$1"
filename="$2"
platform=$(get_platform)
if [ "${platform:-x}" = "win64" ] || [ "${platform:-x}" = "win32" ]; then
extension='zip'
Expand All @@ -114,7 +115,7 @@ download_release() {
# Debug code
ls -alh

mv "micro-$version/micro" ./micro
mv "micro-$version/micro" "$filename"
rm "micro.$extension"
rm -rf "micro-$version"
}
Expand Down

0 comments on commit 51f1dda

Please sign in to comment.