From c4438de200e177364db9ed94ed48cc58eaf6ae28 Mon Sep 17 00:00:00 2001 From: Imran <30463115+ImranR98@users.noreply.github.com> Date: Sun, 30 Jun 2024 12:55:38 -0400 Subject: [PATCH 1/2] Update release.yml --- .github/workflows/release.yml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 19e5b7c..e9ce90c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,7 +6,13 @@ on: beta: type: boolean description: Is beta? - + draft: + type: boolean + description: Is draft? + checkout: + required: true + default: "main" + jobs: build: runs-on: ubuntu-latest @@ -32,8 +38,8 @@ jobs: gpg_private_key: ${{ secrets.PGP_KEY_BASE64 }} passphrase: ${{ secrets.PGP_PASSPHRASE }} - - name: Check submodule - id: check_submodule + - name: Checkout branch + id: checkout_branch run: | SUBMODULE_COMMIT_LONG="$(git submodule status | head -1 | tail -c +2 | awk '{print $1}')" FLUTTER_COMMIT_SHORT="$(flutter --version | head -2 | tail -1 | awk '{print $4}')" @@ -43,6 +49,11 @@ jobs: exit 1 fi + - name: Check submodule + id: check_submodule + run: | + git checkout ${{ inputs.checkout }} + - name: Extract Version id: extract_version run: | @@ -92,5 +103,6 @@ jobs: token: ${{ secrets.GH_ACCESS_TOKEN }} tag: "${{ steps.extract_version.outputs.tag }}" prerelease: "${{ steps.extract_version.outputs.beta }}" + draft: "${{ inputs.draft }}" artifacts: ./build/app/outputs/flutter-apk/*-release*.apk* generateReleaseNotes: true From 75efd335e992eadf6846ea11e22009ce2bebb056 Mon Sep 17 00:00:00 2001 From: Imran <30463115+ImranR98@users.noreply.github.com> Date: Sun, 30 Jun 2024 12:56:28 -0400 Subject: [PATCH 2/2] Update release.yml --- .github/workflows/release.yml | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e9ce90c..bc88098 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,9 +9,6 @@ on: draft: type: boolean description: Is draft? - checkout: - required: true - default: "main" jobs: build: @@ -38,17 +35,6 @@ jobs: gpg_private_key: ${{ secrets.PGP_KEY_BASE64 }} passphrase: ${{ secrets.PGP_PASSPHRASE }} - - name: Checkout branch - id: checkout_branch - run: | - SUBMODULE_COMMIT_LONG="$(git submodule status | head -1 | tail -c +2 | awk '{print $1}')" - FLUTTER_COMMIT_SHORT="$(flutter --version | head -2 | tail -1 | awk '{print $4}')" - echo "SUBMODULE_COMMIT_LONG=$SUBMODULE_COMMIT_LONG, FLUTTER_COMMIT_SHORT=$FLUTTER_COMMIT_SHORT" - if ! [[ "$SUBMODULE_COMMIT_LONG" =~ ^$FLUTTER_COMMIT_SHORT ]]; then - echo "Your submodule has not been updated!" - exit 1 - fi - - name: Check submodule id: check_submodule run: |