-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch '1.2.latest' into user/alexander-smolyakov/backport-rele…
…ase-workflow-to-1.2.latest
- Loading branch information
Showing
3 changed files
with
197 additions
and
30 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
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 |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# **what?** | ||
# When bots create a PR, this action will add a corresponding changie yaml file to that | ||
# PR when a specific label is added. | ||
# | ||
# The file is created off a template: | ||
# | ||
# kind: <per action matrix> | ||
# body: <PR title> | ||
# time: <current timestamp> | ||
# custom: | ||
# Author: <PR User Login (generally the bot)> | ||
# Issue: 4904 | ||
# PR: <PR number> | ||
# | ||
# **why?** | ||
# Automate changelog generation for more visability with automated bot PRs. | ||
# | ||
# **when?** | ||
# Once a PR is created, label should be added to PR before or after creation. You can also | ||
# manually trigger this by adding the appropriate label at any time. | ||
# | ||
# **how to add another bot?** | ||
# Add the label and changie kind to the include matrix. That's it! | ||
# | ||
|
||
name: Bot Changelog | ||
|
||
on: | ||
pull_request: | ||
# catch when the PR is opened with the label or when the label is added | ||
types: [labeled] | ||
|
||
permissions: | ||
contents: write | ||
pull-requests: read | ||
|
||
jobs: | ||
generate_changelog: | ||
strategy: | ||
matrix: | ||
include: | ||
- label: "dependencies" | ||
changie_kind: "Dependencies" | ||
- label: "snyk" | ||
changie_kind: "Security" | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
|
||
- name: Create and commit changelog on bot PR | ||
if: ${{ contains(github.event.pull_request.labels.*.name, matrix.label) }} | ||
id: bot_changelog | ||
uses: emmyoop/changie_bot@v1.0.1 | ||
with: | ||
GITHUB_TOKEN: ${{ secrets.FISHTOWN_BOT_PAT }} | ||
commit_author_name: "Github Build Bot" | ||
commit_author_email: "<buildbot@fishtownanalytics.com>" | ||
commit_message: "Add automated changelog yaml from template for bot PR" | ||
changie_kind: ${{ matrix.changie_kind }} | ||
label: ${{ matrix.label }} | ||
custom_changelog_string: "custom:\n Author: ${{ github.event.pull_request.user.login }}\n PR: ${{ github.event.pull_request.number }}" |
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