name: Node.js CI on: push: branches: - master - develop - release/* pull_request: branches: - master jobs: build: name: Node.js CI runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - name: Setup Node.js uses: actions/setup-node@v1 with: node-version: 14 - name: Install Yarn uses: bahmutov/npm-install@v1.1.0 - name: Test run: yarn test - name: Copy built files to docs run: cp ./dist/shareon.min.* ./docs if: github.event == 'push' && github.ref == 'refs/heads/master' - name: Deploy to GitHub Pages uses: crazy-max/ghaction-github-pages@v2.1.2 with: keep_history: true build_dir: docs fqdn: shareon.js.org jekyll: false if: github.event == 'push' && github.ref == 'refs/heads/master'