image: golang:alpine

variables:
  REPO_NAME: gitlab.com/elves/elvish

before_script:
  - go version
  - apk add git

test:
  script:
    - apk add gcc musl-dev
    - go test -race ./...

build:
  script:
    - apk add zip
    - ./tools/buildall.sh . bin HEAD
  artifacts:
    paths:
      - bin
