Update node.js.yml #857
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: eBay UI CI | |
on: | |
pull_request: | |
types: [opened, synchronize] | |
push: | |
branches: [master] | |
concurrency: | |
group: "${{ github.workflow }}-${{ github.event_name == 'pull_request_target' && github.head_ref || github.ref }}" | |
cancel-in-progress: true | |
jobs: | |
build: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@master | |
- uses: actions/setup-node@master | |
with: | |
node-version: "18" | |
- uses: webfactory/ssh-agent@v0.5.4 | |
with: | |
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }} | |
- run: npm i | |
- run: npm run build:ci | |
env: | |
BROWSERSTACK_USER: ${{ secrets.BROWSERSTACK_USERNAME }} | |
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }} | |
BROWSERSTACK_PROJECT_NAME: "CoreUI" | |
BUILD_NUMBER: CI | |
REPO_SLUG: ebay/ebayui-core | |
- uses: coverallsapp/github-action@master | |
if: ${{ success() }} | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
path-to-lcov: .coverage/lcov.info | |
release: | |
runs-on: macos-latest | |
needs: [build] | |
if: "${{ github.repository_owner == 'ebay' && github.event_name == 'push' }}" | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Setup node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: "18" | |
cache: npm | |
- name: Install dependencies | |
run: npm ci | |
- name: Release | |
id: changesets | |
uses: changesets/action@v1 | |
with: | |
version: npm run version | |
publish: npm run release | |
commit: "ci: release" | |
title: "ci: release" | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |