Skip to content

Commit

Permalink
fetch-configlet: support fetching arm64 assets (#805)
Browse files Browse the repository at this point in the history
The most recent configlet release [1] includes pre-built binaries for:

- arm64 Linux [2]
- arm64 macOS [3]
- arm64 Windows [4]
- riscv64 Linux [5]

Support arm64 in the bash fetch-configlet script.

Refs: #122

[1] https://github.com/exercism/configlet/releases/tag/4.0.0-beta.14
[2] 0e8d665, 2023-08-16, ".github, config: use Zig to cross-compile arm64 Linux asset"
[3] f280445, 2023-08-17, ".github: cross-compile arm64 macOS asset"
[4] 3824299, 2023-08-18, ".github, cli, completion: cross-compile arm64 Windows asset"
[5] a962b18, 2023-08-17, ".github: cross-compile riscv64 Linux asset"
  • Loading branch information
ee7 authored Aug 22, 2023
1 parent dca4119 commit 98095a5
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions scripts/fetch-configlet
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,11 @@ get_download_url() {
local latest='https://api.github.com/repos/exercism/configlet/releases/latest'
local arch
case "$(uname -m)" in
x86_64) arch='x86-64' ;;
*686*) arch='i386' ;;
*386*) arch='i386' ;;
*) arch='x86-64' ;;
aarch64|arm64) arch='arm64' ;;
x86_64) arch='x86-64' ;;
*686*) arch='i386' ;;
*386*) arch='i386' ;;
*) arch='x86-64' ;;
esac
local suffix="${os}_${arch}.${ext}"
curl "${curlopts[@]}" --header 'Accept: application/vnd.github.v3+json' "${latest}" |
Expand Down

0 comments on commit 98095a5

Please sign in to comment.