Skip to content

simplify rollup ts plugin #1443

simplify rollup ts plugin

simplify rollup ts plugin #1443

Workflow file for this run

on:
push:
pull_request:
workflow_dispatch:
name: CI
jobs:
unit-tests:
name: Tests
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- uses: pnpm/[email protected]
with:
version: 6.16.0
- uses: actions/setup-node@v2
with:
node-version: "18.x"
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Save start timestamp
id: timestamp-store
run: echo "::set-output name=start_timestamp::$(($(date +%s%N)/1000000))"
- name: Run tests
run: pnpm run test
# - name: Send elapsed time
# run: curl https://thisgraph.com/api/timings/$THISGRAPH_BUCKET_ID/basic -X POST -d "$(($(date +%s%N)/1000000-${{ steps.timestamp-store.outputs.start_timestamp }}))"
# env:
# THISGRAPH_BUCKET_ID: ${{ secrets.THISGRAPH_BUCKET_ID }}
lint:
name: Linting
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- uses: pnpm/[email protected]
with:
version: 6.16.0
- uses: actions/setup-node@v2
with:
node-version: "18.x"
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Run linter
run: |
pnpm run lint
pnpm run format
publish:
needs: [unit-tests, lint]
name: Build and Publish
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- uses: actions/checkout@master
- uses: pnpm/[email protected]
with:
version: 6.16.0
- uses: actions/setup-node@v2
with:
node-version: "18.x"
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Build
run: pnpm run build
- name: Publish
if: github.ref == 'refs/heads/master'
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
deploy-pages:
needs: [publish]
name: Build pages
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- name: Checkout
uses: actions/checkout@v1
- uses: pnpm/[email protected]
with:
version: 6.16.0
- name: Setup node
uses: actions/setup-node@v2
with:
node-version: "14"
cache: "pnpm"
- name: Build package
run: pnpm install && pnpm run build
- name: Build pages
run: cd pages && pnpm install && pnpm run build
- name: Deploy
uses: JamesIves/github-pages-deploy-action@releases/v3
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
FOLDER: pages/dist
CLEAN: true
SINGLE_COMMIT: true