delete dummy index.html file when build is aborted #81
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
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- stable | |
paths: | |
- '.github/workflows/release.yml' | |
- 'packages/**' | |
name: Release Pipeline | |
jobs: | |
release: | |
name: Bump Packages | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.head_ref }} | |
token: ${{ secrets.PUSH_TOKEN }} | |
- uses: dart-lang/setup-dart@v1.3 | |
- uses: subosito/flutter-action@v2 | |
- name: Authenticate to Google Cloud | |
uses: google-github-actions/auth@v1 | |
with: | |
credentials_json: ${{ secrets.PUB_PUBLISH_KEY }} | |
- name: Bootstrap | |
run: | | |
dart pub global activate melos | |
dart pub global activate -s git https://github.com/schultek/semantic_changelog | |
melos bootstrap --no-private | |
jaspr --disable-analytics | |
gcloud auth print-identity-token --audiences=https://pub.dev | dart pub token add https://pub.dev | |
- name: Bump Package Versions | |
id: bump | |
run: | | |
version bump | tee output.txt | |
echo 'commit_message<<EOF' >> $GITHUB_OUTPUT | |
echo "Bump package versions" >> $GITHUB_OUTPUT | |
echo "" >> $GITHUB_OUTPUT | |
cat output.txt >> $GITHUB_OUTPUT | |
echo 'EOF' >> $GITHUB_OUTPUT | |
echo "did_bump=$(grep -q "No packages" output.txt; echo $?)" >> $GITHUB_OUTPUT | |
rm -rf output.txt | |
- name: Apply Versions | |
run: | | |
melos bootstrap | |
- name: Update CLI | |
run: | | |
melos run generate:versions | |
melos run format | |
- name: Commit Versions | |
if: steps.bump.outputs.did_bump != '0' | |
run: | | |
git add apps/ | |
git add examples/ | |
git add packages/ | |
git -c user.name="github-actions[bot]" -c user.email="41898282+github-actions[bot]@users.noreply.github.com" \ | |
commit -m "${{ steps.bump.outputs.commit_message }}" \ | |
--author="${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>" | |
- name: Tag Packages | |
run: | | |
version publish -f | |
git push --tags origin stable | |