forked from microsoft/TypeScript
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a GH Action to file a new issue if we go a week without seeing a …
…typescript-error-deltas issue (microsoft#51271) * Add a GH Action to file a new issue if we go a week without seeing a typescript-error-deltas issue * Don't use the search terms in the title of the bug report
- Loading branch information
Showing
1 changed file
with
36 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: "typescript-error-deltas Watchdog" | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 0 * * 3' # Every Wednesday | ||
|
||
jobs: | ||
check-for-recent: | ||
runs-on: ubuntu-latest | ||
if: github.repository == 'microsoft/TypeScript' | ||
permissions: | ||
contents: read # Apparently required to create issues | ||
issues: write | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
TAGS: "@RyanCavanaugh @DanielRosenwasser @amcasey" | ||
steps: | ||
- name: NewErrors | ||
run: | # --json and --jq prints exactly one issue number per line of output | ||
DATE=$(date --date="7 days ago" --iso-8601) | ||
gh issue list --repo microsoft/typescript --search "[NewErrors] created:>=$DATE" --state all --json number --jq ".[].number" \ | ||
| grep -qe "[0-9]" \ | ||
|| gh issue create --repo ${{ github.repository }} --title "No NewErrors issue since $DATE" --body "$TAGS Please check the [pipeline](https://typescript.visualstudio.com/TypeScript/_build?definitionId=48)." | ||
- name: ServerErrors TS | ||
run: | | ||
DATE=$(date --date="7 days ago" --iso-8601) | ||
gh issue list --repo microsoft/typescript --search "[ServerErrors][TypeScript] created:>=$DATE" --state all --json number --jq ".[].number" \ | ||
| grep -qe "[0-9]" \ | ||
|| gh issue create --repo ${{ github.repository }} --title "No TypeScript ServerErrors issue since $DATE" --body "$TAGS Please check the [pipeline](https://typescript.visualstudio.com/TypeScript/_build?definitionId=59)." | ||
- name: ServerErrors JS | ||
run: | | ||
DATE=$(date --date="7 days ago" --iso-8601) | ||
gh issue list --repo microsoft/typescript --search "[ServerErrors][JavaScript] created:>=$DATE" --state all --json number --jq ".[].number" \ | ||
| grep -qe "[0-9]" \ | ||
|| gh issue create --repo ${{ github.repository }} --title "No JavaScript ServerErrors issue since $DATE" --body "$TAGS Please check the [pipeline](https://typescript.visualstudio.com/TypeScript/_build?definitionId=58)." |