From f40e3da52e61235d541cf13d37a75629d14a5226 Mon Sep 17 00:00:00 2001 From: Emily Rockman Date: Fri, 22 Mar 2024 14:07:53 -0500 Subject: [PATCH 1/2] use issue context --- .github/workflows/docs-issue.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs-issue.yml b/.github/workflows/docs-issue.yml index da1659f957c..d1b387455e5 100644 --- a/.github/workflows/docs-issue.yml +++ b/.github/workflows/docs-issue.yml @@ -32,7 +32,7 @@ jobs: if: | (github.event.issue.state == 'closed' && github.event.issue.state_reason == 'completed' && - contains( github.event.pull_request.labels.*.name, 'user docs')) + contains( github.event.issue.labels.*.name, 'user docs')) uses: dbt-labs/actions/.github/workflows/open-issue-in-repo.yml@main with: issue_repository: "dbt-labs/docs.getdbt.com" From b02cbc50e4f31982e8ba446eb03a8100bfdb55fc Mon Sep 17 00:00:00 2001 From: Emily Rockman Date: Fri, 22 Mar 2024 14:53:58 -0500 Subject: [PATCH 2/2] more workding cleanup --- .github/workflows/docs-issue.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/docs-issue.yml b/.github/workflows/docs-issue.yml index d1b387455e5..a0c093832fc 100644 --- a/.github/workflows/docs-issue.yml +++ b/.github/workflows/docs-issue.yml @@ -1,5 +1,5 @@ # **what?** -# Open an issue in docs.getdbt.com when a PR is labeled `user docs` +# Open an issue in docs.getdbt.com when an issue is labeled `user docs` and closed as completed # **why?** # To reduce barriers for keeping docs up to date @@ -8,8 +8,8 @@ # When an issue is labeled `user docs` and is closed as completed. Can be labeled before or after the issue is closed. -name: Open issues in docs.getdbt.com repo when a PR is labeled -run-name: "Open an issue in docs.getdbt.com for PR #${{ github.event.pull_request.number }}" +name: Open issues in docs.getdbt.com repo when an issue is labeled +run-name: "Open an issue in docs.getdbt.com for issue #${{ github.event.issue.number }}" on: issues: @@ -36,6 +36,6 @@ jobs: uses: dbt-labs/actions/.github/workflows/open-issue-in-repo.yml@main with: issue_repository: "dbt-labs/docs.getdbt.com" - issue_title: "Docs Changes Needed from ${{ github.event.repository.name }} PR #${{ github.event.pull_request.number }}" + issue_title: "Docs Changes Needed from ${{ github.event.repository.name }} Issue #${{ github.event.issue.number }}" issue_body: "At a minimum, update body to include a link to the page on docs.getdbt.com requiring updates and what part(s) of the page you would like to see updated." secrets: inherit