feat: first commit #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: Nest.JS clean architecture CI | |
on: | |
push: | |
branches: ['*'] | |
pull_request: | |
branches: [main] | |
jobs: | |
lint-commit: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Copy repository | |
uses: actions/checkout@v3 | |
- uses: pnpm/action-setup@v4 | |
name: Install pnpm | |
with: | |
version: 8 | |
run_install: false | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
cache: pnpm | |
- name: Install dependencies | |
run: pnpm install | |
- name: Lint commit | |
run: npx commitlint --last --verbose | |
lint-code: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Copy repository | |
uses: actions/checkout@v3 | |
- uses: pnpm/action-setup@v4 | |
name: Install pnpm | |
with: | |
version: 8 | |
run_install: false | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
cache: pnpm | |
- name: Install dependencies | |
run: pnpm install | |
- name: Lint code | |
run: pnpm lint | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Copy repository | |
uses: actions/checkout@v3 | |
- uses: pnpm/action-setup@v4 | |
name: Install pnpm | |
with: | |
version: 8 | |
run_install: false | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
cache: pnpm | |
- name: Install dependencies | |
run: pnpm install | |
- name: Run tests | |
run: pnpm test |