fix: add preprocessor directives to filter out addressables code (#21) #14
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: Release | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
release: | |
name: release | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
persist-credentials: false | |
- name: Semantic Release | |
id: semantic | |
uses: cycjimmy/semantic-release-action@v3.1.2 | |
with: | |
extra_plugins: | | |
@semantic-release/changelog | |
@semantic-release/git | |
branch: main | |
env: | |
GH_TOKEN: ${{ secrets.GH_TOKEN }} | |
- name: Post Release Checkout | |
id: post_release | |
uses: actions/checkout@v3 | |
if: steps.semantic.outputs.new_release_published == 'true' | |
with: | |
ref: ${{ steps.semantic.outputs.new_release_version }} | |
- name: Split UPM Branch | |
id: split_upm | |
if: steps.post_release.outcome == 'success' | |
run: | | |
git branch -d upm &> /dev/null || echo upm branch not found | |
git subtree split -P "$PKG_ROOT" -b upm | |
git checkout upm | |
if [[ -d "Samples" ]]; then | |
git mv Samples Samples~ | |
rm -f Samples.meta | |
git config --global user.name 'github-bot' | |
git config --global user.email 'github-bot@users.noreply.github.com' | |
git commit -am "fix: Samples => Samples~" | |
fi | |
git push -f -u origin upm | |
env: | |
PKG_ROOT: Packages/mygamedevtools-scene-loader | |
- name: Create UPM Tag | |
if: steps.split_upm.outcome == 'success' | |
run: | | |
git tag $TAG upm | |
git push origin --tags | |
env: | |
TAG: upm/${{ steps.semantic.outputs.new_release_version }} |