2020-06-15 16:29:31 +00:00
|
|
|
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
|
|
|
|
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
|
|
|
|
|
|
|
|
name: Build and Publish
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ master ]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
publish:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- uses: actions/setup-node@v1
|
|
|
|
with:
|
|
|
|
node-version: 12
|
|
|
|
registry-url: https://registry.npmjs.org/
|
|
|
|
- name: Build and WNS publish
|
|
|
|
run: |
|
|
|
|
git config --global user.email "npm@dxos.network"
|
2020-06-23 14:19:01 +00:00
|
|
|
git config --global user.name "DXOS"
|
2020-06-15 16:29:31 +00:00
|
|
|
|
|
|
|
yarn install
|
|
|
|
yarn build
|
|
|
|
yarn test
|
|
|
|
yarn lint
|
|
|
|
|
|
|
|
# Uncomment for NPM publishing.
|
|
|
|
npm whoami
|
|
|
|
yarn lerna publish -y prerelease --dist-tag="beta" --force-publish
|
|
|
|
|
|
|
|
# Publish to WNS
|
2020-08-27 18:18:20 +00:00
|
|
|
yarn wire profile init --name $WIRE_PROFILE --template-url https://git.io/JUkhm
|
2020-06-15 16:29:31 +00:00
|
|
|
scripts/deploy_apps_to_wns.sh
|
|
|
|
env:
|
|
|
|
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
|
|
|
|
WIRE_WNS_USER_KEY: ${{secrets.wns_user_key}}
|
|
|
|
WIRE_WNS_BOND_ID: ${{secrets.wns_bond_id}}
|
|
|
|
WIRE_PROFILE: ci
|