build: refactor makefile

This commit is contained in:
Oleg Lobanov 2021-12-20 23:16:35 +01:00
parent b1e0d5b39f
commit f81857acce
No known key found for this signature in database
GPG key ID: 7CC64E41212621B0
15 changed files with 3333 additions and 87 deletions

View file

@ -9,6 +9,7 @@ on:
pull_request:
jobs:
# linters
lint-frontend:
runs-on: ubuntu-latest
steps:
@ -34,24 +35,37 @@ jobs:
- uses: actions/setup-node@v2
with:
node-version: '14'
- run: npm i -g commitlint
- run: make lint-commits
lint:
runs-on: ubuntu-latest
needs: [lint-frontend, lint-backend, lint-commints]
steps:
- run: echo "passed"
test:
- run: echo "done"
# tests
test-frontend:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '14'
- run: make test-frontend
test-backend:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v2
with:
go-version: 1.17
- uses: actions/setup-node@v2
with:
node-version: '14'
- run: make test
- run: make test-backend
test:
runs-on: ubuntu-latest
needs: [test-frontend, test-backend]
steps:
- run: echo "done"
# release
release:
runs-on: ubuntu-latest
needs: [lint, test]