stages:
  - build
  - test
  - release

variables:
  GIT_STRATEGY: fetch
  GIT_DEPTH: "3"

cache:
  paths:
    - frontend/node_modules
    - backend/deps

backend-build:
  stage: build
  script:
    - cd backend; make compile
  stage: build
  artifacts:
    paths:
      - backend/_build

backend-test:
  stage: test
  cache:
    paths:
      - backend/deps
  script:
    - cd backend; make test-do
  dependencies:
    - backend-build

frontend-build:
  stage: build
  script:
    - cd frontend; make compile
  artifacts:
    paths:
      - frontend/dist

frontend-test:
  stage: test
  script:
    - cd frontend; make test
  dependencies:
    - frontend-build

release:
  stage: release
  script:
    - make release
  artifacts:
    paths:
      - serverboards.tar.gz
  dependencies:
    - frontend-build
  expire_in: 1 week

stages:
  - build
  - test
  - release

variables:
  GIT_STRATEGY: fetch
  GIT_DEPTH: "3"

cache:
  paths:
    - frontend/node_modules
    - backend/deps

backend-build:
  stage: build
  script:
    - cd backend; make compile
  stage: build
  artifacts:
    paths:
      - backend/_build

backend-test:
  stage: test
  cache:
    paths:
      - backend/deps
  script:
    - cd backend; make test-do
  dependencies:
    - backend-build

frontend-build:
  stage: build
  script:
    - cd frontend; make compile
  artifacts:
    paths:
      - frontend/dist

frontend-test:
  stage: test
  script:
    - cd frontend; make test
  dependencies:
    - frontend-build

release:
  stage: release
  script:
    - make release
  artifacts:
    paths:
      - serverboards.tar.gz
    expire_in: 1 week
  dependencies:
    - frontend-build

Fix in artifacts expire in
Fix in artifacts expire in
