Skip to content

Commit

Permalink
add action
Browse files Browse the repository at this point in the history
  • Loading branch information
Vladislav Kalugin committed Nov 8, 2022
1 parent 92acdb7 commit 8c1d1c1
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Build dotnet package

on: [push]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET Core SDK 5.0.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: '5.0.x'
- name: Build
run: dotnet build --configuration Release
- name: Upload dll
uses: actions/upload-artifact@v3
with:
name: msbuild-database
path: bin/Release/netstandard2.0/msbuild-database.dll


28 changes: 28 additions & 0 deletions .github/workflows/publish_release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Publish release

on:
push:
branches:
- "main"

jobs:
build-and-publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET Core SDK 5.0.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: '5.0.x'
- name: Build
run: dotnet build --configuration Release
- name: Set version
run: |
export VERSION=$(date '+%Y.%-m').$GITHUB_RUN_NUMBER
echo "VERSION=$VERSION" >> $GITHUB_ENV
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "${{ env.VERSION }}"
prerelease: true
files: bin/Release/netstandard2.0/msbuild-database.dll

0 comments on commit 8c1d1c1

Please sign in to comment.