11# The version is pulled from the CHANGELOG.md file of the package.
2- # Add a `-dev.xxx` suffix to the version.
2+ # Add a `-dev.xxx` suffix to the version. Example: `0.0.1-dev.1`
33name : Create Dev Release
44
55on : workflow_dispatch
@@ -24,17 +24,32 @@ jobs:
2424 - name : Restore dependencies
2525 run : dotnet restore
2626
27- - name : Extract Version from CHANGELOG.md
27+ - name : Extract Common Package Version from CHANGELOG.md
2828 id : extract_version
2929 shell : bash
3030 run : |
31- VERSION =$(awk '/^## [0-9]+\.[0-9]+\.[0-9]+-dev(\.[0-9]+)?$/ {print $2; exit}' PowerSync/PowerSync.Common/CHANGELOG.md)
32- echo "Detected Version: $VERSION "
33- echo "VERSION=$VERSION " >> $GITHUB_ENV
31+ COMMON_VERSION =$(awk '/^## [0-9]+\.[0-9]+\.[0-9]+-dev(\.[0-9]+)?$/ {print $2; exit}' PowerSync/PowerSync.Common/CHANGELOG.md)
32+ echo "Detected Version: $COMMON_VERSION "
33+ echo "VERSION=$COMMON_VERSION " >> $GITHUB_ENV
3434
35- - name : Run Pack
36- run : dotnet pack -c Release -o ${{ github.workspace }}/output
35+ - name : Run Pack For Common
36+ run : dotnet pack PowerSync/PowerSync.Common -c Release -o ${{ github.workspace }}/output
3737
38- - name : Run Push
39- run : dotnet nuget push ${{ github.workspace }}\output\*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }}
40-
38+ - name : Run Push For Common
39+ continue-on-error : true
40+ run : dotnet nuget push ${{ github.workspace }}\output\PowerSync.Common*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }}
41+
42+ - name : Extract MAUI Package Version from CHANGELOG.md
43+ id : extract_maui_version
44+ shell : bash
45+ run : |
46+ MAUI_VERSION=$(awk '/^## [0-9]+\.[0-9]+\.[0-9]+-dev(\.[0-9]+)?$/ {print $2; exit}' PowerSync/PowerSync.Maui/CHANGELOG.md)
47+ echo "Detected Version: $MAUI_VERSION"
48+ echo "VERSION=$MAUI_VERSION" >> $GITHUB_ENV
49+
50+ - name : Run Pack For MAUI
51+ run : dotnet pack PowerSync/PowerSync.Maui -c Release -o ${{ github.workspace }}/output
52+
53+ - name : Run Push For MAUI
54+ continue-on-error : true
55+ run : dotnet nuget push ${{ github.workspace }}\output\PowerSync.Maui*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }}
0 commit comments