Skip to content

🐛 Better archtectures ARM handling : aa64 #220

@adriens

Description

@adriens

❔ About

We initialy intended to use this action only for Linux x86-64, for our own needs... but now some users using this action on different architectures fall on the issue we expected :

🎯 Action

In the action, detect the OS and properly log it in the action ;

# Detect OS
detect_os() {
    case "$(uname -s)" in
        Linux*)     OS="Linux";;
        Darwin*)    OS="Darwin";;
        CYGWIN*|MINGW*|MSYS*) OS="Windows";;
        FreeBSD*)   OS="FreeBSD";;
        OpenBSD*)   OS="OpenBSD";;
        *)          OS="UNKNOWN";;
    esac
    echo "$OS"
}

then the architecture properly log it in the action:

detect_arch() {
    ARCH=$(uname -m)
    case $ARCH in
        x86_64)  echo "x86_64";;
        amd64)   echo "x86_64";;
        arm64)   echo "arm64";;
        aarch64) echo "arm64";;
        armv7l)  echo "armv7";;
        armv6l)  echo "armv6";;
        i386|i686) echo "i386";;
        *)       echo "unknown";;
    esac
}

Then prepare the proper asset url to download.
Do the next steps

✔️ DoD

Sub-issues

Metadata

Metadata

Assignees

Labels

BUILDToute activité liée à la création de nouvelles fonctionnalitésenhancementNew feature or requestgithub_actionsPull requests that update GitHub Actions codesucces-remarquableFlagger une issue ou une PR comme un succès particulier !

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions