Skip to content
Snippets Groups Projects
Commit b716d676 authored by Drew Blessing's avatar Drew Blessing
Browse files

Merge branch 'bugfix/git-hook-prohibited-filenames' into 'master'

Improve error message for prohibited filenames

Will fix #202

See merge request !162
parents 4987f9e4 fc682e7d
No related branches found
No related tags found
3 merge requests!8889WIP: Port of 25624-anticipate-obstacles-to-removing-turbolinks to EE.,!7795Asciidoctor plantuml,!7793Add support for PlantUML diagrams in Asciidoc.
Loading
Loading
@@ -251,7 +251,7 @@ module Gitlab
if git_hook.file_name_regex.present?
commit.diffs.each do |diff|
if (diff.renamed_file || diff.new_file) && diff.new_path =~ Regexp.new(git_hook.file_name_regex)
return build_status_object(false, "File name #{diff.new_path.inspect} does not follow the pattern '#{git_hook.file_name_regex}'")
return build_status_object(false, "File name #{diff.new_path.inspect} is prohibited by the pattern '#{git_hook.file_name_regex}'")
end
end
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment