From 1d4133d9ebc04e2893d93a96764fe76dfea9bfea Mon Sep 17 00:00:00 2001 From: Abdou Abarchi Aboubacar <57944650+AbdouAbarchiAboubacar@users.noreply.github.com> Date: Mon, 20 Mar 2023 17:57:00 +0100 Subject: [PATCH] Trying to build change logs --- .github/workflows/firebase-hosting-merge.yml | 189 ++++++++++--------- README.md | 2 +- 2 files changed, 100 insertions(+), 91 deletions(-) diff --git a/.github/workflows/firebase-hosting-merge.yml b/.github/workflows/firebase-hosting-merge.yml index ef98e71..a9e5087 100644 --- a/.github/workflows/firebase-hosting-merge.yml +++ b/.github/workflows/firebase-hosting-merge.yml @@ -4,8 +4,6 @@ name: Flutter Build, Release And Deploy 'on': push: - branches: - - master jobs: flutter_test: name: Run flutter test and analyze @@ -20,98 +18,109 @@ jobs: flutter-version: '2.10.4' channel: "stable" - run: flutter pub get - - run: flutter analyze - - run: flutter test + # - run: flutter analyze + # - run: flutter test - build_apk: - name: Generate apk files + generate_release_note: + name: Generate release note needs: [flutter_test] runs-on: ubuntu-latest - # Steps represent a sequence of tasks that will be executed as part of the job steps: - # Setup Java environment in order to build the Android app. - - uses: actions/checkout@v3 - - uses: actions/setup-java@v1 - with: - java-version: '11.x' - # Setup the flutter environment. - - uses: subosito/flutter-action@v2 - with: - flutter-version: '2.10.4' - channel: "stable" - - name: Install dependencies - run: flutter pub get - - name: Build apk - run: flutter build apk - # Upload generated apk to the artifacts. - - uses: actions/upload-artifact@master - with: - name: release-apk - path: build/app/outputs/apk/release/app-release.apk + - name: Build Changelog + id: github_release + uses: mikepenz/release-changelog-builder-action@v3 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + # build_apk: + # name: Generate apk files + # needs: [flutter_test] + # runs-on: ubuntu-latest + # # Steps represent a sequence of tasks that will be executed as part of the job + # steps: + # # Setup Java environment in order to build the Android app. + # - uses: actions/checkout@v3 + # - uses: actions/setup-java@v1 + # with: + # java-version: '11.x' + # # Setup the flutter environment. + # - uses: subosito/flutter-action@v2 + # with: + # flutter-version: '2.10.4' + # channel: "stable" + # - name: Install dependencies + # run: flutter pub get + # - name: Build apk + # run: flutter build apk + # # Upload generated apk to the artifacts. + # - uses: actions/upload-artifact@master + # with: + # name: release-apk + # path: build/app/outputs/apk/release/app-release.apk - build_appbundle: - name: Generate appbundle files - needs: [flutter_test] - runs-on: ubuntu-latest - # Steps represent a sequence of tasks that will be executed as part of the job - steps: - # Setup Java environment in order to build the Android app. - - uses: actions/checkout@v3 - - uses: actions/setup-java@v1 - with: - java-version: '11.x' - # Setup the flutter environment. - - uses: subosito/flutter-action@v2 - with: - flutter-version: '2.10.4' - channel: "stable" - - name: Install dependencies - run: flutter pub get - - name: Build appbundle - run: flutter build appbundle - # Upload generated apk to the artifacts. - - uses: actions/upload-artifact@master - with: - name: release-appbundle - path: build/app/outputs/bundle/release/app-release.aab + # build_appbundle: + # name: Generate appbundle files + # needs: [flutter_test] + # runs-on: ubuntu-latest + # # Steps represent a sequence of tasks that will be executed as part of the job + # steps: + # # Setup Java environment in order to build the Android app. + # - uses: actions/checkout@v3 + # - uses: actions/setup-java@v1 + # with: + # java-version: '11.x' + # # Setup the flutter environment. + # - uses: subosito/flutter-action@v2 + # with: + # flutter-version: '2.10.4' + # channel: "stable" + # - name: Install dependencies + # run: flutter pub get + # - name: Build appbundle + # run: flutter build appbundle + # # Upload generated apk to the artifacts. + # - uses: actions/upload-artifact@master + # with: + # name: release-appbundle + # path: build/app/outputs/bundle/release/app-release.aab - build_web: - name: Build Flutter (Web) - needs: [flutter_test] - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v1 - with: - java-version: "18.x" - - uses: subosito/flutter-action@v2 - with: - channel: "stable" - - run: flutter pub get - - run: flutter config --enable-web - - run: flutter build web - - name: Archive Production Artifact - uses: actions/upload-artifact@master - with: - name: web-build - path: build/web + # build_web: + # name: Build Flutter (Web) + # needs: [flutter_test] + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v3 + # - uses: actions/setup-java@v1 + # with: + # java-version: "18.x" + # - uses: subosito/flutter-action@v2 + # with: + # channel: "stable" + # - run: flutter pub get + # - run: flutter config --enable-web + # - run: flutter build web + # - name: Archive Production Artifact + # uses: actions/upload-artifact@master + # with: + # name: web-build + # path: build/web - deploy: - name: Deploy to firebase hosting - runs-on: ubuntu-latest - needs: [build_web] - steps: - - uses: actions/checkout@v3 - - name: Checkout Repo - uses: actions/checkout@master - - name: Download Artifact - uses: actions/download-artifact@master - with: - name: web-build - path: build/web - - uses: FirebaseExtended/action-hosting-deploy@v0 - with: - repoToken: '${{ secrets.GITHUB_TOKEN }}' - firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_PORTFOLIO_E3C04 }}' - channelId: live - projectId: portfolio-e3c04 + # deploy: + # name: Deploy to firebase hosting + # runs-on: ubuntu-latest + # needs: [build_web] + # steps: + # - uses: actions/checkout@v3 + # - name: Checkout Repo + # uses: actions/checkout@master + # - name: Download Artifact + # uses: actions/download-artifact@master + # with: + # name: web-build + # path: build/web + # - uses: FirebaseExtended/action-hosting-deploy@v0 + # with: + # repoToken: '${{ secrets.GITHUB_TOKEN }}' + # firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_PORTFOLIO_E3C04 }}' + # channelId: live + # projectId: portfolio-e3c04 diff --git a/README.md b/README.md index d777f9d..3f9917c 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ This is a Flutter template with Continuous Integration and Continuous Deployment To use this template, simply click on the "Use this template" button at the top of the repository page or clone this repository to your local machine: 🤖 -``` +```sh git clone https://github.com/your-username/your-repo-name.git ```