diff --git a/.github/workflows/deploy-clean.yml b/.github/workflows/deploy-clean.yml index c34f1987..06b9e794 100644 --- a/.github/workflows/deploy-clean.yml +++ b/.github/workflows/deploy-clean.yml @@ -198,7 +198,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Deployment Cleanup ${{ job.status == 'success' && '✅' || '❌' }} + ## 📦 ᲼Deployment Cleanup ᲼${{ job.status == 'success' && '✅' || '❌' }} A **successful** deployment cleanup was triggered on your repository. The history for this environment has been wiped and will no longer list previous deployments you've made. @@ -234,7 +234,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Deployment Cleanup ${{ job.status == 'success' && '✅' || '❌' }} + ## 📦 ᲼Deployment Cleanup ᲼${{ job.status == 'success' && '✅' || '❌' }} A **failed** deployment cleanup was triggered on your repository. Since the action failed; no entries of your repo's deployment history have been removed. diff --git a/.github/workflows/deploy-docker-dockerhub.yml b/.github/workflows/deploy-docker-dockerhub.yml index 12cef167..9a5a31fd 100644 --- a/.github/workflows/deploy-docker-dockerhub.yml +++ b/.github/workflows/deploy-docker-dockerhub.yml @@ -409,7 +409,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Docker › Deploy ${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` + ## 📦 ᲼Docker › Deploy ᲼${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` A new version of the docker container `${{ env.IMAGE_NAME }}` has been released from Github. The image is available at: - https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }} @@ -653,7 +653,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Docker › Deploy ${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` + ## 📦 ᲼Docker › Deploy ᲼${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` A new version of the docker container `${{ env.IMAGE_NAME }}` has been released from Github. The image is available at: - https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }} diff --git a/.github/workflows/deploy-docker-github.yml b/.github/workflows/deploy-docker-github.yml index a455bc9d..d6b205a2 100644 --- a/.github/workflows/deploy-docker-github.yml +++ b/.github/workflows/deploy-docker-github.yml @@ -407,7 +407,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Docker › Deploy ${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` + ## 📦 ᲼Docker › Deploy ᲼${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` A new version of the docker container `${{ env.IMAGE_NAME }}` has been released from Github. The image is available at: - https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }} @@ -647,7 +647,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Docker › Deploy ${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` + ## 📦 ᲼Docker › Deploy ᲼${{ job.status == 'success' && '✅' || '❌' }} › `${{ env.IMAGE_NAME }}-${{ env.IMAGE_VERSION }}` A new version of the docker container `${{ env.IMAGE_NAME }}` has been released from Github. The image is available at: - https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }} diff --git a/.github/workflows/issues-scan.yml b/.github/workflows/issues-scan.yml index 5d1ad9a2..0730d9dc 100644 --- a/.github/workflows/issues-scan.yml +++ b/.github/workflows/issues-scan.yml @@ -828,7 +828,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://cdn.pixabay.com/photo/2022/01/30/13/33/github-6980894_960_720.png' embed-description: | - ## 🎫 Issues › Scan ${{ job.status == 'success' && '✅' || '❌' }} + ## 🎫 ᲼Issues › Scan ᲼${{ job.status == 'success' && '✅' || '❌' }} **${{ job.status == 'success' && '✅ Success' || '❌ Failure' }}** › Your container just ran the `Issues › Scan` workflow. Every time this workflow is ran, your list of pull requests will be scanned to determine what files have been changed. It will scan each modified file and see if the code conforms with our rules, and will then post a status report inside the pull request that is open. @@ -879,7 +879,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://cdn.pixabay.com/photo/2022/01/30/13/33/github-6980894_960_720.png' embed-description: | - ## 🎫 Issues › Scan ${{ job.status == 'success' && '✅' || '❌' }} + ## 🎫 ᲼Issues › Scan ᲼${{ job.status == 'success' && '✅' || '❌' }} **${{ job.status == 'success' && '✅ Success' || '❌ Failure' }}** › Your container just ran the `Issues › Scan` workflow. Every time this workflow is ran, your list of pull requests will be scanned to determine what files have been changed. It will scan each modified file and see if the code conforms with our rules, and will then post a status report inside the pull request that is open. diff --git a/.github/workflows/labels-clean.yml b/.github/workflows/labels-clean.yml index a7587192..73c93ed2 100644 --- a/.github/workflows/labels-clean.yml +++ b/.github/workflows/labels-clean.yml @@ -29,6 +29,15 @@ env: BOT_NAME_DEPENDABOT: dependabot[bot] LABELS_JSON: | [ + { "name": "bug", "color": "8F1784", "description": "Default github label" }, + { "name": "documentation", "color": "8F1784", "description": "Default github label" }, + { "name": "duplicate", "color": "8F1784", "description": "Default github label" }, + { "name": "enhancement", "color": "8F1784", "description": "Default github label" }, + { "name": "good first issue", "color": "8F1784", "description": "Default github label" }, + { "name": "help wanted", "color": "8F1784", "description": "Default github label" }, + { "name": "invalid", "color": "8F1784", "description": "Default github label" }, + { "name": "question", "color": "8F1784", "description": "Default github label" }, + { "name": "wontfix", "color": "8F1784", "description": "Default github label" }, { "name": "AC › Changes Made", "color": "8F1784", "description": "Requested changes have been made and are pending a re-scan" }, { "name": "AC › Changes Required", "color": "8F1784", "description": "Requires changes to be made to the package before being accepted" }, { "name": "AC › Failed", "color": "a61f2d", "description": "Autocheck failed to run through a complete cycle, requires investigation" }, @@ -112,7 +121,7 @@ jobs: steps: # # - # [ Delete Labels ] Start + # Labels › Start # # - name: >- @@ -122,7 +131,20 @@ jobs: echo "Starting workflow" # # - # [ Delete Labels ] Checkout + # Labels › Set Env Variables + # # + + - name: >- + 🕛 Get Timestamp + id: task_label_set_timestamp + run: | + echo "NOW=$(date +'%m-%d-%Y %H:%M:%S')" >> $GITHUB_ENV + echo "NOW_SHORT=$(date +'%m-%d-%Y')" >> $GITHUB_ENV + echo "NOW_LONG=$(date +'%m-%d-%Y %H:%M')" >> $GITHUB_ENV + echo "NOW_DOCKER_LABEL=$(date +'%Y%m%d')" >> $GITHUB_ENV + + # # + # Labels › Checkout # # - name: >- @@ -133,7 +155,7 @@ jobs: fetch-depth: 0 # # - # [ Delete Labels ] Start + # Labels › Start # # - name: >- @@ -165,6 +187,7 @@ jobs: }); // const labels = JSON.parse( process.env.LABELS_JSON ); + let result = Object.keys(labels).length; for ( const label of labels ) { try @@ -181,3 +204,89 @@ jobs: console.error("Error: " + err); } } + + console.log("[Success]: Added " + result + " labels to repo"); + + return result + + # # + # Labels › Get Weekly Commits + # # + + - name: >- + 🕛 Get Weekly Commit List + id: task_label_set_weekly_commit_list + run: | + echo 'WEEKLY_COMMITS<> $GITHUB_ENV + git log --format="[\`%h\`](${{ github.server_url }}/${{ github.repository }}/commit/%H) %s - %an" --since=7.days >> $GITHUB_ENV + echo 'EOF' >> $GITHUB_ENV + + # # + # Labels › Notify Github › Success + # # + + - name: >- + 🔔 Send Discord Webhook Message (Success) + id: task_label_notify_discord_success + uses: tsickert/discord-webhook@v6.0.0 + if: success() + with: + username: 'Io' + avatar-url: 'https://i.imgur.com/8BVDkla.jpg' + webhook-url: ${{ secrets.DISCORD_WEBHOOK_CHAN_TVAPP2_WORKFLOWS }} + embed-title: "⚙️ ${{ github.workflow_ref }}" + embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" + embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' + embed-description: | + ## 🎫 ᲼Labels › Clean ᲼${{ job.status == 'success' && '✅' || '❌' }} + + A **successful** workflow has been ran to wipe all labels from your repository. + + **${{ steps.task_label_remove_run.outputs.result }}** labels have been removed. + + - Labels: `${{ steps.task_label_remove_run.outputs.result }} created` + - Workflow: `${{ github.workflow }} (#${{github.run_number}})` + - Runner: `${{ runner.name }}` + - Triggered By: `${{ github.actor }}` + - Status: `${{ job.status == 'success' && '✅ Successful' || '❌ Failed' }}` + + embed-color: ${{ job.status == 'success' && '5763719' || '15418782' }} + embed-footer-text: "Completed at ${{ env.NOW }} UTC" + embed-timestamp: "${{ env.NOW_LONG }}" + embed-author-name: "${{ github.repository_owner }}" + embed-author-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" + embed-author-icon-url: "https://avatars.githubusercontent.com/u/200161462" + + # # + # Labels › Notify Github › Failure + # # + + - name: >- + 🔔 Send Discord Webhook Message (Failure) + id: task_label_notify_discord_failure + uses: tsickert/discord-webhook@v6.0.0 + if: failure() + with: + username: 'Io' + avatar-url: 'https://i.imgur.com/8BVDkla.jpg' + webhook-url: ${{ secrets.DISCORD_WEBHOOK_CHAN_TVAPP2_WORKFLOWS }} + embed-title: "⚙️ ${{ github.workflow_ref }}" + embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" + embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' + embed-description: | + ## 🎫 ᲼ Labels › Clean ᲼${{ job.status == 'success' && '✅' || '❌' }} + + A **failed** attempt was made to run this workflow. No new labels have been added to your repository. + + - Labels: `${{ steps.task_label_remove_run.outputs.result }} created` + - Workflow: `${{ github.workflow }} (#${{github.run_number}})` + - Runner: `${{ runner.name }}` + - Triggered By: `${{ github.actor }}` + - Status: `${{ job.status == 'success' && '✅ Successful' || '❌ Failed' }}` + + embed-color: ${{ job.status == 'success' && '5763719' || '15418782' }} + embed-footer-text: "Completed at ${{ env.NOW }} UTC" + embed-timestamp: "${{ env.NOW_LONG }}" + embed-author-name: "${{ github.repository_owner }}" + embed-author-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" + embed-author-icon-url: "https://avatars.githubusercontent.com/u/200161462" diff --git a/.github/workflows/labels-create.yml b/.github/workflows/labels-create.yml index 7f35b1e0..d4a1a4eb 100644 --- a/.github/workflows/labels-create.yml +++ b/.github/workflows/labels-create.yml @@ -167,7 +167,7 @@ jobs: github-token: ${{ secrets.ADMINSERV_TOKEN_CL }} script: | const labels = JSON.parse( process.env.LABELS_JSON ); - let count = Object.keys(labels).length; + let result = Object.keys(labels).length; for ( const label of labels ) { try @@ -194,9 +194,9 @@ jobs: } } - console.log("[Success]: Added" + count + " labels to repo"); + console.log("[Success]: Added " + result + " labels to repo"); - return count + return result # # # Cleanup › Get Weekly Commits @@ -227,10 +227,11 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Labels › Create ${{ job.status == 'success' && '✅' || '❌' }} + ## 🎫 ᲼Labels › Create ᲼${{ job.status == 'success' && '✅' || '❌' }} A **successful** workflow has been ran to generate labels for your repository. - ${{ steps.task_label_verify_existing.outputs.result }} labels have been added. + + **${{ steps.task_label_verify_existing.outputs.result }}** labels have been added. - Labels: `${{ steps.task_label_verify_existing.outputs.result }} created` - Workflow: `${{ github.workflow }} (#${{github.run_number}})` @@ -262,7 +263,7 @@ jobs: embed-url: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" embed-thumbnail-url: 'https://i.imgur.com/zDIzE8T.jpg' embed-description: | - ## 📦 Labels › Create ${{ job.status == 'success' && '✅' || '❌' }} + ## 🎫 ᲼Labels › Create ᲼${{ job.status == 'success' && '✅' || '❌' }} A **failed** attempt was made to run this workflow. No new labels have been added to your repository.