<commit_before>version: 2
references:
  repo_restore_cache: &repo_restore_cache
    restore_cache:
      keys:
        - repo-{{ .Environment.CIRCLE_SHA1 }}
  repo_save_cache: &repo_save_cache
    save_cache:
      key: repo-{{ .Environment.CIRCLE_SHA1 }}-{{ epoch }}
      paths:
        - ~/airbrake
  bundle_install: &bundle_install
    run:
      name: Install Bundler dependencies
      command: bundle install --path ~/airbrake/vendor/bundle --jobs 15
  appraisal_install: &appraisal_install
    run:
      name: Install Appraisal dependencies
      command: bundle exec appraisal install --jobs 15
  unit: &unit
    run:
      name: Run unit tests
      command: bundle exec rake spec:unit
  rails32: &rails32
    run:
      name: Test Rails 3.2
      command: bundle exec appraisal rails-3.2 rake spec:integration:rails
  rails41: &rails41
    run:
      name: Test Rails 4.1
      command: bundle exec appraisal rails-4.1 rake spec:integration:rails
  rails42: &rails42
    run:
      name: Test Rails 4.2
      command: bundle exec appraisal rails-4.2 rake spec:integration:rails
  rails50: &rails50
    run:
      name: Test Rails 5.0
      command: bundle exec appraisal rails-5.0 rake spec:integration:rails
  rails51: &rails51
    run:
      name: Test Rails 5.1
      command: bundle exec appraisal rails-5.1 rake spec:integration:rails
  rails52: &rails52
    run:
      name: Test Rails 5.2
      command: bundle exec appraisal rails-5.2 rake spec:integration:rails
  rails52: &rails60
    run:
      name: Test Rails 6.0
      command: bundle exec appraisal rails-6.0 rake spec:integration:rails
  sinatra: &sinatra
    run:
      name: Test Sinatra
      command: bundle exec appraisal sinatra rake spec:integration:sinatra
  rack: &rack
    run:
      name: Test Rack
      command: bundle exec appraisal rack rake spec:integration:rack
jobs:
  lint:
    docker:
      - image: circleci/ruby:2.6
    working_directory: ~/airbrake
    steps:
      - checkout
      - <<: *repo_save_cache
      - <<: *bundle_install
      - run:
          name: Run RuboCop linting
          command: bundle exec rubocop --parallel
  "ruby-2.1":
    docker:
      - image: circleci/ruby:2.1
    working_directory: ~/airbrake
    steps:
      - <<: *repo_restore_cache
      - <<: *bundle_install
      - <<: *appraisal_install<commit_msg>circleci: fix typo in rails60 directive<commit_after>version: 2
references:
  repo_restore_cache: &repo_restore_cache
    restore_cache:
      keys:
        - repo-{{ .Environment.CIRCLE_SHA1 }}
  repo_save_cache: &repo_save_cache
    save_cache:
      key: repo-{{ .Environment.CIRCLE_SHA1 }}-{{ epoch }}
      paths:
        - ~/airbrake
  bundle_install: &bundle_install
    run:
      name: Install Bundler dependencies
      command: bundle install --path ~/airbrake/vendor/bundle --jobs 15
  appraisal_install: &appraisal_install
    run:
      name: Install Appraisal dependencies
      command: bundle exec appraisal install --jobs 15
  unit: &unit
    run:
      name: Run unit tests
      command: bundle exec rake spec:unit
  rails32: &rails32
    run:
      name: Test Rails 3.2
      command: bundle exec appraisal rails-3.2 rake spec:integration:rails
  rails41: &rails41
    run:
      name: Test Rails 4.1
      command: bundle exec appraisal rails-4.1 rake spec:integration:rails
  rails42: &rails42
    run:
      name: Test Rails 4.2
      command: bundle exec appraisal rails-4.2 rake spec:integration:rails
  rails50: &rails50
    run:
      name: Test Rails 5.0
      command: bundle exec appraisal rails-5.0 rake spec:integration:rails
  rails51: &rails51
    run:
      name: Test Rails 5.1
      command: bundle exec appraisal rails-5.1 rake spec:integration:rails
  rails52: &rails52
    run:
      name: Test Rails 5.2
      command: bundle exec appraisal rails-5.2 rake spec:integration:rails
  rails60: &rails60
    run:
      name: Test Rails 6.0
      command: bundle exec appraisal rails-6.0 rake spec:integration:rails
  sinatra: &sinatra
    run:
      name: Test Sinatra
      command: bundle exec appraisal sinatra rake spec:integration:sinatra
  rack: &rack
    run:
      name: Test Rack
      command: bundle exec appraisal rack rake spec:integration:rack
jobs:
  lint:
    docker:
      - image: circleci/ruby:2.6
    working_directory: ~/airbrake
    steps:
      - checkout
      - <<: *repo_save_cache
      - <<: *bundle_install
      - run:
          name: Run RuboCop linting
          command: bundle exec rubocop --parallel
  "ruby-2.1":
    docker:
      - image: circleci/ruby:2.1
    working_directory: ~/airbrake
    steps:
      - <<: *repo_restore_cache
      - <<: *bundle_install
      - <<: *appraisal_install
{'fraction_non_alphanumeric': 0.08776030599235018, 'fraction_numerical': 0.029749256268593285, 'mean_word_length': 2.5821917808219177, 'pattern_counts': {'":': 2, '<': 23, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6159076', 'n_tokens_mistral': 1669, 'n_tokens_neox': 1453, 'n_words': 430}