name: Deployment
on:
  push:
    branches:
      - master

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
    - run: export CHROME_BIN=chromium-browser
    - run: export DISPLAY=:99.0
    - run: Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
    - run: sleep 5
    - uses: actions/checkout@v1
    - uses: actions/setup-node@v1
      with:
        node-version: '8.x'
    - run: mkdir dist
    - run: mkdir dist/js
    - run: npm install
    - run: npm run setup
    - run: npm run build
    - run: npm run html:production
    # - name: GitHub Pages Deployment
    #   uses: crazy-max/ghaction-github-pages@v0.1.0
    #   if: success()
    #   with:
    #     target_branch: gh-pages
    #     build_dir: dist
    #   env:
    #     GITHUB_PAT: ${{ secrets.GITHUB_PAT }}
    - name: NPM Release
      if: success()
      uses: primer/publish@master
      env:
        NPM_AUTH_TOKEN: ${{ secrets.NPMJS_TOKEN }}


name: Deployment
on:
  push:
    branches:
      - master

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
    - run: export CHROME_BIN=chromium-browser
    - run: export DISPLAY=:99.0
    - run: Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
    - run: sleep 5
    - uses: actions/checkout@v1
    - uses: actions/setup-node@v1
      with:
        node-version: '8.x'
    - run: mkdir dist
    - run: mkdir dist/js
    - run: npm install
    - run: npm run setup
    - run: npm run build
    - run: npm run html:production
    # - name: GitHub Pages Deployment
    #   uses: crazy-max/ghaction-github-pages@v0.1.0
    #   if: success()
    #   with:
    #     target_branch: gh-pages
    #     build_dir: dist
    #   env:
    #     GITHUB_PAT: ${{ secrets.GITHUB_PAT }}
    - name: NPM Release
      if: success()
      uses: primer/publish@master
      env:
        NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}


Set NPM token as correct name
Set NPM token as correct name
