diff --git a/.github/workflows/bundle_size.yml b/.github/workflows/bundle_size.yml new file mode 100644 index 00000000..ab1e30dc --- /dev/null +++ b/.github/workflows/bundle_size.yml @@ -0,0 +1,26 @@ +name: CI +on: [push] +jobs: + ci: + name: CI + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@master + + - name: Set up Node.js + uses: actions/setup-node@master + with: + node-version: 12 + + - name: Install dependencies + run: yarn + + - name: CSS Lint + run: yarn stylelint && yarn stylelint -- --report-needless-disables + + - name: Build + run: yarn dist + + - name: Reporting bundle sizes + run: script/bundle-size-report.js --all diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8c393beb..e9a10063 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,9 +25,6 @@ jobs: - name: Test run: yarn test - - name: Prepublish - run: script/prepublish - - name: Create .npmrc run: | cat << EOF > "$HOME/.npmrc" diff --git a/.npmignore b/.npmignore index 2803190a..c373e1b1 100644 --- a/.npmignore +++ b/.npmignore @@ -9,7 +9,5 @@ docs-test/ lib/ pages/ script/ -# we ignore this because everything in src/ is copied out in script/prepublish -src/ static/ tests/ diff --git a/package.json b/package.json index 67520aea..b7d6da0d 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,6 @@ "eslint": "eslint script deprecations.js lib .storybook", "eslint-docs": "eslint docs/{content,src,*.js}", "postpublish": "script/postpublish", - "prepublishOnly": "script/prepublish", "publish-storybook": "script/publish-storybook", "start": "npm run dev", "dev": "cd docs && npm install && npm run develop", diff --git a/script/prepublish b/script/prepublish deleted file mode 100755 index 4d9604c9..00000000 --- a/script/prepublish +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/bash -set -e - -# generate the build directory -npm run --silent dist - -# run the bundle size and selector diff reports -script/run-reports - -files=$(git ls-files src | sed -e 's#^src/##' | sed -e 's#/.*$##' | sort -u) -echo $files > publish-files.log -cd src -cp -rv $files .. -cd -