-
Notifications
You must be signed in to change notification settings - Fork 18
68 lines (58 loc) · 1.82 KB
/
CI-CD-Wallet-Connect-Package.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: 'CI-CD @gear-js/wallet-connect'
on:
pull_request:
branches: [main]
paths:
- utils/wallet-connect/**
push:
branches: [main]
paths:
- utils/wallet-connect/**
workflow_dispatch:
jobs:
wallet-connect-build:
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- name: Cancel previous workflow runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- name: Install NodeJS 18.x
uses: actions/[email protected]
with:
node-version: 18.x
- name: 'wallet-connect: Install dependencies'
working-directory: utils/wallet-connect
run: yarn install
- name: 'vwallet-connect: Build pkg'
working-directory: utils/wallet-connect
run: yarn run build
publish-to-npm:
runs-on: ubuntu-latest
steps:
- name: 'Checkout'
uses: actions/checkout@v2
- name: Use node 18.x
uses: actions/[email protected]
with:
node-version: 18.x
- name: '@gear-js/wallet-connect: Check pkg version'
uses: EndBug/version-check@v1
id: check_gear
with:
file-name: utils/wallet-connect/package.json
file-url: https://unpkg.com/@gear-js/wallet-connect@latest/package.json
static-checking: localIsNew
- name: '@gear-js/wallet-connect: Publish'
working-directory: utils/wallet-connect
run: |
export token=$(printenv $(printenv GITHUB_ACTOR))
yarn install
npm run build
npm config set //registry.npmjs.org/:_authToken=$token --no-workspaces
npm publish
env:
osipov-mit: ${{ secrets.OSIPOV_NPM_TOKEN }}
nikitayutanov: ${{ secrets.YUTANOV_NPM_TOKEN }}