# Official language image. Look for the different tagged releases at: # https://hub.docker.com/r/library/ruby/tags/ image: ruby:2.4-alpine cache: paths: - vendor/ruby # cache gems in between builds before_script: - ruby -v # Print out ruby version for debugging - gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image # install nproc (coreutils) for bundle -j # install git for building the gemspec # install make, gcc for building gem native extension (commonmarker) # libc-dev for musl-dev dependency (stdlib.h) needed by gcc - apk --no-cache add coreutils git make gcc libc-dev - bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby - rake install # install the gem rubocop: stage: test script: - rubocop test: stage: test script: - rake test pages: stage: deploy script: - yard doc - mkdir public - mv doc/* public/ artifacts: paths: - public only: - master