lib/overcommit/hook_context/post_merge.rb
# Returns the set of line numbers corresponding to the lines that were
# changed in a specified file.
Returns the set of line numbers corresponding to the lines that were
changed in a specified file.
Returns the set of line numbers corresponding to the lines that were changed in a specified file .
def modified_lines_in_file(file)
      staged = squash?
      refs = 'HEAD^ HEAD' if merge_commit?
      @modified_lines ||= {}
      @modified_lines[file] ||=
        Overcommit::GitRepo.extract_modified_lines(file, staged: staged, refs: refs)
    end
def modified_lines_in_file ( file ) staged = squash? refs = 'HEAD^ HEAD' if merge_commit? @modified_lines ||= { } @modified_lines [ file ] ||= Overcommit :: GitRepo . extract_modified_lines ( file , staged : staged , refs : refs ) end
Returns the set of line numbers corresponding to the lines that were
changed in a specified file.
Returns the set of line numbers corresponding to the lines that were changed in a specified file .
file
<not_specific>