Skip to content

Move back to lower-case 'usage' string (#157) #225

Move back to lower-case 'usage' string (#157)

Move back to lower-case 'usage' string (#157) #225

Workflow file for this run

name: Publish
on:
push:
branches: [ "main" ]
tags: [ "*" ]
permissions:
contents: write
jobs:
publish:
strategy:
matrix:
include:
- os: ubuntu-latest
rid: linux-x64
zipSuffix: tar.gz
- os: ubuntu-latest
rid: linux-arm64
zipSuffix: tar.gz
- os: windows-latest
rid: win-x64
zipSuffix: zip
- os: macos-latest
rid: osx-x64
zipSuffix: tar.gz
- os: macos-latest
rid: osx-arm64
zipSuffix: tar.gz
runs-on: ${{ matrix.os }}
steps:
- name: Install linux arm64 prereqs
if: matrix.rid == 'linux-arm64'
run: |
sudo dpkg --add-architecture arm64
sudo bash -c 'cat > /etc/apt/sources.list.d/arm64.list <<EOF
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ jammy main restricted
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ jammy-updates main restricted
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ jammy-backports main restricted universe multiverse
EOF'
sudo sed -i -e 's/deb http/deb [arch=amd64] http/g' /etc/apt/sources.list
sudo sed -i -e 's/deb mirror/deb [arch=amd64] mirror/g' /etc/apt/sources.list
sudo apt update
sudo apt install -y clang llvm binutils-aarch64-linux-gnu gcc-aarch64-linux-gnu zlib1g-dev:arm64
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: '8.0.*'
- name: Restore local tools
run: dotnet tool restore
- name: Publish Windows
if: matrix.os == 'windows-latest'
shell: pwsh
run: ./publish.ps1
- name: Publish Unix
if: matrix.os != 'windows-latest'
run: ./publish.sh -r ${{ matrix.rid }}
- name: Upload a Build Artifact
uses: actions/[email protected]
with:
name: dnvm-${{ matrix.rid }}.${{ matrix.zipSuffix }}
# A file, directory or wildcard pattern that describes what to upload
path: artifacts/dnvm-*-${{ matrix.rid }}.${{ matrix.zipSuffix }}
release:
if: startsWith(github.ref, 'refs/tags/v')
needs: publish
runs-on: ubuntu-latest
steps:
- name: Download release artifacts
uses: actions/download-artifact@v3
- name: Display structure of downloaded files
run: ls -R
- name: Make Release
uses: softprops/action-gh-release@v1
with:
prerelease: true
draft: true
files:
dnvm-*/dnvm-*