-
Notifications
You must be signed in to change notification settings - Fork 22.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
110 changed files
with
2,993 additions
and
321 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,30 @@ | ||
name: Check URL issues | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- "files/**/*.md" | ||
|
||
jobs: | ||
check_url_issues: | ||
#if: github.repository == 'mdn/content' | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Node.js environment | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version-file: ".nvmrc" | ||
cache: yarn | ||
|
||
- name: Check URL deletions and broken fragments | ||
run: | | ||
echo "::add-matcher::.github/workflows/url-issues-problem-matcher.json" | ||
git fetch origin main | ||
node scripts/log-url-issues.js --workflow |
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,18 @@ | ||
{ | ||
"problemMatcher": [ | ||
{ | ||
"owner": "log-url-issues", | ||
"severity": "error", | ||
"pattern": [ | ||
{ | ||
"regexp": "^(ERROR|WARN|INFO):(.+):(\\d+):(\\d+):(.+)$", | ||
"severity": 1, | ||
"file": 2, | ||
"line": 3, | ||
"column": 4, | ||
"message": 5 | ||
} | ||
] | ||
} | ||
] | ||
} |
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,14 @@ | ||
BRANCH="$(git rev-parse --abbrev-ref HEAD)" | ||
if [[ "$BRANCH" != "main" ]]; then | ||
exit 0 | ||
fi | ||
|
||
if [ -f ".husky/_/history" ]; then | ||
lastHash=$(cat ./.husky/_/history) | ||
isUpdated=$(git diff $lastHash HEAD -- ./package.json) | ||
if [ "$isUpdated" != "" ]; then | ||
echo -e "\n⚠🔥 'package.json' has changed. Please run 'yarn install'! 🔥" | ||
fi | ||
else | ||
yarn install | ||
fi |
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,7 @@ | ||
# This script stores the 'main' branch's HEAD commit hash in .husky/_/history | ||
# The stored commit hash is used by the post-merge script .husky/post-merge | ||
|
||
BRANCH="$(git rev-parse --abbrev-ref HEAD)" | ||
if [[ "$BRANCH" == "main" ]]; then | ||
echo $(git rev-parse HEAD) > ./.husky/_/history | ||
fi |
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 |
---|---|---|
|
@@ -68,5 +68,6 @@ | |
"path": "./project-words.txt", | ||
"addWords": true | ||
} | ||
] | ||
], | ||
"enableFiletypes": ["xml"] | ||
} |
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
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
Oops, something went wrong.