Skip to content

chore: update docs

chore: update docs #2

Workflow file for this run

name: Lint and Test
on:
pull_request:
branches: ["**"]
push:
branches:
- "**"
jobs:
# https://github.com/snezhig/obsidian-front-matter-title/blob/master/.github/workflows/main.yml
validate:
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: "true"
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: 16
cache: "npm"
- run: npm i
# - name: Eslint
# run: npm run lint
- name: Run test
run: npm run test
pretty:
needs: validate
runs-on: ubuntu-latest
# if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'Newdea/obsidian-spaced-repetition-recall'
steps:
- name: Checkout
uses: actions/checkout@v3
with:
# Make sure the actual branch is checked out when running on pull requests
ref: ${{ github.head_ref }}
- name: Prettify code
uses: creyD/[email protected]
with:
prettier_version: 2.8.8
# This part is also where you can pass other options, for example:
# prettier_options: --write *.ts *.json src test --ignore-path package-lock.json
prettier_options: --write . --ignore-path package-lock.json
lint_and_test:
needs: pretty
runs-on: ubuntu-latest
steps:
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: "20.x"
- uses: actions/checkout@v3
- name: Install Dependencies
run: npm install -g pnpm && pnpm install
- name: Lint
run: pnpm lint
- name: Test
run: pnpm test