Sha256: 288e1e8ee64aef80a19b9f01a85089719074582d1d5db9992cdfbe363ec418eb

Contents?: true

Size: 560 Bytes

Versions: 158

Compression:

Stored size: 560 Bytes

Contents

# frozen_string_literal: true

require 'overcommit'
require 'overcommit/hook/pre_commit/base'

module Overcommit
  module Hook
    module PreCommit
      # CircleCI plugin for Overcommit to validate config file (.circleci/config.yml)
      class CircleCi < Base
        # @return [Symbol, Array<[Symbol, String]>]
        def run
          result = execute(command)
          return :pass if result.success?

          if result.success?
            :pass
          else
            [:fail, result.stderr]
          end
        end
      end
    end
  end
end

Version data entries

158 entries across 158 versions & 2 rubygems

Version Path
checkoff-0.163.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.162.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.161.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.160.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.159.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.158.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.157.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.156.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.155.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.154.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.153.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.152.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.151.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.150.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.149.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.148.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.147.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.145.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.139.0 .git-hooks/pre_commit/circle_ci.rb
checkoff-0.138.0 .git-hooks/pre_commit/circle_ci.rb