Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
December 18, 2022 01:05 pm GMT

Simple Github Workflow for Lint - Prettier & Jest (yarn)

For this workflow make sure you add your own version of node that you have installed on your machine

name: Master Previewon:  push:    branches:      - master  pull_request:    branches:      - masterjobs:  run-linters:    name: Lint & Jest    runs-on: ubuntu-latest    steps:      - name: Check out Git repository        uses: actions/checkout@v2      - name: Set up Node.js        uses: actions/setup-node@v1        with:          node-version: v16.6.1      - name: Install dependencies        run: yarn --prefer-offline      - name: Run linters        run: yarn lint      - name: Test        run: yarn test  prettier:    name: Prettier    runs-on: ubuntu-latest    steps:      - name: Check out Git repository        uses: actions/checkout@v2      - name: Set up Node.js        uses: actions/setup-node@v1        with:          node-version: v16.6.1      - name: Install dependencies        run: yarn --prefer-offline      - name: Run Prettier        run: yarn run format  build:    runs-on: ubuntu-latest    name: Build and Test    steps:      - uses: actions/checkout@v2        name: Check out repository      - uses: actions/setup-node@v1        name: Set up Node.js        with:          node-version: 16.10.0

Original Link: https://dev.to/vikirobles/simple-github-workflow-for-build-lint-test-yarn-2hb4

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To