.gitlab-ci.yml
# To contribute improvements to CI/CD templates, please follow the Development guide at:
# https://docs.gitlab.com/ee/development/cicd/templates.html
# This specific template is located at:
# https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Ruby.gitlab-ci.yml
# Official language image. Look for the different tagged releases at:
# https://hub.docker.com/r/library/ruby/tags/
image: ruby:latest
# Cache gems in between builds
cache:
paths:
- vendor/ruby
# This is a basic example for a gem or script which doesn't use
# services such as redis or postgres
before_script:
- ruby -v # Print out ruby version for debugging
# Uncomment next line if your rails app needs a JS runtime:
# - apt-get update -q && apt-get install nodejs -yqq
- bundle config set path 'vendor' # Install dependencies into ./vendor/ruby
- bundle install -j $(nproc)
- gem install rubocop
- gem install rspec
# Optional - Delete if not using `rubocop`
rubocop:
script:
- rubocop
rspec:
script:
- rspec spec