build_dist:
  stage: build
  script:
    - if ! [ x$CI_COMMIT_REF_NAME = x$CI_COMMIT_TAG ]; then
        poetry version $(poetry version | cut -d" " -f2)+$(date --date=${CI_COMMIT_TIMESTAMP} +%Y%m%d%H%M%S).${CI_COMMIT_SHORT_SHA} ;
      fi
    - tox -e build
  artifacts:
    paths:
      - dist/
