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
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
7b34c9dc
Commit
7b34c9dc
authored
Feb 20, 2015
by
Douwe Maan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add list of changed files to EmailsOnPush.
See #1906.
parent
6afb03ee
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
64 additions
and
14 deletions
+64
-14
app/views/layouts/notify.html.haml
app/views/layouts/notify.html.haml
+9
-0
app/views/notify/repository_push_email.html.haml
app/views/notify/repository_push_email.html.haml
+36
-8
app/views/notify/repository_push_email.text.haml
app/views/notify/repository_push_email.text.haml
+18
-5
app/views/projects/diffs/_stats.html.haml
app/views/projects/diffs/_stats.html.haml
+1
-1
No files found.
app/views/layouts/notify.html.haml
View file @
7b34c9dc
...
...
@@ -16,6 +16,15 @@
font-size
:
small
;
color
:
#777
}
.file-stats
a
{
text-decoration
:
none
;
}
.file-stats
.new-file
{
color
:
#090
;
}
.file-stats
.deleted-file
{
color
:
#B00
;
}
#{
add_email_highlight_css
}
%body
%div
.content
...
...
app/views/notify/repository_push_email.html.haml
View file @
7b34c9dc
...
...
@@ -11,16 +11,44 @@
%i
at
#{
commit
.
committed_date
.
strftime
(
"%Y-%m-%dT%H:%M:%SZ"
)
}
%pre
#{
commit
.
safe_message
}
%h4
#{
pluralize
@diffs
.
count
,
"changed file"
}
:
%ul
-
@diffs
.
each_with_index
do
|
diff
,
i
|
%li
.file-stats
%a
{
href:
"#diff-#{i}"
}
-
if
diff
.
deleted_file
%span
.deleted-file
−
=
diff
.
old_path
-
elsif
diff
.
renamed_file
=
diff
.
old_path
→
=
diff
.
new_path
-
elsif
diff
.
new_file
%span
.new-file
+
=
diff
.
new_path
-
else
=
diff
.
new_path
%h4
Changes:
-
@diffs
.
each
do
|
diff
|
%li
%strong
-
if
diff
.
old_path
==
diff
.
new_path
=
diff
.
new_path
-
elsif
diff
.
new_path
&&
diff
.
old_path
#{
diff
.
old_path
}
→
#{
diff
.
new_path
}
-
@diffs
.
each_with_index
do
|
diff
,
i
|
%li
{
id:
"diff-#{i}"
}
%a
{
href:
@target_url
+
"#diff-#{i}"
}
-
if
diff
.
deleted_file
%strong
=
diff
.
old_path
deleted
-
elsif
diff
.
renamed_file
%strong
=
diff
.
old_path
→
%strong
=
diff
.
new_path
-
else
=
diff
.
new_path
||
diff
.
old_path
%strong
=
diff
.
new_path
%hr
%pre
=
color_email_diff
(
diff
.
diff
)
...
...
app/views/notify/repository_push_email.text.haml
View file @
7b34c9dc
...
...
@@ -8,16 +8,29 @@ Commits:
\- - - - -
\
\
#{
pluralize
@diffs
.
count
,
"changed file"
}
:
\
-
@diffs
.
each
do
|
diff
|
-
if
diff
.
deleted_file
\- −
#{
diff
.
old_path
}
-
elsif
diff
.
renamed_file
\-
#{
diff
.
old_path
}
→
#{
diff
.
new_path
}
-
elsif
diff
.
new_file
\- +
#{
diff
.
new_path
}
-
else
\-
#{
diff
.
new_path
}
\
\
Changes:
-
@diffs
.
each
do
|
diff
|
\
\=====================================
-
if
diff
.
old_path
==
diff
.
new_path
=
diff
.
new_path
-
elsif
diff
.
new_path
&&
diff
.
old_path
#{
diff
.
old_path
}
→
#{
diff
.
new_path
}
-
if
diff
.
deleted_file
#{
diff
.
old_path
}
deleted
-
elsif
diff
.
renamed_file
#{
diff
.
old_path
}
→
#{
diff
.
new_path
}
-
else
=
diff
.
new_path
||
diff
.
old_path
=
diff
.
new_path
\=====================================
!=
diff
.
diff
\
...
...
app/views/projects/diffs/_stats.html.haml
View file @
7b34c9dc
...
...
@@ -26,7 +26,7 @@
%a
{
href:
"#diff-#{i}"
}
%i
.fa.fa-minus
=
diff
.
old_path
\->
→
=
diff
.
new_path
-
elsif
diff
.
new_file
%span
.new-file
...
...
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