Merge pull request #5 from Dpbm/fix #48
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 'Test nasm asdf plugin' | |
on: | |
push: | |
branches: | |
- "main" | |
pull_request: | |
branches: | |
- "*" | |
env: | |
DEFAULT_NASM_VERSION: 2.16 | |
ASDF_BRANCH: v0.13.1 | |
ASDF_DIR_WINDOWS: /root/.asdf | |
ASDF_EXEC: /root/.asdf/bin/asdf | |
ASDF_INSTALLATION_NASM: /root/.asdf/installs/nasm/2.16/bin/nasm | |
jobs: | |
plugin_test_ubuntu: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: 'Test asdf install' | |
uses: asdf-vm/actions/install@v2 | |
with: | |
tool_versions: 'nasm ${{ env.DEFAULT_NASM_VERSION }}' | |
- name: asdf_plugin_test | |
uses: asdf-vm/actions/plugin-test@v2 | |
with: | |
command: 'nasm --version' | |
- name: 'Show plugins' | |
run: 'asdf list' | |
- name: 'Test asdf list-all' | |
run: 'asdf list-all nasm' | |
plugin_test_windows: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: wsl-bash_Ubuntu-20.04 {0} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: Vampire/setup-wsl@v2 | |
with: | |
distribution: Ubuntu-20.04 | |
- name: 'Install dependencies' | |
run: sudo apt-get update && sudo apt-get upgrade -y && apt-get install -y build-essential curl git | |
- name: 'Asdf installation' | |
run: | | |
git config --global advice.detachedHead false | |
export ASDF_DIR=${{env.ASDF_DIR_WINDOWS}} | |
git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch ${{ env.ASDF_BRANCH }} | |
sh $ASDF_DIR/asdf.sh | |
${{env.ASDF_EXEC}} plugin add nasm https://github.com/Dpbm/asdf-nasm.git | |
- name: 'Test list-all' | |
run: '${{env.ASDF_EXEC}} list-all nasm' | |
- name: 'Test install version' | |
run: '${{env.ASDF_EXEC}} install nasm ${{env.DEFAULT_NASM_VERSION}}' | |
- name: 'Test nasm version' | |
run: '${{env.ASDF_INSTALLATION_NASM}} --version' | |
- name: 'Show plugins' | |
run: '${{env.ASDF_EXEC}} list' | |
plugin_test_mac: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: 'Test asdf install' | |
uses: asdf-vm/actions/install@v2 | |
with: | |
tool_versions: 'nasm ${{ env.DEFAULT_NASM_VERSION }}' | |
- name: 'Test nasm version' | |
run: 'nasm --version' | |
- name: 'Show plugins' | |
run: 'asdf list' | |
- name: 'Test asdf list-all' | |
run: 'asdf list-all nasm' |