forked from pantsbuild/pants
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Automate Slack release announcement. (pantsbuild#19411)
A future change will do the same for email.
- Loading branch information
Showing
3 changed files
with
61 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -299,6 +299,18 @@ jobs: | |
packages-dir: dest/pypi_release | ||
password: ${{ secrets.PANTSBUILD_PYPI_API_TOKEN }} | ||
skip-existing: true | ||
- name: Generate announcement | ||
run: './pants run src/python/pants_release/generate_release_announcement.py -- | ||
--channel=slack >> ${{ runner.temp }}/slack_announcement.json | ||
' | ||
- env: | ||
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} | ||
name: Announce to Slack | ||
uses: slackapi/[email protected] | ||
with: | ||
channel-id: C18RRR4JK | ||
payload-file-path: ${{ runner.temp }}/slack_announcement.json | ||
- env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1091,6 +1091,24 @@ def release_jobs_and_inputs() -> tuple[Jobs, dict[str, Any]]: | |
"skip-existing": True, | ||
}, | ||
}, | ||
{ | ||
"name": "Generate announcement", | ||
"run": dedent( | ||
"""\ | ||
./pants run src/python/pants_release/generate_release_announcement.py \ | ||
-- --channel=slack >> ${{ runner.temp }}/slack_announcement.json | ||
""" | ||
), | ||
}, | ||
{ | ||
"name": "Announce to Slack", | ||
"uses": "slackapi/[email protected]", | ||
"with": { | ||
"channel-id": "C18RRR4JK", | ||
"payload-file-path": "${{ runner.temp }}/slack_announcement.json", | ||
}, | ||
"env": {"SLACK_BOT_TOKEN": f"{gha_expr('secrets.SLACK_BOT_TOKEN')}"}, | ||
}, | ||
deploy_to_s3( | ||
"Deploy commit mapping to S3", | ||
scope="tags/pantsbuild.pants", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters