diff --git a/.github/workflows/auto-inspection.yml b/.github/workflows/auto-inspection.yml deleted file mode 100644 index 344884172f..0000000000 --- a/.github/workflows/auto-inspection.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: 🔂 Auto Inspection - -on: - pull_request: - branches: - - master - -jobs: - preview: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Get branch name (pull request) - run: echo "BRANCH_NAME=$(echo ${GITHUB_HEAD_REF})" >> $GITHUB_ENV - - uses: lxfu1/surge-preview@2.0.3 - id: preview_step - with: - project_name: 'G2Plot' - project_branch: ${{ env.BRANCH_NAME }} - surge_token: ${{ secrets.SURGE_TOKEN }} - github_token: ${{ secrets.GITHUB_TOKEN }} - build: | - yarn - - name: Get the preview url - run: echo "url => ${{ steps.preview_step.outputs.preview_url }}" diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 694bf578a8..4f859ab1e2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,55 +1,29 @@ name: build -on: ["push"] +on: [push] jobs: - lint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js 14 - uses: actions/setup-node@v2 - with: - node-version: 14 - - name: yarn install - run: | - yarn install - - name: lint - run: | - npm run lint - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js 14 - uses: actions/setup-node@v2 - with: - node-version: 14 - - name: yarn install - run: | - yarn install - - name: build - run: | - npm run build + runs-on: macOS-latest - test: - runs-on: macos-latest steps: - - uses: actions/checkout@v2 - - name: Use Node.js 14 - uses: actions/setup-node@v2 + - name: Checkout + uses: actions/checkout@v2.3.4 + + - name: Setup Node.js environment + uses: actions/setup-node@v2.1.5 with: - node-version: 14 - - name: yarn install - run: | - yarn install - - name: test + node-version: '14' + + - name: Run CI run: | + npm install + npm run lint + npm run build npm run coverage - env: - CI: true - - name: Coveralls + + - name: Update coverall + if: ${{ success() }} uses: coverallsapp/github-action@master with: - github-token: ${{ secrets.GITHUB_TOKEN }} + github-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file