class Overcommit::Hook::PreCommit::LocalPathsInGemfile

Checks for local paths in files and issues a warning

Public Instance Methods

run() click to toggle source
# File lib/overcommit/hook/pre_commit/local_paths_in_gemfile.rb, line 6
def run
  result = execute(command, args: applicable_files)

  unless result.stdout.empty?
    return :warn, "Avoid pointing to local paths in Gemfiles:\n#{result.stdout}"
  end

  :pass
end