lib/gitlab_git/diff.rb in gitlab_git-8.2.0 vs lib/gitlab_git/diff.rb in gitlab_git-9.0.0
- old
+ new
@@ -128,11 +128,12 @@
:patience, :include_ignored, :include_untracked,
:include_unmodified, :recurse_untracked_dirs,
:disable_pathspec_match, :deltas_are_icase,
:include_untracked_content, :skip_binary_check,
:include_typechange, :include_typechange_trees,
- :ignore_filemode, :recurse_ignored_dirs, :paths]
+ :ignore_filemode, :recurse_ignored_dirs, :paths,
+ :max_files, :max_lines, :all_diffs]
if default_options
actual_defaults = default_options.dup
actual_defaults.keep_if do |key|
allowed_options.include?(key)
@@ -183,9 +184,13 @@
hash
end
def submodule?
a_mode == '160000' || b_mode == '160000'
+ end
+
+ def line_count
+ @line_count ||= Util.count_lines(@diff)
end
private
def init_from_rugged(rugged)