refactor the CI in scripts #39
Workflow file for this run
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
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
name: continuous-integration | |
defaults: | |
run: | |
shell: bash | |
env: | |
NU_LOG_LEVEL: DEBUG | |
CI_SCRIPTS: ".github/workflows/scripts" | |
jobs: | |
tests: | |
strategy: | |
fail-fast: true | |
matrix: | |
platform: [windows-latest, macos-latest, ubuntu-20.04] | |
runs-on: ${{ matrix.platform }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set platform-specific variables | |
run: bash $CI_SCRIPTS/set-platform-specific-variables.sh "${{ runner.os }}" >> "$GITHUB_ENV" | |
- name: Install Nushell from Nightly | |
run: bash $CI_SCRIPTS/install-nightly-nushell.sh "${{ env.ARCH }}" "${{ env.EXT }}" "${{ env.NU_BIN }}" | |
- name: Install Nupm from Source | |
run: git clone https://github.com/nushell/nupm "${{ env.NUPM }}" | |
- name: Show Nushell Version | |
run: | | |
"$HOME/${{ env.NU_BIN }}" --commands "version" | |
- name: Run the tests | |
run: | | |
"$HOME/${{ env.NU_BIN }}" --commands "use ${{ env.NUPM }}/nupm/; nupm test" |