Skip to content

[LBGG-533] Account Login & Creation user feedback #72

[LBGG-533] Account Login & Creation user feedback

[LBGG-533] Account Login & Creation user feedback #72

Workflow file for this run

name: CI - Build & Linting
on:
push:
branches: [main]
pull_request:
concurrency:
group: ${{ github.head_ref || github.run_id }}-build-and-lint
cancel-in-progress: true
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
build_and_lint:
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- name: Read package.json
id: package
uses: juliangruber/read-file-action@v1
with:
path: ./package.json
# Ensures pnpm version is consistent and gets back the value to be used in pnpm setup action
- name: Get PNPM version
id: pnpm-version
uses: buffet-time/pnpm-versions-check-action@v1.2
with:
# engines.pnpm
packageJson-engines-pnpm: '${{ fromJson(steps.package.outputs.content).engines.pnpm }}'
# packageManager
packageJson-packageManager: '${{ fromJson(steps.package.outputs.content).packageManager }}'
- name: Cache PNPM modules
uses: actions/cache@v3
id: cache-modules
with:
path: |
~/.pnpm-store
node_modules
key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: ${{ runner.os }}-node-
- uses: pnpm/action-setup@v2.2.4
with:
version: '${{ steps.pnpm-version.outputs.version }}'
- uses: actions/setup-node@v3
with:
# use the version found in `.nvmrc`
node-version-file: '.nvmrc'
cache: 'pnpm'
# shows current pnpm version
- name: check pnpm version
run: pnpm -v
- name: Install `node_modules`
if: steps.cache-modules.outputs.cache-hit != 'true'
run: pnpm install
- name: Copy `.env.test` -> `.env`
run: cp .env.test .env
- name: Cache build
uses: actions/cache@v3
id: cache-build
with:
path: .nuxt/
key: ${{ runner.os }}-build-${{ hashFiles('**/.nuxt') }}
restore-keys: ${{ runner.os }}-build-
- name: Build the `.nuxt` directory
if: steps.cache-build.outputs.cache-hit != 'true'
run: pnpm build
- name: Linting
run: pnpm run lint
- name: Prettier
run: pnpm run prettier:check