11version : 2.1
22
3+ orbs :
4+ code-infra : https://raw.githubusercontent.com/mui/mui-public/refs/heads/ci-orb/.circleci/orbs/code-infra.yaml
5+
36parameters :
47 browserstack-force :
58 description : Whether to force browserstack usage. We have limited resources on browserstack so the pipeline might decide to skip browserstack if this parameter isn't set to true.
@@ -89,6 +92,21 @@ commands:
8992 else
9093 pnpm install
9194 fi
95+ linting :
96+ description : ' Runs linters'
97+ steps :
98+ - run :
99+ name : ESLint
100+ command : pnpm eslint:ci
101+ - run :
102+ name : Stylelint
103+ command : pnpm stylelint
104+ - run :
105+ name : Lint Markdown
106+ command : pnpm markdownlint
107+ - run :
108+ name : Lint writing style
109+ command : pnpm valelint
92110
93111jobs :
94112 test_unit :
@@ -117,25 +135,7 @@ jobs:
117135 steps :
118136 - checkout
119137 - install_js
120- - run :
121- name : ' `pnpm prettier` changes committed?'
122- command : |
123- # #target-branch-reference
124- if [[ $(git diff --name-status master | grep pnpm-lock) == "" ]];
125- then
126- pnpm prettier --check
127- else
128- pnpm exec prettier --check . --ignore-path .lintignore
129- fi
130- - run :
131- name : ESLint
132- command : pnpm eslint:ci
133- - run :
134- name : Stylelint
135- command : pnpm stylelint
136- - run :
137- name : Lint Markdown
138- command : pnpm markdownlint
138+ - code-infra/run-linters
139139 test_static :
140140 << : *default-job
141141 steps :
@@ -151,6 +151,16 @@ jobs:
151151 else
152152 pnpm dedupe --check
153153 fi
154+ - run :
155+ name : ' `pnpm prettier` changes committed?'
156+ command : |
157+ # #target-branch-reference
158+ if [[ $(git diff --name-status master | grep pnpm-lock) == "" ]];
159+ then
160+ pnpm prettier --check
161+ else
162+ pnpm exec prettier --check . --ignore-path .lintignore
163+ fi
154164 - run :
155165 name : Generate the documentation
156166 command : pnpm docs:api
0 commit comments