Release SDK #2
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
# Currently this workflow does not automatically pull in changes from development or create a git tag or Github "Release". First | |
# make sure to manually create a release commit in main branch updating the version number in the `mparticle.nuspec` file. | |
# Then run this workflow from main branch to build and release to nuget. After it's released to nuget, manually create a tag | |
# and Github "Release" in the public repo pointing to the release commit. | |
name: Release SDK | |
on: | |
workflow_dispatch: | |
jobs: | |
# SDK release is done from main branch. | |
confirm-main-branch: | |
name: Confirm release is run from main branch | |
uses: mParticle/mparticle-workflows/.github/workflows/sdk-release-repo-branch-check.yml@stable | |
release-to-nuget: | |
name: Release and Sync Repos | |
runs-on: macos-15 | |
needs: ['confirm-main-branch'] | |
steps: | |
- name: Git checkout | |
uses: actions/checkout@v4 | |
- name: Install Android SDK 34 | |
run: | | |
yes | $ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager --install "platforms;android-34" | |
- name: Install Mono Framework for nuget command | |
run: | | |
curl https://download.mono-project.com/archive/6.12.0/macos-10-universal/MonoFramework-MDK-6.12.0.206.macos10.xamarin.universal.pkg -o /tmp/MonoFramework-MDK-6.12.0.206.macos10.xamarin.universal.pkg | |
sudo installer -pkg /tmp/MonoFramework-MDK-6.12.0.206.macos10.xamarin.universal.pkg -target / | |
- name: Install MAUI workload | |
run: dotnet workload install maui | |
- name: Build artifacts | |
run: ./build.sh | |
- name: Release to Nuget | |
run: nuget push *.nupkg ${{ secrets.NUGET_API_KEY }} -Source https://api.nuget.org/v3/index.json |