Implement MergeSources and BindReturn (#4) #46
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: Publish | |
on: | |
push: | |
branches: | |
- master | |
env: | |
publish_version: 0.0.${{ github.run_number }} | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
dotnet: [6.0.401] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v1 | |
- uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: ${{ matrix.dotnet }} | |
source-url: https://nuget.pkg.github.com/totallymoney/index.json | |
env: | |
NUGET_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
- run: dotnet tool restore | |
- run: dotnet paket restore | |
- run: dotnet build | |
- run: dotnet run -p ./tests/**/*.fsproj | |
- id: commit_msg_reader | |
run: | | |
LATEST_TAG="$(git describe --tags --abbrev=0)" | |
MESSAGES_SINCE_TAG="$(git log "$LATEST_TAG".."$GITHUB_SHA" --format="%s <%an>")" | |
echo "::set-output name=messages::$MESSAGES_SINCE_TAG" | |
- run: | | |
dotnet pack \ | |
--output ./out \ | |
--configuration Release \ | |
-p:PackageVersion=${{ env.publish_version }} \ | |
-p:PackageReleaseNotes="${{ steps.commit_msg_reader.outputs.messages }}" | |
- run: | | |
dotnet nuget push ./out/*.nupkg \ | |
--api-key ${{ secrets.NUGET_TOKEN }} \ | |
--source https://www.nuget.org | |
- uses: actions/create-release@latest | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ env.publish_version }} | |
release_name: ${{ env.publish_version }} | |
body: ${{ steps.commit_msg_reader.outputs.messages }} | |
draft: false | |
prerelease: false | |
- uses: svenstaro/upload-release-action@v1-release | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: out/*.nupkg | |
tag: ${{ env.publish_version }} | |
overwrite: true | |
file_glob: true |