From 4e4bb43eeaef3ac548f35128c3136163db4c4736 Mon Sep 17 00:00:00 2001 From: TASNEEM KOUSHAR Date: Sun, 18 Feb 2024 16:54:03 +0530 Subject: [PATCH 1/5] Update push.yml --- .github/workflows/push.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 5796468eac..bd518ee46e 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -58,6 +58,24 @@ jobs: fail_ci_if_error: false name: '${{env.CODECOV_UNIQUE_NAME}}' + Empty-Commit: + name: Create Empty Commit + runs-on: ubuntu-latest + if: github.ref == 'refs/heads/develop' + steps: + - name: Checkout repository + uses: actions/checkout@v3 + with: + persist-credentials: false + token: ${{ secrets.TALAWA_DOCS_SYNC }} + - name: Empty Commit + run: | + git config --global user.name "${{github.actor}}" + git config --global user.email "${{env.email}}" + git config --global url.https://${{ secrets.TALAWA_DOCS_SYNC }}@github.com/.insteadOf https://github.com/ + git commit --allow-empty -m "Trigger Documentation Workflow" + git push origin develop:automated-docs --force + Generate-Documentation: runs-on: ubuntu-latest if: github.ref == 'refs/heads/automated-docs' From a192aedb9fcb2d4fc31a1c6c030618952949da65 Mon Sep 17 00:00:00 2001 From: TASNEEM KOUSHAR Date: Sun, 18 Feb 2024 17:08:02 +0530 Subject: [PATCH 2/5] Update push.yml --- .github/workflows/push.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index bd518ee46e..1289cfb635 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -82,7 +82,12 @@ jobs: steps: - name: Checkout the Repository uses: actions/checkout@v3 + with: + ref: develop + - name: Pull latest changes from develop + run: git pull origin develop + - name: Node.js Version uses: actions/setup-node@v4 with: From 7ad7446e47a3492eb872846de9e362285f9211df Mon Sep 17 00:00:00 2001 From: TASNEEM KOUSHAR Date: Sun, 18 Feb 2024 17:21:41 +0530 Subject: [PATCH 3/5] Update push.yml --- .github/workflows/push.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 1289cfb635..b7dade94a7 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -78,15 +78,15 @@ jobs: Generate-Documentation: runs-on: ubuntu-latest - if: github.ref == 'refs/heads/automated-docs' + if: github.ref == 'refs/heads/develop' steps: - name: Checkout the Repository uses: actions/checkout@v3 - with: - ref: develop + # with: + # ref: develop - - name: Pull latest changes from develop - run: git pull origin develop + # - name: Pull latest changes from develop + # run: git pull origin develop - name: Node.js Version uses: actions/setup-node@v4 @@ -156,7 +156,7 @@ jobs: git config --global user.email "${{env.email}}" git add . git commit -m "Update documentation" - git push + git push origin develop:automated-docs --force echo -e "🚀${Green} Hurrah! doc updated${NoColor}" - name: Create Documentation Artifact @@ -166,7 +166,7 @@ jobs: path: talawa-admin-docs Copy-docs-to-talawa-docs: - needs: Generate-Documentation + if: github.ref == 'refs/heads/automated-docs' runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 From 7055b34b2e35f72343fb1cc717470c9d2f0d8d7f Mon Sep 17 00:00:00 2001 From: TASNEEM KOUSHAR Date: Sun, 18 Feb 2024 17:23:25 +0530 Subject: [PATCH 4/5] Update push.yml --- .github/workflows/push.yml | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b7dade94a7..b73c283aaf 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -58,24 +58,6 @@ jobs: fail_ci_if_error: false name: '${{env.CODECOV_UNIQUE_NAME}}' - Empty-Commit: - name: Create Empty Commit - runs-on: ubuntu-latest - if: github.ref == 'refs/heads/develop' - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - persist-credentials: false - token: ${{ secrets.TALAWA_DOCS_SYNC }} - - name: Empty Commit - run: | - git config --global user.name "${{github.actor}}" - git config --global user.email "${{env.email}}" - git config --global url.https://${{ secrets.TALAWA_DOCS_SYNC }}@github.com/.insteadOf https://github.com/ - git commit --allow-empty -m "Trigger Documentation Workflow" - git push origin develop:automated-docs --force - Generate-Documentation: runs-on: ubuntu-latest if: github.ref == 'refs/heads/develop' @@ -165,6 +147,25 @@ jobs: name: documentation-admin path: talawa-admin-docs + Empty-Commit: + name: Create Empty Commit + runs-on: ubuntu-latest + if: github.ref == 'refs/heads/develop' + needs: Generate-Documentation + steps: + - name: Checkout repository + uses: actions/checkout@v3 + with: + persist-credentials: false + token: ${{ secrets.TALAWA_DOCS_SYNC }} + - name: Empty Commit + run: | + git config --global user.name "${{github.actor}}" + git config --global user.email "${{env.email}}" + git config --global url.https://${{ secrets.TALAWA_DOCS_SYNC }}@github.com/.insteadOf https://github.com/ + git commit --allow-empty -m "Trigger Documentation Workflow" + git push origin develop:automated-docs --force + Copy-docs-to-talawa-docs: if: github.ref == 'refs/heads/automated-docs' runs-on: ubuntu-latest From 5a625c77ba9b1872f3721411764955eb98b1cc8a Mon Sep 17 00:00:00 2001 From: Peter Harrison <16875803+palisadoes@users.noreply.github.com> Date: Mon, 19 Feb 2024 10:22:17 -0800 Subject: [PATCH 5/5] Updated github actions to the latest versions (#1604) * Workflow Test 1708236296 * Workflow Test 1708236792 * Test * Upgraded github actions to the latest versions --------- Co-authored-by: Peter Harrison --- .github/workflows/codeql-codescan.yml | 2 +- .github/workflows/pull-request.yml | 14 +++++++------- .github/workflows/push.yml | 16 ++++++++-------- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/.github/workflows/codeql-codescan.yml b/.github/workflows/codeql-codescan.yml index a5cc559e65..e9eb5c5d49 100644 --- a/.github/workflows/codeql-codescan.yml +++ b/.github/workflows/codeql-codescan.yml @@ -28,7 +28,7 @@ jobs: language: [ 'javascript' ] steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Initialize CodeQL uses: github/codeql-action/init@v2 diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index b6d7c42a89..eec15f2817 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -25,7 +25,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout the Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install Dependencies run: npm install @@ -68,10 +68,10 @@ jobs: # needs: Code-Quality-Checks steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v5 with: python-version: 3.9 @@ -85,7 +85,7 @@ jobs: needs: [Code-Quality-Checks] steps: - name: Checkout the Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install Dependencies run: npm install @@ -107,7 +107,7 @@ jobs: done - name: Present and Upload coverage to Codecov as ${{env.CODECOV_UNIQUE_NAME}} - uses: codecov/codecov-action@v3 + uses: codecov/codecov-action@v4 with: token: ${{ secrets.CODECOV_TOKEN }} verbose: true @@ -125,10 +125,10 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout the Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up Node.js - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: '20.x' diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b73c283aaf..d9f70f63a7 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -26,14 +26,14 @@ jobs: matrix: node-version: [20.x] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - name: Cache node modules id: cache-npm - uses: actions/cache@v3 + uses: actions/cache@v4 env: cache-name: cache-node-modules with: @@ -51,7 +51,7 @@ jobs: run: npm install - run: npm run test -- --watchAll=false --coverage - name: Present and upload coverage to Codecov as ${{env.CODECOV_UNIQUE_NAME}} - uses: codecov/codecov-action@v3 + uses: codecov/codecov-action@v4 with: token: ${{ secrets.CODECOV_TOKEN }} verbose: true @@ -63,7 +63,7 @@ jobs: if: github.ref == 'refs/heads/develop' steps: - name: Checkout the Repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 # with: # ref: develop @@ -77,7 +77,7 @@ jobs: - name: Restore node_modules from cache id: cache-npm - uses: actions/cache@v3 + uses: actions/cache@v4 env: cache-name: cache-node-modules with: @@ -154,7 +154,7 @@ jobs: needs: Generate-Documentation steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: persist-credentials: false token: ${{ secrets.TALAWA_DOCS_SYNC }} @@ -170,7 +170,7 @@ jobs: if: github.ref == 'refs/heads/automated-docs' runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dmnemec/copy_file_to_another_repo_action@v1.1.1 env: API_TOKEN_GITHUB: ${{secrets.TALAWA_DOCS_SYNC}}