File tree 5 files changed +41
-54
lines changed
5 files changed +41
-54
lines changed Original file line number Diff line number Diff line change @@ -5,5 +5,3 @@ FROM mcr.microsoft.com/devcontainers/base:alpine-${ALPINE_VERSION}
5
5
6
6
ARG NODE_VERSION
7
7
RUN apk update && apk add --no-cache nodejs=${NODE_VERSION} npm
8
-
9
- WORKDIR /workspaces/datc
Original file line number Diff line number Diff line change 1
- NODE_VERSION = 20.15
2
- UBUNTU_VERSION = 20.04
1
+ NODE_VERSION = 20.15
Original file line number Diff line number Diff line change 1
- name : Storybook to GitHub Pages Pipeline
1
+ name : Continuous Deployment Pipeline
2
+
3
+ permissions :
4
+ contents : write
5
+ pages : write
6
+ id-token : write
2
7
3
8
on :
4
9
push :
5
10
branches :
6
11
- production
7
12
8
- permissions :
9
- contents : read
10
- pages : write
11
- id-token : write
12
-
13
13
concurrency :
14
14
group : " pages"
15
15
cancel-in-progress : true
16
16
17
17
jobs :
18
- deploy :
18
+ deploy-storybook-to-github-pages :
19
19
environment :
20
20
name : github-pages
21
21
url : ${{ steps.deployment.outputs.page_url }}
50
50
- name : Deploy to GitHub Pages
51
51
id : deployment
52
52
uses : actions/deploy-pages@v4
53
+
54
+ publish-package-to-npm :
55
+ runs-on : ubuntu-latest
56
+ steps :
57
+ - uses : actions/checkout@v4
58
+ with :
59
+ fetch-depth : 0
60
+ token : ${{ secrets.GITHUB_TOKEN }}
61
+
62
+ - name : Setup Node.js
63
+ uses : actions/setup-node@v4
64
+ with :
65
+ node-version : ${{ env.NODE_VERSION }}
66
+ registry-url : " https://registry.npmjs.org"
67
+
68
+ - name : Install dependencies
69
+ run : npm ci
70
+
71
+ - name : Get version
72
+ id : package-version
73
+ run : echo "version=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT
74
+
75
+ - name : Create and push tag
76
+ run : |
77
+ git tag v${{ steps.package-version.outputs.version }}
78
+ git push origin v${{ steps.package-version.outputs.version }}
79
+
80
+ - name : Publish to NPM
81
+ run : npm publish
82
+ env :
83
+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
- name : Version Check
1
+ name : Versioning Pipeline
2
2
3
3
on :
4
4
pull_request :
5
5
branches :
6
6
- production
7
7
8
8
jobs :
9
- version- check :
9
+ check :
10
10
runs-on : ubuntu-latest
11
11
12
12
steps :
You can’t perform that action at this time.
0 commit comments