Skip to content

Commit

Permalink
Add GitHub template and workflows needed on the default branch (mmtk#70)
Browse files Browse the repository at this point in the history
* Copy across GitHub Action workflows

* Add workflow to close stale PRs

* Add PR template

* Remove codeowners from upstream
  • Loading branch information
nickrobinson251 authored Sep 25, 2023
1 parent 426927e commit 47a7fef
Show file tree
Hide file tree
Showing 5 changed files with 65 additions and 6 deletions.
6 changes: 0 additions & 6 deletions .github/CODEOWNERS

This file was deleted.

13 changes: 13 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!---
PRs to RelationalAI/julia must be opened to the correct branch (see
https://github.com/RelationalAI/raicode/blob/master/nix/julia-version.json).
-->
## PR Description

_What does this PR do?_

## Checklist

Requirements for merging:
- [ ] I have opened an issue or PR upstream on JuliaLang/julia: <link to JuliaLang/julia>
- [ ] I have removed the `port-to-*` labels that don't apply.
19 changes: 19 additions & 0 deletions .github/workflows/LabelCheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Labels

permissions:
contents: read
on:
pull_request:
types: [labeled, unlabeled, opened, reopened, edited, synchronize]
jobs:
enforce-labels:
name: Check for blocking labels
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- uses: yogevbd/enforce-label-action@2.2.2
with:
# REQUIRED_LABELS_ANY: "bug,enhancement,skip-changelog"
# REQUIRED_LABELS_ANY_DESCRIPTION: "Select at least one label ['bug','enhancement','skip-changelog']"
BANNED_LABELS: "needs docs,needs compat annotation,needs more info,needs nanosoldier run,needs news,needs pkgeval,needs tests,DO NOT MERGE"
BANNED_LABELS_DESCRIPTION: "A PR should not be merged with `needs *` or `DO NOT MERGE` labels"
17 changes: 17 additions & 0 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# See https://github.com/actions/labeler
name: "Pull Request Labeler"
on:
pull_request_target:
types:
- opened

jobs:
triage:
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v4
with:
dot: true
16 changes: 16 additions & 0 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: "Close stale PRs"
on:
schedule:
- cron: "0 0 * * *" # every night at midnight

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v8
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-pr-message: 'This PR is stale because it has been open 30 days with no activity. Comment or remove stale label, or this PR will be closed in 5 days.'
days-before-stale: 30
days-before-close: 5
stale-pr-label: 'stale'

0 comments on commit 47a7fef

Please sign in to comment.