Skip to content

Commit 4a4a675

Browse files
author
Sam Robson
authored
Merge pull request #29 from gocardless/sam-robson-publish-package
fix: build the package before publishing in CI
2 parents eb55d05 + 7806447 commit 4a4a675

File tree

3 files changed

+13
-164
lines changed

3 files changed

+13
-164
lines changed

.circleci/config.yml

Lines changed: 0 additions & 157 deletions
This file was deleted.

.github/workflows/build.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
name: build
22
on: push
33

4+
permissions:
5+
packages: write
6+
contents: read
7+
48
jobs:
59
build_and_lint:
610
runs-on: ubuntu-latest
@@ -44,10 +48,12 @@ jobs:
4448
path: node_modules
4549
- name: Install Dependencies
4650
run: npm install
47-
env:
48-
NODE_AUTH_TOKEN: ${{ secrets.ROBOT_PACKAGE_WRITER }}
51+
- name: Build
52+
run: npm run build
4953
- name: Publish package
5054
run: npm publish --access=public
55+
env:
56+
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
5157

5258
storybook_publish:
5359
if: github.ref == 'refs/heads/master'

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
{
22
"name": "@gocardless/react-dropin",
3-
"version": "0.3.2",
3+
"version": "0.3.3",
44
"description": "React bindings to the GoCardless Dropin checkout flow",
5+
"repository": "[email protected]:gocardless/react-dropin.git",
56
"main": "dist/index.js",
67
"types": "dist/index.d.ts",
78
"module": "dist/index.esm.js",
@@ -11,17 +12,16 @@
1112
"README.md",
1213
"LICENSE"
1314
],
15+
"publishConfig": {
16+
"registry": "https://npm.pkg.github.com/gocardless"
17+
},
1418
"scripts": {
1519
"build": "rm -rf dist && rollup -c",
1620
"lint": "eslint '{src,examples}/**/*.{ts,tsx,js,jsx}' --ignore-path .gitignore",
1721
"lint:fix": "eslint --fix '{src,examples}/**/*.{ts,tsx,js,jsx}' --ignore-path .gitignore",
1822
"storybook": "start-storybook -p 6006",
1923
"build-storybook": "build-storybook -o dist/storybook"
2024
},
21-
"repository": {
22-
"type": "git",
23-
"url": "git+https://github.com/gocardless/react-gocardless-dropin.git"
24-
},
2525
"keywords": [
2626
"checkout",
2727
"payments"

0 commit comments

Comments
 (0)