From f87681463811d33344ef5b26b766d4f2d7fc6c58 Mon Sep 17 00:00:00 2001 From: Nick - Ngoc Pham Date: Wed, 2 Oct 2024 12:21:34 +0700 Subject: [PATCH] chore: noversion --- .github/workflows/update-config.yml | 57 +++++++++++++++++------------ 1 file changed, 34 insertions(+), 23 deletions(-) diff --git a/.github/workflows/update-config.yml b/.github/workflows/update-config.yml index 540eab5..d5b070b 100644 --- a/.github/workflows/update-config.yml +++ b/.github/workflows/update-config.yml @@ -9,8 +9,8 @@ permissions: contents: write jobs: - setup-build-publish-deploy: - name: Update config ${{ matrix.env }} + run: + name: Run ${{ matrix.env }} environment: ${{ matrix.env }} runs-on: ubuntu-latest continue-on-error: true @@ -34,24 +34,35 @@ jobs: path: ${{ matrix.env }}/app-config.json if-no-files-found: warn - # - name: Checkout source - # uses: actions/checkout@v4 - # with: - # repository: ${{ secrets.STATIC_WEB_REPOSITORY }} - # token: ${{ secrets.GH_PAT }} - # path: source - - # - name: Move file - # run: | - # rm -rf ./source/${{ matrix.env }}/conf/app-config.json - # mv ./tmp/app-config.json ./source/${{ matrix.env }}/conf/app-config.json - - # - name: Commit - # working-directory: source - # run: | - # cat ./${{ matrix.env }}/conf/app-config.json - # git config user.name "GitHub Actions" - # git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - # git add -A - # git diff-index --quiet HEAD || git commit -m ':white_check_mark: Update' - # git pull origin main && git push origin main + after-run: + name: After run + needs: [run] + runs-on: ubuntu-latest + steps: + - name: Download from artifact + uses: actions/download-artifact@v4 + + - name: Checkout source + uses: actions/checkout@v4 + with: + repository: ${{ secrets.STATIC_WEB_REPOSITORY }} + token: ${{ secrets.GH_PAT }} + path: source + + - name: test + run: ls + + # - name: Move file + # run: | + # rm -rf ./source/${{ matrix.env }}/conf/app-config.json + # mv ./tmp/app-config.json ./source/${{ matrix.env }}/conf/app-config.json + + # - name: Commit + # working-directory: source + # run: | + # cat ./${{ matrix.env }}/conf/app-config.json + # git config user.name "GitHub Actions" + # git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + # git add -A + # git diff-index --quiet HEAD || git commit -m ':white_check_mark: Update' + # git pull origin main && git push origin main