Skip to content

Commit

Permalink
chore: update ci and package.json scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
TheSisb committed Sep 21, 2023
1 parent 21a9d62 commit 12cd5b9
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 12 deletions.
13 changes: 4 additions & 9 deletions .github/workflows/on_pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -258,8 +258,8 @@ jobs:
- name: Run tests
run: yarn test

prettier:
name: Prettier checks
format:
name: Code format checks
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
Expand Down Expand Up @@ -300,13 +300,8 @@ jobs:
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --immutable

- name: Build packages
run: yarn build
env:
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}

- name: Run prettier
run: yarn prettier
- name: Run BiomeJS + Prettier format for their respective files
run: yarn format:ci

chromatic:
name: Component Visual regression tests
Expand Down
11 changes: 11 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
**/*.ts
**/*.tsx
**/*.js
**/*.jsx
**/*.json
**/*.jsonc
**/*.css
**/*.md
**/*.mdx

node_modules
bower_components
dist
bin
__testfixtures__

packages/paste-design-tokens/docs
packages/paste-icons/cjs
packages/paste-icons/esm
packages/paste-icons/json
Expand Down
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"build:theme-designer": "yarn nx run @twilio-paste/theme-designer:build",
"build:nextjs-template": "yarn nx run @twilio-paste/nextjs-template:build",
"build:contrast-checking": "yarn nx run @twilio-paste/token-contrast-checker:build",
"pre-push": "concurrently \"yarn:lint\" \"yarn:test\" \"yarn:prettier\" \"yarn:type-check\"",
"pre-push": "concurrently \"yarn:lint\" \"yarn:test\" \"yarn:format\" \"yarn:type-check\"",
"prerelease": "yarn build && yarn lint && yarn test",
"release": "yarn changeset publish",
"release:next": "yarn lerna publish -m 'chore(release): pre release' --conventional-commits --canary --preid beta --dist-tag next",
Expand All @@ -63,8 +63,6 @@
"start:test:storybook": "start-server-and-test 'NODE_ENV=test yarn start:storybook' http://localhost:9001 'yarn test:storybook'",
"serve:website": "yarn workspace @twilio-paste/website start",
"package-size-action-build": "yarn build",
"prettier": "prettier --list-different '{.storybook,packages,templates}/**/*.{ts,tsx}'",
"prettier-clean": "prettier --write '{.storybook,packages,templates}/**/*.{ts,tsx}'",
"lint": "yarn pre-test && yarn lint:repo && yarn lint:core && yarn lint:website && yarn lint:remix && yarn lint:contrast-checker && yarn lint:nextjs-template && yarn lint:vscode-intellisense",
"lint:core": "eslint -c .eslintrc.core.js --ext .tsx,.ts ./packages/{paste-color-contrast-utils,paste-core,paste-customization,paste-design-tokens,paste-icons,paste-libraries,paste-style-props,paste-theme,paste-types,paste-utils}/**/src",
"lint:website": "eslint -c ./packages/paste-website/.eslintrc --ext .tsx,.ts ./packages/paste-website",
Expand All @@ -73,6 +71,9 @@
"lint:nextjs-template": "eslint -c ./templates/paste-nextjs-template/.eslintrc.json --ext .tsx,.ts ./templates/paste-nextjs-template",
"lint:vscode-intellisense": "eslint -c ./apps/vs-code-intellisense/.eslintrc.json --ext .tsx,.ts ./apps/vs-code-intellisense",
"lint:repo": "eslint -c .eslintrc.repo.js --ext .tsx,.ts .",
"format": "biome format ./ && prettier --list-different ./packages/",
"format:write": "biome format ./ --write",
"format:ci": "biome ci ./ --linter-enabled=false && prettier --list-different ./packages/",
"type-check": "yarn prebuild && yarn nx run-many --target=tsc",
"tsc": "echo 'Did you mean to run yarn type-check?'",
"chromatic": "chromatic",
Expand Down

0 comments on commit 12cd5b9

Please sign in to comment.