Support complete pathname patterns in config file. #19
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
name: 'Build and publish release' | |
on: | |
push: | |
tags: | |
- '*' | |
jobs: | |
build-and-package: | |
strategy: | |
matrix: | |
include: | |
- platform: 'x86' | |
build_configuration: 'Release' | |
- platform: 'x64' | |
build_configuration: 'Release' | |
- platform: 'ARM64' | |
build_configuration: 'Release' | |
runs-on: windows-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout from GitHub | |
uses: actions/checkout@v3 | |
- name: Add msbuild to PATH | |
uses: microsoft/setup-msbuild@v1 | |
- name: Install vcpkg | |
shell: bash | |
run: | | |
git clone https://github.com/Microsoft/vcpkg.git | |
cd vcpkg | |
./bootstrap-vcpkg.sh | |
./vcpkg integrate install | |
- name: Install Microsoft GSL | |
run: | | |
./vcpkg/vcpkg install ms-gsl:x86-windows ms-gsl:x64-windows ms-gsl:arm64-windows | |
- name: Parse Version | |
shell: bash | |
run: | | |
# Strip "v" prefix from tag name | |
VERSION=$(echo ${{ github.ref_name }} | sed -e 's/^v//') | |
echo "VERSION=${VERSION}" >> $GITHUB_ENV | |
- name: Build | |
run: msbuild socksify.sln -t:rebuild -verbosity:minimal -property:Configuration=Release -property:Platform=${{ matrix.platform }} -property:Version=${{ env.VERSION }} -property:Repository=${{ github.repository }} | |
- name: Package Release | |
uses: thedoctor0/[email protected] | |
with: | |
type: 'zip' | |
filename: 'ProxiFyre-${{ github.ref_name }}-${{ matrix.platform }}.zip' | |
directory: 'bin\exe\${{ matrix.platform }}\${{ matrix.build_configuration }}' | |
exclusions: '*.pdb' | |
- name: Upload artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: ${{ matrix.platform }}-artifact | |
path: 'bin\exe\${{ matrix.platform }}\${{ matrix.build_configuration }}\ProxiFyre-${{ github.ref_name }}-${{ matrix.platform }}.zip' | |
upload-release: | |
if: ${{ always() }} | |
needs: build-and-package | |
runs-on: windows-latest | |
steps: | |
- name: Checkout from GitHub | |
uses: actions/checkout@v3 | |
- name: Download artifacts | |
uses: actions/download-artifact@v2 | |
with: | |
path: 'artifacts' | |
- name: Parse Version | |
shell: bash | |
run: | | |
# Strip "v" prefix from tag name | |
VERSION=$(echo ${{ github.ref_name }} | sed -e 's/^v//') | |
echo "VERSION=${VERSION}" >> $GITHUB_ENV | |
- name: Upload Release | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: 'artifacts/**/*.zip' | |
name: 'ProxiFyre-${{ github.ref_name }}' | |
tag: ${{ github.ref_name }} | |
token: ${{ secrets.MY_GITHUB_PAT }} | |
skipIfReleaseExists: true |