amis2/.github/workflows/pr-test.yml

66 lines
1.7 KiB
YAML
Raw Permalink Normal View History

2021-02-02 15:23:12 +08:00
name: PR test
on:
pull_request:
branches: ['**']
2021-02-02 15:23:12 +08:00
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
2024-04-25 10:40:50 +08:00
node-version: [20.x]
2021-02-02 15:23:12 +08:00
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
2024-07-16 10:38:07 +08:00
- uses: actions/checkout@v4
2021-02-02 15:23:12 +08:00
with:
persist-credentials: false
- name: Use Node.js ${{ matrix.node-version }}
2024-07-16 10:38:07 +08:00
uses: actions/setup-node@v4
2021-02-02 15:23:12 +08:00
with:
node-version: ${{ matrix.node-version }}
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: npm install
env:
NODE_OPTIONS: '--max-old-space-size=8192'
2021-02-02 15:23:12 +08:00
run: |
npm i --legacy-peer-deps
cd packages/office-viewer
npm i --legacy-peer-deps
cd ../../
- name: build amis-formula
run: |
npm run build --workspace amis-formula
- name: build amis-core
run: |
npm run build --workspace amis-core
- name: build amis-ui
run: |
npm run build --workspace amis-ui
- name: build amis
run: |
npm run build --workspace amis
- name: check schema.json
run: |
cp ./packages/amis/schema.json .
- name: build amis-editor-core
run: |
npm run build --workspace amis-editor-core
- name: build amis-editor
run: |
npm run build --workspace amis-editor
- name: typescript check
env:
NODE_OPTIONS: '--max-old-space-size=8192'
run: |
npm run typecheck
- name: test
run: |
2022-06-02 13:28:23 +08:00
npm test --workspaces
cd packages/office-viewer
2023-05-05 21:39:45 +08:00
npm test
cd ../../
sh deploy-gh-pages.sh