onasty/Taskfile.yml (view raw)
Oleksandr Smirnov
Oleksandr Smirnov
olexsmir@gmail.com api: add openapi docs (#181)..., 9 months ago
olexsmir@gmail.com api: add openapi docs (#181)..., 9 months ago
| 1 | version: "3" |
| 2 | |
| 3 | dotenv: |
| 4 | - ".env" |
| 5 | |
| 6 | includes: |
| 7 | migrate: ./migrations/Taskfile.yml |
| 8 | frontend: |
| 9 | taskfile: ./web/Taskfile.yml |
| 10 | dir: ./web/ |
| 11 | |
| 12 | api: |
| 13 | taskfile: ./api/Taskfile.yml |
| 14 | dir: ./api/ |
| 15 | |
| 16 | env: |
| 17 | COMPOSE_BAKE: 1 |
| 18 | |
| 19 | vars: |
| 20 | gotest: |
| 21 | sh: 'command -v gotest >/dev/null && echo gotest || echo "go test"' |
| 22 | |
| 23 | tasks: |
| 24 | run: |
| 25 | - docker compose up -d --build --remove-orphans core mailer |
| 26 | |
| 27 | lint: |
| 28 | - golangci-lint run |
| 29 | |
| 30 | lint:all: |
| 31 | deps: |
| 32 | - lint |
| 33 | - frontend:lint |
| 34 | - api:lint |
| 35 | |
| 36 | docker:up: |
| 37 | - docker compose up -d --build --remove-orphans |
| 38 | |
| 39 | docker:down: |
| 40 | aliases: [docker:stop] |
| 41 | cmd: docker compose stop |
| 42 | |
| 43 | seed:run: |
| 44 | - docker compose run --rm seed |
| 45 | |
| 46 | test: |
| 47 | - task: test:unit |
| 48 | - task: test:e2e |
| 49 | - task: frontend:test |
| 50 | |
| 51 | test:unit: |
| 52 | - '{{.gotest}} --count=1 -v --short ./...' |
| 53 | |
| 54 | test:e2e: |
| 55 | - '{{.gotest}} --count=1 -v ./e2e/' |