forked from prettier/prettier
-
-
Notifications
You must be signed in to change notification settings - Fork 3
98 lines (77 loc) · 2.3 KB
/
lint.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: Lint
on:
push:
branches:
- main
- patch-release
- next
pull_request:
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Setup Node.js
uses: actions/[email protected]
with:
cache: "yarn"
- name: Install Dependencies
run: yarn install --immutable
- name: Check Dependencies
run: yarn lint:deps
- name: Check JSDoc Types
run: yarn lint:typecheck
- name: Lint ESLint
run: yarn lint:eslint
- name: Lint Prettier
run: yarn lint:prettier
- name: Spellcheck
run: yarn lint:spellcheck
- name: Lint Changelog
run: yarn lint:changelog
- name: Lint docs code block
# TODO: Lint files in `website/versioned_docs/version-stable` too
run: yarn "docs/**/*.md"
env:
# Make Prettier throws on embeded format
PRETTIER_DEBUG: true
- name: Lint workflow files
run: |
bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
./actionlint -color
shell: bash
- name: Validate renovate config
run: npx --package renovate -c renovate-config-validator
- name: Run yarn (/)
run: |
yarn
yarn dedupe --check
- name: Run yarn (/website)
run: |
yarn
yarn dedupe --check
working-directory: website
- name: Run yarn (/scripts/release)
run: |
yarn
yarn dedupe --check
working-directory: scripts/release
- name: Run yarn (/scripts/tools/bundle-test)
run: |
yarn
yarn dedupe --check
working-directory: scripts/tools/bundle-test
- name: Run yarn (/scripts/tools/eslint-plugin-prettier-internal-rules)
run: |
yarn
yarn dedupe --check
working-directory: scripts/tools/eslint-plugin-prettier-internal-rules
- name: Check File Changes
run: echo "Listing changed files:" && git diff --name-only --exit-code && echo "No files changed during lint."