This patch: - removes the "is this upstream check?" when publishing daily version - fixes the bug when manually triggered builds were pushed under @beta tag Drive-by: rename "tip-of-tree" flag to "next" for consistency.
48 lines
1.5 KiB
YAML
48 lines
1.5 KiB
YAML
name: "devrelease:npm"
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
schedule:
|
|
- cron: "10 0 * * *"
|
|
push:
|
|
branches:
|
|
- release-*
|
|
|
|
jobs:
|
|
publish-canary-npm:
|
|
name: "publish to NPM"
|
|
runs-on: ubuntu-20.04
|
|
if: github.repository == 'microsoft/playwright'
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 12
|
|
registry-url: 'https://registry.npmjs.org'
|
|
- run: npm i -g npm@7
|
|
- run: npm ci
|
|
- run: npm run build
|
|
- run: npx playwright install-deps
|
|
- name: "@next: publish with commit timestamp (triggered manually)"
|
|
if: contains(github.ref, 'master') && github.event_name == 'workflow_dispatch'
|
|
run: |
|
|
node utils/build/update_canary_version.js --today-date
|
|
utils/publish_all_packages.sh --next
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
- name: "@next: publish with today's date (triggered automatically)"
|
|
if: contains(github.ref, 'master') && github.event_name != 'workflow_dispatch'
|
|
run: |
|
|
node utils/build/update_canary_version.js --today-date
|
|
utils/publish_all_packages.sh --next
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
- name: "@beta: publish with commit timestamp (triggered automatically)"
|
|
if: contains(github.ref, 'release') && github.event_name != 'workflow_dispatch'
|
|
run: |
|
|
node utils/build/update_canary_version.js --commit-timestamp
|
|
utils/publish_all_packages.sh --beta
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
|