Skip to content

Commit

Permalink
Merge pull request #29 from gocardless/sam-robson-publish-package
Browse files Browse the repository at this point in the history
fix: build the package before publishing in CI
  • Loading branch information
Sam Robson committed Feb 8, 2023
2 parents eb55d05 + 7806447 commit 4a4a675
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 164 deletions.
157 changes: 0 additions & 157 deletions .circleci/config.yml

This file was deleted.

10 changes: 8 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: build
on: push

permissions:
packages: write
contents: read

jobs:
build_and_lint:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -44,10 +48,12 @@ jobs:
path: node_modules
- name: Install Dependencies
run: npm install
env:
NODE_AUTH_TOKEN: ${{ secrets.ROBOT_PACKAGE_WRITER }}
- name: Build
run: npm run build
- name: Publish package
run: npm publish --access=public
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}

storybook_publish:
if: github.ref == 'refs/heads/master'
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"name": "@gocardless/react-dropin",
"version": "0.3.2",
"version": "0.3.3",
"description": "React bindings to the GoCardless Dropin checkout flow",
"repository": "git@github.com:gocardless/react-dropin.git",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"module": "dist/index.esm.js",
Expand All @@ -11,17 +12,16 @@
"README.md",
"LICENSE"
],
"publishConfig": {
"registry": "https://npm.pkg.github.com/gocardless"
},
"scripts": {
"build": "rm -rf dist && rollup -c",
"lint": "eslint '{src,examples}/**/*.{ts,tsx,js,jsx}' --ignore-path .gitignore",
"lint:fix": "eslint --fix '{src,examples}/**/*.{ts,tsx,js,jsx}' --ignore-path .gitignore",
"storybook": "start-storybook -p 6006",
"build-storybook": "build-storybook -o dist/storybook"
},
"repository": {
"type": "git",
"url": "git+https://github.com/gocardless/react-gocardless-dropin.git"
},
"keywords": [
"checkout",
"payments"
Expand Down

0 comments on commit 4a4a675

Please sign in to comment.