aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-02-13 21:43:51 +0900
committernsfisis <nsfisis@gmail.com>2026-02-13 21:58:25 +0900
commitdff818158c790481868c995e0209f13aeb106251 (patch)
tree8c666ea05faa7dd6d7aacc22b67a3224917a80ec
parent7037bd46431830e4d4ad46b2e136243e8455ac02 (diff)
downloadphperkaigi-2026-albatross-dff818158c790481868c995e0209f13aeb106251.tar.gz
phperkaigi-2026-albatross-dff818158c790481868c995e0209f13aeb106251.tar.zst
phperkaigi-2026-albatross-dff818158c790481868c995e0209f13aeb106251.zip
chore: replace Makefile with justfile
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
-rw-r--r--Makefile65
-rw-r--r--backend/Makefile14
-rw-r--r--backend/justfile6
-rw-r--r--docs/DEV.md4
-rw-r--r--frontend/package.json2
-rw-r--r--justfile57
-rw-r--r--worker/swift/Makefile10
-rw-r--r--worker/swift/justfile3
8 files changed, 69 insertions, 92 deletions
diff --git a/Makefile b/Makefile
deleted file mode 100644
index 2d2060d..0000000
--- a/Makefile
+++ /dev/null
@@ -1,65 +0,0 @@
-DOCKER_COMPOSE := docker compose -f compose.local.yaml
-
-all: down build up
-
-.PHONY: build
-build:
- ${DOCKER_COMPOSE} build
- cd frontend; npm install
-
-.PHONY: up
-up:
- ${DOCKER_COMPOSE} up -d
- cd frontend; npm run dev
-
-.PHONY: down
-down:
- ${DOCKER_COMPOSE} down --remove-orphans
-
-.PHONY: logs
-logs:
- ${DOCKER_COMPOSE} logs
-
-.PHONY: logsf
-logsf:
- ${DOCKER_COMPOSE} logs -f
-
-.PHONY: psql
-psql:
- ${DOCKER_COMPOSE} up --wait db
- ${DOCKER_COMPOSE} exec db psql --user=postgres albatross
-
-.PHONY: psql-query
-psql-query:
- ${DOCKER_COMPOSE} up --wait db
- ${DOCKER_COMPOSE} exec --no-TTY db psql --user=postgres albatross
-
-.PHONY: sqldef-dryrun
-sqldef-dryrun: down
- ${DOCKER_COMPOSE} build db
- ${DOCKER_COMPOSE} up --wait db
- ${DOCKER_COMPOSE} run --no-TTY tools psqldef --dry-run < ./backend/schema.sql
-
-.PHONY: sqldef
-sqldef: down
- ${DOCKER_COMPOSE} build db
- ${DOCKER_COMPOSE} up --wait db
- ${DOCKER_COMPOSE} run --no-TTY tools psqldef < ./backend/schema.sql
-
-.PHONY: asynq
-asynq:
- ${DOCKER_COMPOSE} up --wait task-db
- ${DOCKER_COMPOSE} run tools go run github.com/hibiken/asynq/tools/asynq --uri task-db:6379 dash
-
-.PHONY: init
-init: build initdb
-
-.PHONY: initdb
-initdb:
- make psql-query < ./backend/schema.sql
- make psql-query < ./backend/fixtures/dev.sql
-
-.PHONY: gen
-gen:
- cd backend; make gen
- cd frontend; npm run openapi-typescript
diff --git a/backend/Makefile b/backend/Makefile
deleted file mode 100644
index e9bc5a6..0000000
--- a/backend/Makefile
+++ /dev/null
@@ -1,14 +0,0 @@
-.PHONY: all
-all: check lint
-
-.PHONY: check
-check:
- go build -o /dev/null ./...
-
-.PHONY: lint
-lint:
- go run github.com/golangci/golangci-lint/cmd/golangci-lint run
-
-.PHONY: gen
-gen:
- go generate ./...
diff --git a/backend/justfile b/backend/justfile
new file mode 100644
index 0000000..2927f38
--- /dev/null
+++ b/backend/justfile
@@ -0,0 +1,6 @@
+check:
+ go build -o /dev/null ./...
+ go run github.com/golangci/golangci-lint/cmd/golangci-lint run
+
+gen:
+ go generate ./...
diff --git a/docs/DEV.md b/docs/DEV.md
index b2cd6de..6f1ab45 100644
--- a/docs/DEV.md
+++ b/docs/DEV.md
@@ -22,8 +22,8 @@
* `ALBATROSS_JWT_SECRET`: Secret key for JWT tokens
* `ALBATROSS_COOKIE_SECRET`: Secret key for cookies
1. `direnv allow .` (optional)
-1. `make init`
-1. `make up`
+1. `just init`
+1. `just up`
1. Access to http://localhost:5173/iosdc-japan/2025/code-battle/.
* User `a`, `b` and `c` can log in with `pass` password.
* User `a` and `b` are players.
diff --git a/frontend/package.json b/frontend/package.json
index 4a9a3ab..9767a12 100644
--- a/frontend/package.json
+++ b/frontend/package.json
@@ -8,7 +8,7 @@
"check": "npm run check:biome && npm run check:ts && npm run check:eslint",
"check:biome": "biome check --write",
"check:eslint": "eslint --cache --cache-location ./node_modules/.cache/eslint .",
- "check:ts": "react-router typegen && tsc",
+ "check:ts": "react-router typegen && tsc --noEmit",
"dev": "react-router dev",
"openapi-typescript": "openapi-typescript --output ./app/api/schema.d.ts ../openapi/api-server.yaml",
"shiki-codegen": "shiki-codegen --langs php,swift --themes github-light --engine javascript ./app/shiki.bundle.ts",
diff --git a/justfile b/justfile
new file mode 100644
index 0000000..de2a8fa
--- /dev/null
+++ b/justfile
@@ -0,0 +1,57 @@
+docker_compose := "docker compose -f compose.local.yaml"
+
+default: down build up
+
+build:
+ {{ docker_compose }} build
+ cd frontend; npm install
+
+up:
+ {{ docker_compose }} up -d
+ cd frontend; npm run dev
+
+down:
+ {{ docker_compose }} down --remove-orphans
+
+logs:
+ {{ docker_compose }} logs
+
+logsf:
+ {{ docker_compose }} logs -f
+
+psql:
+ {{ docker_compose }} up --wait db
+ {{ docker_compose }} exec db psql --user=postgres albatross
+
+psql-query:
+ {{ docker_compose }} up --wait db
+ {{ docker_compose }} exec --no-TTY db psql --user=postgres albatross
+
+sqldef-dryrun: down
+ {{ docker_compose }} build db
+ {{ docker_compose }} up --wait db
+ {{ docker_compose }} run --no-TTY tools psqldef --dry-run < ./backend/schema.sql
+
+sqldef: down
+ {{ docker_compose }} build db
+ {{ docker_compose }} up --wait db
+ {{ docker_compose }} run --no-TTY tools psqldef < ./backend/schema.sql
+
+asynq:
+ {{ docker_compose }} up --wait task-db
+ {{ docker_compose }} run tools go run github.com/hibiken/asynq/tools/asynq --uri task-db:6379 dash
+
+init: build initdb
+
+initdb:
+ just psql-query < ./backend/schema.sql
+ just psql-query < ./backend/fixtures/dev.sql
+
+gen:
+ cd backend; just gen
+ cd frontend; npm run openapi-typescript
+
+check:
+ cd backend; just check
+ cd worker/swift; just check
+ cd frontend; npm run check
diff --git a/worker/swift/Makefile b/worker/swift/Makefile
deleted file mode 100644
index 6ee4f47..0000000
--- a/worker/swift/Makefile
+++ /dev/null
@@ -1,10 +0,0 @@
-.PHONY: all
-all: check lint
-
-.PHONY: check
-check:
- go build -o /dev/null ./...
-
-.PHONY: lint
-lint:
- go run github.com/golangci/golangci-lint/cmd/golangci-lint run
diff --git a/worker/swift/justfile b/worker/swift/justfile
new file mode 100644
index 0000000..46f0320
--- /dev/null
+++ b/worker/swift/justfile
@@ -0,0 +1,3 @@
+check:
+ go build -o /dev/null ./...
+ go run github.com/golangci/golangci-lint/cmd/golangci-lint run