Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add linting.yaml to action workflow #21

Merged
merged 3 commits into from
Jul 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/workflows/linting.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Linting

on: pull_request

jobs:
prettier:
name: Prettier
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: "lts/hydrogen"

- run: npm ci

- run: npm run lint:prettier:check
4 changes: 2 additions & 2 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 'lts/hydrogen'
node-version: "lts/hydrogen"

- run: npm ci

Expand Down
3 changes: 1 addition & 2 deletions infra/compose.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
services:
database:
container_name: "postgres-dev"
image: 'postgres:16.0-alpine3.18'
image: "postgres:16.0-alpine3.18"
env_file:
- ../.env.development
ports:
- "5432:5432"

4 changes: 2 additions & 2 deletions infra/migrations/1710383390337_test-migration.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

exports.shorthands = undefined;

exports.up = pgm => {};
exports.up = (pgm) => {};

exports.down = pgm => {};
exports.down = (pgm) => {};
8 changes: 4 additions & 4 deletions jsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"compilerOptions": {
"baseUrl": "."
}
}
"compilerOptions": {
"baseUrl": "."
}
}
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"scripts": {
"set-env": "npm run docker:up && npm run wait-for-postgres",
"dev": "npm run set-env && npm run migration:up && next dev",
"lint:check": "prettier --check .",
"lint:fix": "prettier --write .",
"lint:prettier:check": "prettier --check .",
"lint:prettier:fix": "prettier --write .",
"concurrent-base": "concurrently -n next,jest -s command-jest --hide next -k \"next dev\"",
"test-concurrently": "npm run concurrent-base -- \"jest --runInBand\"",
"test": "npm run set-env && npm run test-concurrently",
Expand Down