Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
39ada489
Commit
39ada489
authored
Apr 13, 2016
by
Stan Hu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't attempt to include too large diffs in e-mail-on-push messages
Possible cause of issues in gitlab-org/gitlab-ce#15137
parent
d01168a1
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
49 additions
and
45 deletions
+49
-45
CHANGELOG-EE
CHANGELOG-EE
+1
-0
app/views/notify/repository_push_email.html.haml
app/views/notify/repository_push_email.html.haml
+29
-28
app/views/notify/repository_push_email.text.haml
app/views/notify/repository_push_email.text.haml
+19
-17
No files found.
CHANGELOG-EE
View file @
39ada489
Please view this file on the master branch, on stable branches it's out of date.
v 8.7.0 (unreleased)
- Don't attempt to include too large diffs in e-mail-on-push messages (Stan Hu)
- Update GitLab Pages to 0.2.1: support user-defined 404 pages
- Refactor group sync to pull access level logic to its own class. !306
- [Elastic] Stabilize database indexer if database is inconsistent
...
...
app/views/notify/repository_push_email.html.haml
View file @
39ada489
...
...
@@ -48,33 +48,34 @@
-
unless
@message
.
disable_diffs?
-
diff_files
=
@message
.
diffs
%h4
Changes:
-
diff_files
.
each_with_index
do
|
diff_file
,
i
|
%li
{
id:
"diff-#{i}"
}
%a
{
href:
@message
.
target_url
+
"#diff-#{i}"
}
-
if
diff_file
.
deleted_file
%strong
=
diff_file
.
old_path
deleted
-
elsif
diff_file
.
renamed_file
%strong
=
diff_file
.
old_path
→
%strong
=
diff_file
.
new_path
-
if
@message
.
compare_timeout
%h5
The diff was not included because it is too large.
-
else
%h4
Changes:
-
diff_files
.
each_with_index
do
|
diff_file
,
i
|
%li
{
id:
"diff-#{i}"
}
%a
{
href:
@message
.
target_url
+
"#diff-#{i}"
}
-
if
diff_file
.
deleted_file
%strong
=
diff_file
.
old_path
deleted
-
elsif
diff_file
.
renamed_file
%strong
=
diff_file
.
old_path
→
%strong
=
diff_file
.
new_path
-
else
%strong
=
diff_file
.
new_path
%hr
-
diff_commit
=
diff_file
.
deleted_file
?
@message
.
diff_refs
.
first
:
@message
.
diff_refs
.
last
-
blob
=
@message
.
project
.
repository
.
blob_for_diff
(
diff_commit
,
diff_file
)
-
if
blob
&&
blob
.
respond_to?
(
:text?
)
&&
blob_text_viewable?
(
blob
)
%table
.code.white
-
diff_file
.
highlighted_diff_lines
.
each
do
|
line
|
=
render
"projects/diffs/line"
,
{
line:
line
,
diff_file:
diff_file
,
line_code:
nil
,
plain:
true
}
-
else
%strong
=
diff_file
.
new_path
%hr
-
diff_commit
=
diff_file
.
deleted_file
?
@message
.
diff_refs
.
first
:
@message
.
diff_refs
.
last
-
blob
=
@message
.
project
.
repository
.
blob_for_diff
(
diff_commit
,
diff_file
)
-
if
blob
&&
blob
.
respond_to?
(
:text?
)
&&
blob_text_viewable?
(
blob
)
%table
.code.white
-
diff_file
.
highlighted_diff_lines
.
each
do
|
line
|
=
render
"projects/diffs/line"
,
{
line:
line
,
diff_file:
diff_file
,
line_code:
nil
,
plain:
true
}
-
else
No preview for this file type
%br
No preview for this file type
%br
-
if
@message
.
compare_timeout
%h5
Huge diff. To prevent performance issues changes are hidden
app/views/notify/repository_push_email.text.haml
View file @
39ada489
...
...
@@ -25,24 +25,26 @@
-
else
\-
#{
diff
.
new_path
}
-
unless
@message
.
disable_diffs?
\
\
Changes:
-
@message
.
diffs
.
each
do
|
diff_file
|
-
if
@message
.
compare_timeout
\
\=====================================
-
if
diff_file
.
deleted_file
#{
diff_file
.
old_path
}
deleted
-
elsif
diff_file
.
renamed_file
#{
diff_file
.
old_path
}
→
#{
diff_file
.
new_path
}
-
else
=
diff_file
.
new_path
\=====================================
!=
diff_file
.
diff
.
diff
-
if
@message
.
compare_timeout
\
\
Huge diff. To prevent performance issues it was hidden
\
The diff was not included because it is too large.
-
else
\
\
Changes:
-
@message
.
diffs
.
each
do
|
diff_file
|
\
\=====================================
-
if
diff_file
.
deleted_file
#{
diff_file
.
old_path
}
deleted
-
elsif
diff_file
.
renamed_file
#{
diff_file
.
old_path
}
→
#{
diff_file
.
new_path
}
-
else
=
diff_file
.
new_path
\=====================================
!=
diff_file
.
diff
.
diff
-
if
@message
.
target_url
\
\
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment