forked from microsoft/TypeScript
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switch GHA workflows for LF line endings to work around dependabot bug (
- Loading branch information
1 parent
02f9ddf
commit 17a987d
Showing
11 changed files
with
543 additions
and
542 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 |
---|---|---|
@@ -1,15 +1,15 @@ | ||
--- | ||
blank_issues_enabled: false | ||
contact_links: | ||
- about: 'Please ask and answer usage questions on Stack Overflow.' | ||
name: Question | ||
url: 'https://stackoverflow.com/questions/tagged/typescript' | ||
- about: 'Alternatively, you can use the TypeScript Community Discord.' | ||
name: Chat | ||
url: 'https://discord.gg/typescript' | ||
- about: 'Please check the FAQ before filing new issues' | ||
name: 'TypeScript FAQ' | ||
url: 'https://github.com/microsoft/TypeScript/wiki/FAQ' | ||
- about: 'Please raise issues about the site on its own repo.' | ||
name: Website | ||
url: 'https://github.com/microsoft/TypeScript-Website/issues/new' | ||
--- | ||
blank_issues_enabled: false | ||
contact_links: | ||
- about: 'Please ask and answer usage questions on Stack Overflow.' | ||
name: Question | ||
url: 'https://stackoverflow.com/questions/tagged/typescript' | ||
- about: 'Alternatively, you can use the TypeScript Community Discord.' | ||
name: Chat | ||
url: 'https://discord.gg/typescript' | ||
- about: 'Please check the FAQ before filing new issues' | ||
name: 'TypeScript FAQ' | ||
url: 'https://github.com/microsoft/TypeScript/wiki/FAQ' | ||
- about: 'Please raise issues about the site on its own repo.' | ||
name: Website | ||
url: 'https://github.com/microsoft/TypeScript-Website/issues/new' |
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 |
---|---|---|
@@ -1,49 +1,49 @@ | ||
name: Close issues | ||
|
||
on: | ||
schedule: | ||
- cron: '0 1 * * *' | ||
workflow_dispatch: | ||
|
||
permissions: | ||
contents: read | ||
|
||
# Ensure scripts are run with pipefail. See: | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
close-issues: | ||
runs-on: ubuntu-latest | ||
if: github.repository == 'microsoft/TypeScript' | ||
permissions: | ||
contents: read # Apparently required to create issues | ||
issues: write | ||
|
||
steps: | ||
- name: Close issues | ||
env: | ||
GH_TOKEN: ${{ secrets.TS_BOT_GITHUB_TOKEN }} | ||
run: | | ||
DATE=$(date --date='2 days ago' --iso-8601) | ||
close_issues() { | ||
echo "Closing issues marked as '$1'." | ||
for issue in $(gh issue list --limit 100 --label "$1" --repo ${{ github.repository }} --state open --search "updated:<$DATE" --json number --jq '.[].number'); do | ||
echo "Closing https://github.com/${{ github.repository }}/issues/$issue" | ||
gh issue close $issue --repo ${{ github.repository }} --reason "not planned" --comment "This issue has been marked as \"$1\" and has seen no recent activity. It has been automatically closed for house-keeping purposes." | ||
done | ||
} | ||
close_issues "Duplicate" | ||
close_issues "Unactionable" | ||
close_issues "Not a Defect" | ||
close_issues "External" | ||
close_issues "Working as Intended" | ||
close_issues "Question" | ||
close_issues "Out of Scope" | ||
close_issues "Declined" | ||
close_issues "Won't Fix" | ||
close_issues "Too Complex" | ||
name: Close issues | ||
|
||
on: | ||
schedule: | ||
- cron: '0 1 * * *' | ||
workflow_dispatch: | ||
|
||
permissions: | ||
contents: read | ||
|
||
# Ensure scripts are run with pipefail. See: | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
close-issues: | ||
runs-on: ubuntu-latest | ||
if: github.repository == 'microsoft/TypeScript' | ||
permissions: | ||
contents: read # Apparently required to create issues | ||
issues: write | ||
|
||
steps: | ||
- name: Close issues | ||
env: | ||
GH_TOKEN: ${{ secrets.TS_BOT_GITHUB_TOKEN }} | ||
run: | | ||
DATE=$(date --date='2 days ago' --iso-8601) | ||
close_issues() { | ||
echo "Closing issues marked as '$1'." | ||
for issue in $(gh issue list --limit 100 --label "$1" --repo ${{ github.repository }} --state open --search "updated:<$DATE" --json number --jq '.[].number'); do | ||
echo "Closing https://github.com/${{ github.repository }}/issues/$issue" | ||
gh issue close $issue --repo ${{ github.repository }} --reason "not planned" --comment "This issue has been marked as \"$1\" and has seen no recent activity. It has been automatically closed for house-keeping purposes." | ||
done | ||
} | ||
close_issues "Duplicate" | ||
close_issues "Unactionable" | ||
close_issues "Not a Defect" | ||
close_issues "External" | ||
close_issues "Working as Intended" | ||
close_issues "Question" | ||
close_issues "Out of Scope" | ||
close_issues "Declined" | ||
close_issues "Won't Fix" | ||
close_issues "Too Complex" |
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 |
---|---|---|
@@ -1,45 +1,45 @@ | ||
name: 'typescript-error-deltas Watchdog' | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 0 * * 3' # Every Wednesday | ||
|
||
permissions: | ||
contents: read | ||
|
||
# Ensure scripts are run with pipefail. See: | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
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: '@navya9singh @RyanCavanaugh @DanielRosenwasser' | ||
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)." | ||
name: 'typescript-error-deltas Watchdog' | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 0 * * 3' # Every Wednesday | ||
|
||
permissions: | ||
contents: read | ||
|
||
# Ensure scripts are run with pipefail. See: | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
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: '@navya9singh @RyanCavanaugh @DanielRosenwasser' | ||
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)." |
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 |
---|---|---|
@@ -1,52 +1,52 @@ | ||
name: New Release Branch | ||
|
||
on: | ||
repository_dispatch: | ||
types: [new-release-branch] | ||
|
||
permissions: | ||
contents: read | ||
|
||
# Ensure scripts are run with pipefail. See: | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | ||
with: | ||
filter: blob:none # https://github.blog/2020-12-21-get-up-to-speed-with-partial-clone-and-shallow-clone/ | ||
fetch-depth: 0 # Default is 1; need to set to 0 to get the benefits of blob:none. | ||
token: ${{ secrets.TS_BOT_GITHUB_TOKEN }} | ||
- uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65 # v4.0.0 | ||
- run: | | ||
npm --version | ||
# corepack enable npm | ||
npm install -g $(jq -r '.packageManager' < package.json) | ||
npm --version | ||
- run: | | ||
git checkout -b ${{ github.event.client_payload.branch_name }} | ||
sed -i -e 's/"version": ".*"/"version": "${{ github.event.client_payload.package_version }}"/g' package.json | ||
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' src/compiler/corePublic.ts | ||
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/typescript.d.ts | ||
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/tsserverlibrary.d.ts | ||
sed -i -e 's/const version\(: string\)\{0,1\} = `${versionMajorMinor}.0-.*`/const version = `${versionMajorMinor}.0-${{ github.event.client_payload.core_tag || 'dev' }}`/g' src/compiler/corePublic.ts | ||
npm ci | ||
npm install # update package-lock.json to ensure the version bump is included | ||
npx hereby LKG | ||
npm test | ||
git diff | ||
git add package.json package-lock.json | ||
git add src/compiler/corePublic.ts | ||
git add tests/baselines/reference/api/typescript.d.ts | ||
git add tests/baselines/reference/api/tsserverlibrary.d.ts | ||
git add --force ./lib | ||
git config user.email "[email protected]" | ||
git config user.name "TypeScript Bot" | ||
git commit -m 'Bump version to ${{ github.event.client_payload.package_version }} and LKG' | ||
git push --set-upstream origin ${{ github.event.client_payload.branch_name }} | ||
name: New Release Branch | ||
|
||
on: | ||
repository_dispatch: | ||
types: [new-release-branch] | ||
|
||
permissions: | ||
contents: read | ||
|
||
# Ensure scripts are run with pipefail. See: | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | ||
with: | ||
filter: blob:none # https://github.blog/2020-12-21-get-up-to-speed-with-partial-clone-and-shallow-clone/ | ||
fetch-depth: 0 # Default is 1; need to set to 0 to get the benefits of blob:none. | ||
token: ${{ secrets.TS_BOT_GITHUB_TOKEN }} | ||
- uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65 # v4.0.0 | ||
- run: | | ||
npm --version | ||
# corepack enable npm | ||
npm install -g $(jq -r '.packageManager' < package.json) | ||
npm --version | ||
- run: | | ||
git checkout -b ${{ github.event.client_payload.branch_name }} | ||
sed -i -e 's/"version": ".*"/"version": "${{ github.event.client_payload.package_version }}"/g' package.json | ||
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' src/compiler/corePublic.ts | ||
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/typescript.d.ts | ||
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/tsserverlibrary.d.ts | ||
sed -i -e 's/const version\(: string\)\{0,1\} = `${versionMajorMinor}.0-.*`/const version = `${versionMajorMinor}.0-${{ github.event.client_payload.core_tag || 'dev' }}`/g' src/compiler/corePublic.ts | ||
npm ci | ||
npm install # update package-lock.json to ensure the version bump is included | ||
npx hereby LKG | ||
npm test | ||
git diff | ||
git add package.json package-lock.json | ||
git add src/compiler/corePublic.ts | ||
git add tests/baselines/reference/api/typescript.d.ts | ||
git add tests/baselines/reference/api/tsserverlibrary.d.ts | ||
git add --force ./lib | ||
git config user.email "[email protected]" | ||
git config user.name "TypeScript Bot" | ||
git commit -m 'Bump version to ${{ github.event.client_payload.package_version }} and LKG' | ||
git push --set-upstream origin ${{ github.event.client_payload.branch_name }} |
Oops, something went wrong.