Skip to content

Commit

Permalink
Merge pull request #558 from chocolatey/repo-sync/github/default
Browse files Browse the repository at this point in the history
(maint) synced file(s) with chocolatey/.github
  • Loading branch information
pauby authored Feb 13, 2024
2 parents 8b503bf + 04e6f7f commit 4299cfa
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 4 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/label-sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Sync labels
on:
workflow_dispatch:
schedule:
# Run at the end of the day (most likely UTC)
- cron: "0 0 * * *"

jobs:
labels:
# We use ubuntu as the image, as it is typically faster and cheaper (on private repos).
runs-on: ubuntu-latest

steps:
# uncomment the uses line if additional configuration in the current
# repository is used.
#- uses: actions/[email protected]
- uses: EndBug/[email protected]
with:
config-file: |
https://raw.githubusercontent.com/chocolatey/.github/main/.github/labels.yml
request-token: ${{ secrets.SYNC_TOKEN }} # Used when getting the config files.
delete-other-labels: false # After initial run, and verification change this to true
dry-run: false
token: ${{ secrets.SYNC_TOKEN }} # Used when updating the labels on the repository.
4 changes: 2 additions & 2 deletions .templates/default/issue-note.sbn
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{
if issue_label == "Bug" || issue_label == "Bug Fix" || issue_label == "Bug Fixes"
}}- Fix - {{ issue.title }} - see [#{{ issue.number }}]({{ issue.html_url }}).
}}- Fix - {{ issue.title }} - see [#{{ issue.public_number }}]({{ issue.html_url }}).
{{ else
}}- {{ issue.title }} - see [#{{ issue.number }}]({{ issue.html_url }}).
}}- {{ issue.title }} - see [#{{ issue.public_number }}]({{ issue.html_url }}).
{{ end -}}
4 changes: 2 additions & 2 deletions .templates/default/release-info.sbn
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{{
if issues.count > 0
if commits.count > 0
}}As part of this release we had [{{ commits.count }} {{ commits.count | string.pluralize "commit" "commits" }}]({{ commits.html_url }}) which resulted in [{{ issues.count }} {{ issues.count | string.pluralize "issue" "issues" }}]({{ milestone.target.html_url }}?closed=1) being closed.
}}As part of this release we had [{{ commits.count }} {{ commits.count | string.pluralize "commit" "commits" }}]({{ commits.html_url }}) which resulted in [{{ issues.count }} {{ issues.count | string.pluralize "issue" "issues" }}]({{ milestone.target.html_url }}?{{ milestone.query_string }}) being closed.
{{ else
}}As part of this release we had [{{ issues.count }} {{ issues.count | string.pluralize "issue" "issues" }}]({{ milestone.target.html_url }}?closed=1) closed.
}}As part of this release we had [{{ issues.count }} {{ issues.count | string.pluralize "issue" "issues" }}]({{ milestone.target.html_url }}?{{ milestone.query_string }}) closed.
{{ end
else if commits.count > 0
}}As part of this release we had [{{ commits.count }} {{ commits.count | string.pluralize "commit" "commits" }}]({{ commits.html_url }}).
Expand Down

0 comments on commit 4299cfa

Please sign in to comment.