trigger: - main - feature/* pool: vmImage: 'ubuntu-latest' variables: - group: SAUDEID-GEM jobs: - job: Building steps: - task: UseRubyVersion@0 inputs: versionSpec: '>= 2.7.1' addToPath: true displayName: 'Installing Ruby' - script: | which ruby - script: | sudo apt-get update && sudo apt-get -yqq install xvfb unzip libxi6 libgconf-2-4 libpq-dev displayName: Install dependencies - script: | gem install bundler bundle install --retry=3 --jobs=4 displayName: 'Installing Bundler and Gems' - script: | bundle exec rspec spec/SaudeiD_spec.rb displayName: 'Run Tests' - script: | gem build SaudeiD.gemspec GEM_VERSION=$(gem build SaudeiD.gemspec | grep -P 'File: \K.+' -o) gem push $GEM_VERSION -k $(GEM_HOST_API_KEY) displayName: Build Gem and Publish Gem