Merge pull request #6 from salesHgabriel/feat/add_endpoints #20
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: Publish Nuget Packages | |
on: | |
push: | |
tags: | |
- '*.*.**' | |
jobs: | |
publish_nuget_package: | |
name: Publish SSync Client and Server | |
runs-on: ubuntu-latest | |
steps: | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v2 | |
with: | |
dotnet-version: 8.0.x | |
# project ssync client | |
- uses: actions/checkout@v4 | |
- name: Set Version Client | |
run: | | |
sed -i -e 's/1.1.1/${{github.ref_name}}/' ./src/SSync.Client.LitebDB/SSync.Client.LitebDB.csproj | |
- name: Restore Client | |
run: dotnet restore ./src/SSync.Client.LitebDB/SSync.Client.LitebDB.csproj | |
- name: Build Client | |
run: dotnet build --no-restore ./src/SSync.Client.LitebDB/SSync.Client.LitebDB.csproj | |
- name: Pack Client | |
run: | | |
dotnet pack ./src/SSync.Client.LitebDB/SSync.Client.LitebDB.csproj -c Release -o output-client | |
- name: Publish Client to Nuget.Org | |
run: | | |
dotnet nuget push output-client/*.nupkg -k ${{ secrets.NUGET_API_KEY_CLIENT }} -s https://api.nuget.org/v3/index.json --skip-duplicate | |
# end project ssync client | |
# project ssync server | |
- uses: actions/checkout@v4 | |
- name: Set Version Server | |
run: | | |
sed -i -e 's/1.1.1/${{github.ref_name}}/' ./src/SSync.Server.LitebDB/SSync.Server.LitebDB.csproj | |
- name: Restore Server | |
run: dotnet restore ./src/SSync.Server.LitebDB/SSync.Server.LitebDB.csproj | |
- name: Build Server | |
run: dotnet build --no-restore ./src/SSync.Server.LitebDB/SSync.Server.LitebDB.csproj | |
- name: Pack Server | |
run: | | |
dotnet pack ./src/SSync.Server.LitebDB/SSync.Server.LitebDB.csproj -c Release -o output-server | |
- name: Publish Server to Nuget.Org | |
run: | | |
dotnet nuget push output-server/*.nupkg -k ${{ secrets.NUGET_API_KEY_SERVER }} -s https://api.nuget.org/v3/index.json --skip-duplicate | |
# end project ssync server |