diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dbd8670f7..2388b7cb6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,18 +19,3 @@ jobs: run: npm run dist - name: Unit Tests ๐Ÿงช run: npm test - - name: Semantic Release โฌ†๏ธ - if: github.ref == 'refs/heads/main' - uses: cycjimmy/semantic-release-action@v3 - with: - semantic_version: 19 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - name: Build Storybook and Deploy ๐Ÿš€ - if: github.ref == 'refs/heads/main' - run: | - npm run build:storybook - npm run deploy:storybook -- --ci - env: - GH_TOKEN: ${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000..9ff6fae1c --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,30 @@ +name: Release +on: + push: + branches: [main] +jobs: + ci: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: "16" + - name: Install Dependencies ๐Ÿ”ง + run: npm install + - name: Semantic Release โฌ†๏ธ + uses: cycjimmy/semantic-release-action@v3 + with: + semantic_version: 19 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + - name: Build Storybook ๐Ÿ“š + run: | + npm run build:storybook + - name: Deploy Storybook ๐Ÿš€ + uses: JamesIves/github-pages-deploy-action@v4 + with: + folder: storybook-static + token: ${{ secrets.GITHUB_TOKEN }} + diff --git a/package-lock.json b/package-lock.json index e88df07b1..f0e80de15 100644 --- a/package-lock.json +++ b/package-lock.json @@ -46,7 +46,6 @@ "@storybook/react": "7.0.18", "@storybook/react-webpack5": "7.0.18", "@storybook/source-loader": "7.0.18", - "@storybook/storybook-deployer": "2.8.16", "@storybook/test-runner": "0.10.0", "@storybook/theming": "7.0.18", "@svgr/webpack": "7.0.0", @@ -7264,23 +7263,6 @@ "url": "https://opencollective.com/storybook" } }, - "node_modules/@storybook/storybook-deployer": { - "version": "2.8.16", - "resolved": "https://registry.npmjs.org/@storybook/storybook-deployer/-/storybook-deployer-2.8.16.tgz", - "integrity": "sha512-DRQrjyLKaRLXMYo7SNUznyGabtOLJ0b9yfBKNVMu6PsUHJifGPabXuNXmRPZ6qvyhHUSKLQgeLaX8L3Og6uFUg==", - "dev": true, - "dependencies": { - "git-url-parse": "^12.0.0", - "glob": "^7.1.3", - "parse-repo": "^1.0.4", - "shelljs": "^0.8.1", - "yargs": "^15.0.0" - }, - "bin": { - "storybook-to-aws-s3": "bin/storybook_to_aws_s3", - "storybook-to-ghpages": "bin/storybook_to_ghpages" - } - }, "node_modules/@storybook/telemetry": { "version": "7.0.18", "resolved": "https://registry.npmjs.org/@storybook/telemetry/-/telemetry-7.0.18.tgz", @@ -17112,25 +17094,6 @@ "readable-stream": "3" } }, - "node_modules/git-up": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/git-up/-/git-up-6.0.0.tgz", - "integrity": "sha512-6RUFSNd1c/D0xtGnyWN2sxza2bZtZ/EmI9448n6rCZruFwV/ezeEn2fJP7XnUQGwf0RAtd/mmUCbtH6JPYA2SA==", - "dev": true, - "dependencies": { - "is-ssh": "^1.4.0", - "parse-url": "^7.0.2" - } - }, - "node_modules/git-url-parse": { - "version": "12.0.0", - "resolved": "https://registry.npmjs.org/git-url-parse/-/git-url-parse-12.0.0.tgz", - "integrity": "sha512-I6LMWsxV87vysX1WfsoglXsXg6GjQRKq7+Dgiseo+h0skmp5Hp2rzmcEIRQot9CPA+uzU7x1x7jZdqvTFGnB+Q==", - "dev": true, - "dependencies": { - "git-up": "^6.0.0" - } - }, "node_modules/github-slugger": { "version": "1.5.0", "resolved": "https://registry.npmjs.org/github-slugger/-/github-slugger-1.5.0.tgz", @@ -18535,15 +18498,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-ssh": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/is-ssh/-/is-ssh-1.4.0.tgz", - "integrity": "sha512-x7+VxdxOdlV3CYpjvRLBv5Lo9OJerlYanjwFrPR9fuGPjCiNiCzFgAWpiLAohSbsnH4ZAys3SBh+hq5rJosxUQ==", - "dev": true, - "dependencies": { - "protocols": "^2.0.1" - } - }, "node_modules/is-stream": { "version": "2.0.1", "dev": true, @@ -27428,32 +27382,6 @@ "node": ">=0.10.0" } }, - "node_modules/parse-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/parse-path/-/parse-path-5.0.0.tgz", - "integrity": "sha512-qOpH55/+ZJ4jUu/oLO+ifUKjFPNZGfnPJtzvGzKN/4oLMil5m9OH4VpOj6++9/ytJcfks4kzH2hhi87GL/OU9A==", - "dev": true, - "dependencies": { - "protocols": "^2.0.0" - } - }, - "node_modules/parse-repo": { - "version": "1.0.4", - "dev": true, - "license": "MIT" - }, - "node_modules/parse-url": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/parse-url/-/parse-url-7.0.2.tgz", - "integrity": "sha512-PqO4Z0eCiQ08Wj6QQmrmp5YTTxpYfONdOEamrtvK63AmzXpcavIVQubGHxOEwiIoDZFb8uDOoQFS0NCcjqIYQg==", - "dev": true, - "dependencies": { - "is-ssh": "^1.4.0", - "normalize-url": "^6.1.0", - "parse-path": "^5.0.0", - "protocols": "^2.0.1" - } - }, "node_modules/parse5": { "version": "6.0.1", "dev": true, @@ -28110,12 +28038,6 @@ "react-is": "^16.13.1" } }, - "node_modules/protocols": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/protocols/-/protocols-2.0.1.tgz", - "integrity": "sha512-/XJ368cyBJ7fzLMwLKv1e4vLxOju2MNAIokcr7meSaNcVbWz/CPcW22cP04mwxOErdA5mwjA8Q6w/cdAQxVn7Q==", - "dev": true - }, "node_modules/proxy-addr": { "version": "2.0.7", "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", @@ -37571,19 +37493,6 @@ "@storybook/preview-api": "7.0.18" } }, - "@storybook/storybook-deployer": { - "version": "2.8.16", - "resolved": "https://registry.npmjs.org/@storybook/storybook-deployer/-/storybook-deployer-2.8.16.tgz", - "integrity": "sha512-DRQrjyLKaRLXMYo7SNUznyGabtOLJ0b9yfBKNVMu6PsUHJifGPabXuNXmRPZ6qvyhHUSKLQgeLaX8L3Og6uFUg==", - "dev": true, - "requires": { - "git-url-parse": "^12.0.0", - "glob": "^7.1.3", - "parse-repo": "^1.0.4", - "shelljs": "^0.8.1", - "yargs": "^15.0.0" - } - }, "@storybook/telemetry": { "version": "7.0.18", "resolved": "https://registry.npmjs.org/@storybook/telemetry/-/telemetry-7.0.18.tgz", @@ -44879,25 +44788,6 @@ } } }, - "git-up": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/git-up/-/git-up-6.0.0.tgz", - "integrity": "sha512-6RUFSNd1c/D0xtGnyWN2sxza2bZtZ/EmI9448n6rCZruFwV/ezeEn2fJP7XnUQGwf0RAtd/mmUCbtH6JPYA2SA==", - "dev": true, - "requires": { - "is-ssh": "^1.4.0", - "parse-url": "^7.0.2" - } - }, - "git-url-parse": { - "version": "12.0.0", - "resolved": "https://registry.npmjs.org/git-url-parse/-/git-url-parse-12.0.0.tgz", - "integrity": "sha512-I6LMWsxV87vysX1WfsoglXsXg6GjQRKq7+Dgiseo+h0skmp5Hp2rzmcEIRQot9CPA+uzU7x1x7jZdqvTFGnB+Q==", - "dev": true, - "requires": { - "git-up": "^6.0.0" - } - }, "github-slugger": { "version": "1.5.0", "resolved": "https://registry.npmjs.org/github-slugger/-/github-slugger-1.5.0.tgz", @@ -45825,15 +45715,6 @@ "call-bind": "^1.0.2" } }, - "is-ssh": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/is-ssh/-/is-ssh-1.4.0.tgz", - "integrity": "sha512-x7+VxdxOdlV3CYpjvRLBv5Lo9OJerlYanjwFrPR9fuGPjCiNiCzFgAWpiLAohSbsnH4ZAys3SBh+hq5rJosxUQ==", - "dev": true, - "requires": { - "protocols": "^2.0.1" - } - }, "is-stream": { "version": "2.0.1", "dev": true @@ -52169,31 +52050,6 @@ "version": "1.0.0", "dev": true }, - "parse-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/parse-path/-/parse-path-5.0.0.tgz", - "integrity": "sha512-qOpH55/+ZJ4jUu/oLO+ifUKjFPNZGfnPJtzvGzKN/4oLMil5m9OH4VpOj6++9/ytJcfks4kzH2hhi87GL/OU9A==", - "dev": true, - "requires": { - "protocols": "^2.0.0" - } - }, - "parse-repo": { - "version": "1.0.4", - "dev": true - }, - "parse-url": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/parse-url/-/parse-url-7.0.2.tgz", - "integrity": "sha512-PqO4Z0eCiQ08Wj6QQmrmp5YTTxpYfONdOEamrtvK63AmzXpcavIVQubGHxOEwiIoDZFb8uDOoQFS0NCcjqIYQg==", - "dev": true, - "requires": { - "is-ssh": "^1.4.0", - "normalize-url": "^6.1.0", - "parse-path": "^5.0.0", - "protocols": "^2.0.1" - } - }, "parse5": { "version": "6.0.1", "dev": true @@ -52654,12 +52510,6 @@ "react-is": "^16.13.1" } }, - "protocols": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/protocols/-/protocols-2.0.1.tgz", - "integrity": "sha512-/XJ368cyBJ7fzLMwLKv1e4vLxOju2MNAIokcr7meSaNcVbWz/CPcW22cP04mwxOErdA5mwjA8Q6w/cdAQxVn7Q==", - "dev": true - }, "proxy-addr": { "version": "2.0.7", "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", diff --git a/package.json b/package.json index ff9f7b58e..b3c86b1c4 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,6 @@ "build:svg": "node ./packages/icons/scripts/build.js", "clean": "rimraf dist", "create:component": "./scripts/create-component", - "deploy:storybook": "storybook-to-ghpages", "prestart": "npm run build:design-tokens && npm run build:svg", "pretest": "npm run build:design-tokens && npm run build:svg", "predist": "npm run clean && npm run build:design-tokens && npm run build:svg", @@ -88,7 +87,6 @@ "@storybook/react": "7.0.18", "@storybook/react-webpack5": "7.0.18", "@storybook/source-loader": "7.0.18", - "@storybook/storybook-deployer": "2.8.16", "@storybook/test-runner": "0.10.0", "@storybook/theming": "7.0.18", "@svgr/webpack": "7.0.0",