Skip to content

Commit

Permalink
test v6 beta
Browse files Browse the repository at this point in the history
  • Loading branch information
catcherwong committed Apr 4, 2022
1 parent c881893 commit 4ec3d3b
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
run: |
mkdir /home/runner/work/release
ls /home/runner/work/clis/
zip -r /home/runner/work/release/clisample-$VERSION-$RID.zip /home/runner/work/clis/$RID/*
zip -j /home/runner/work/release/clisample-$VERSION-$RID.zip /home/runner/work/clis/$RID/*
- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
Expand Down
74 changes: 74 additions & 0 deletions .github/workflows/release_unstable.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: Publish Release from Tag

on:
push:
tags:
- "*.*.*-beta*"
- "*.*.*-rc*"

jobs:

build:
name: Build release artifacts
runs-on: ubuntu-latest
strategy:
matrix:
targets:
[
"linux-x64",
"linux-musl-x64",
"linux-arm",
"linux-arm64",
"osx-x64",
"win-x64",
"win-x86",
"win-arm",
"win-arm64",
]
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Set up .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: "6.0.x"
- name: Publish .NET app
env:
RID: ${{ matrix.targets }}
VERSION: ${{ github.ref_name }}
run: dotnet publish -c Release -r $RID --self-contained true -p:DebugType=None -p:DebugSymbols=false -p:PublishSingleFile=true CliSample/CliSample.csproj --output /home/runner/work/clis/$RID
- name: Package assets
env:
RID: ${{ matrix.targets }}
VERSION: ${{ github.ref_name }}
run: |
mkdir /home/runner/work/release
ls /home/runner/work/clis/
zip -j /home/runner/work/release/clisample-$VERSION-$RID.zip /home/runner/work/clis/$RID/*
- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
name: clisample-${{ github.ref_name }}-${{ matrix.targets }}.zip
path: "/home/runner/work/release/clisample-${{ github.ref_name }}-${{ matrix.targets }}.zip"

publish:
name: Publish release
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Create .artifacts dir
run: mkdir .artifacts
- uses: actions/download-artifact@v2
with:
path: .artifacts
- name: Generate Changelog
run: git log --pretty="format:[%h] %s" $(git describe --tags --abbrev=0 @^)..@ > .artifacts/CHANGELOG.txt
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
prerelease: true
files: .artifacts/**
body_path: .artifacts/CHANGELOG.txt

0 comments on commit 4ec3d3b

Please sign in to comment.