Skip to content
This repository was archived by the owner on Aug 22, 2022. It is now read-only.

Commit 1ba5529

Browse files
committed
Add Workflows
1 parent 28dfbd6 commit 1ba5529

File tree

2 files changed

+74
-0
lines changed

2 files changed

+74
-0
lines changed

.github/workflows/publish-to-gpr.yaml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Publish To GPR
2+
on:
3+
push:
4+
branches:
5+
- master
6+
workflow_dispatch:
7+
jobs:
8+
publish-to-gpr:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout
12+
uses: actions/checkout@v1
13+
- name: Use Node.js And Setup .npmrc
14+
uses: actions/setup-node@v1
15+
with:
16+
node-version: '12.x'
17+
registry-url: 'https://npm.pkg.github.com'
18+
scope : '@neos21'
19+
always-auth : true
20+
env :
21+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
22+
- name: Can Publish
23+
run : npx can-npm-publish --verbose
24+
env :
25+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26+
- name: Install
27+
run : npm install
28+
env :
29+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30+
- name: Build
31+
run : npm run build --if-present
32+
env :
33+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34+
- name: Publish
35+
run : npm publish --access=public
36+
env :
37+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/publish-to-npm.yaml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Publish To npm
2+
on:
3+
push:
4+
branches:
5+
- master
6+
workflow_dispatch:
7+
jobs:
8+
publish-to-npm:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout
12+
uses: actions/checkout@v1
13+
- name: Use Node.js And Setup .npmrc
14+
uses: actions/setup-node@v1
15+
with:
16+
node-version: '12.x'
17+
registry-url: 'https://registry.npmjs.org'
18+
scope : '@neos21'
19+
always-auth : true
20+
env :
21+
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
22+
- name: Can Publish
23+
run : npx can-npm-publish --verbose
24+
env :
25+
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
26+
- name: Install
27+
run : npm install
28+
env :
29+
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
30+
- name: Build
31+
run : npm run build --if-present
32+
env :
33+
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
34+
- name: Publish
35+
run : npm publish --access=public
36+
env :
37+
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}

0 commit comments

Comments
 (0)