Skip to content

Commit

Permalink
Remove other unintentional changes from cherry picking.
Browse files Browse the repository at this point in the history
  • Loading branch information
desrosj committed Oct 21, 2022
1 parent 1d70562 commit 2bef637
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 62 deletions.
47 changes: 0 additions & 47 deletions .github/workflows/failed-workflow.yml

This file was deleted.

23 changes: 10 additions & 13 deletions .github/workflows/slack-notifications.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,9 @@ jobs:
steps:
- name: Determine the status of the previous attempt
id: previous-attempt-result
uses: actions/github-script@100527700e8b29ca817ac0e0dfbfc5e8ff38edda # v6.3.2
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
uses: actions/github-script@9ac08808f993958e9de277fe43a64532a609130e # v6.0.0
with:
retries: 2
retry-exempt-status-codes: 418
script: |
const workflow_run = await github.rest.actions.getWorkflowRun({
owner: context.repo.owner,
Expand Down Expand Up @@ -125,15 +124,13 @@ jobs:
- name: Store previous conclusion as an output
id: previous-conclusion
run: echo "previous_conclusion=${{ steps.previous-attempt-result.outputs.result }}" >> $GITHUB_OUTPUT
run: echo "::set-output name=previous_conclusion::${{ steps.previous-attempt-result.outputs.result }}"

- name: Get the commit message
id: current-commit-message
uses: actions/github-script@100527700e8b29ca817ac0e0dfbfc5e8ff38edda # v6.3.2
uses: actions/github-script@9ac08808f993958e9de277fe43a64532a609130e # v6.0.0
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }}
with:
retries: 2
retry-exempt-status-codes: 418
script: |
const commit_details = await github.rest.repos.getCommit({
owner: context.repo.owner,
Expand All @@ -149,11 +146,11 @@ jobs:
${{ github.event_name == 'workflow_run' && github.event.workflow_run.head_commit.message || ( github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' ) && fromJson( steps.current-commit-message.outputs.result ) || github.event.head_commit.message }}
EOF
)
echo "commit_message_escaped=${COMMIT_MESSAGE}" >> $GITHUB_OUTPUT
echo "::set-output name=commit_message_escaped::${COMMIT_MESSAGE}"
- name: Construct payload and store as an output
id: create-payload
run: echo "payload={\"workflow_name\":\"${{ github.workflow }}\",\"ref_name\":\"${{ env.CURRENT_BRANCH }}\",\"run_url\":\"https://github.com/WordPress/wordpress-develop/actions/runs/${{ github.run_id }}/attempts/${{ github.run_attempt }}\",\"commit_message\":\"${{ steps.commit-message.outputs.commit_message_escaped }}\"}" >> $GITHUB_OUTPUT
run: echo "::set-output name=payload::{\"workflow_name\":\"${{ github.event_name == 'workflow_run' && github.event.workflow_run.name || github.workflow }}\",\"ref_name\":\"${{ env.CURRENT_BRANCH }}\",\"run_url\":\"https://github.com/WordPress/wordpress-develop/actions/runs/${{ github.event_name == 'workflow_run' && github.event.workflow_run.id || github.run_id }}\",\"commit_message\":\"${{ steps.commit-message.outputs.commit_message_escaped }}\"}"

# Posts notifications when a workflow fails.
failure:
Expand All @@ -165,7 +162,7 @@ jobs:

steps:
- name: Post failure notifications to Slack
uses: slackapi/slack-github-action@007b2c3c751a190b6f0f040e47ed024deaa72844 # v1.23.0
uses: slackapi/slack-github-action@16b6c78ee73689a627b65332b34e5d409c7299da # v1.18.0
with:
payload: ${{ needs.prepare.outputs.payload }}
env:
Expand All @@ -181,7 +178,7 @@ jobs:

steps:
- name: Post failure notifications to Slack
uses: slackapi/slack-github-action@007b2c3c751a190b6f0f040e47ed024deaa72844 # v1.23.0
uses: slackapi/slack-github-action@16b6c78ee73689a627b65332b34e5d409c7299da # v1.18.0
with:
payload: ${{ needs.prepare.outputs.payload }}
env:
Expand All @@ -197,7 +194,7 @@ jobs:

steps:
- name: Post success notifications to Slack
uses: slackapi/slack-github-action@007b2c3c751a190b6f0f040e47ed024deaa72844 # v1.23.0
uses: slackapi/slack-github-action@16b6c78ee73689a627b65332b34e5d409c7299da # v1.18.0
with:
payload: ${{ needs.prepare.outputs.payload }}
env:
Expand All @@ -213,7 +210,7 @@ jobs:

steps:
- name: Post cancelled notifications to Slack
uses: slackapi/slack-github-action@007b2c3c751a190b6f0f040e47ed024deaa72844 # v1.23.0
uses: slackapi/slack-github-action@16b6c78ee73689a627b65332b34e5d409c7299da # v1.18.0
with:
payload: ${{ needs.prepare.outputs.payload }}
env:
Expand Down
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ You will need Node and npm installed on your computer. Node is a JavaScript runt

If you are not using a package manager, see the [Node.js download page](https://nodejs.org/en/download/) for installers and binaries.

**Note:** WordPress currently only supports Node.js `14.x` and npm `6.x`.

You will also need [Docker](https://www.docker.com/products/docker-desktop) installed and running on your computer. Docker is the virtualization software that powers the local development environment. Docker can be installed just like any other regular application.

### Development Environment Commands
Expand Down

0 comments on commit 2bef637

Please sign in to comment.