Skip to content

Commit b20b421

Browse files
committed
links.yml github workflow changes
Signed-off-by: kohinoor98 <[email protected]>
1 parent dcd2eca commit b20b421

File tree

1 file changed

+20
-8
lines changed

1 file changed

+20
-8
lines changed

.github/workflows/links.yml

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,41 @@
1-
name: Link Checker and ESLint Run
1+
name: Link Checker and ESLint
22
on:
33
push:
44
branches: [main]
55
pull_request:
66
branches: [main]
77

88
jobs:
9-
linkchecker:
9+
lint-and-link-check:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v2
12+
- name: Checkout Repository
13+
uses: actions/checkout@v2
1314

14-
- name: Set up Node.js
15-
uses: actions/setup-node@v2
15+
- name: Setup Node
16+
uses: actions/setup-node@v3
1617
with:
17-
node-version: "18"
18+
node-version-file: ".nvmrc" # Assuming you have a .nvmrc file with the Node version
19+
registry-url: "https://registry.npmjs.org"
20+
21+
- name: Install Yarn
22+
# Use bash to avoid having a Windows/Linux specific step
23+
shell: bash
24+
run: |
25+
YARN_VERSION=$(node -p "require('./package.json').engines.yarn")
26+
echo "Installing yarn@$YARN_VERSION"
27+
npm i -g yarn@$YARN_VERSION
28+
29+
- run: node -v
30+
- run: yarn -v
1831

1932
- name: Install Dependencies
2033
run: yarn install
2134

22-
- name: Run ESLint Run
35+
- name: Run ESLint
2336
run: yarn eslint:run
2437

2538
- name: lychee Link Checker
26-
id: lychee
2739
uses: lycheeverse/lychee-action@master
2840
with:
2941
args: --accept=200,403,429 --exclude=localhost "**/*.html" "**/*.md" "**/*.txt" "**/*.json"

0 commit comments

Comments
 (0)