Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-10-17 21:08:05 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2019-10-17 21:08:05 +0300
commit184c2ced0761bd8dd7032619d16d3983fed7944a (patch)
treecc82b32ee7c1797509da3cf384617e4ffa2e1733 /app/views/notify
parent238d22c07218adf2b8f3db630ee8b74ca6f29df5 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views/notify')
-rw-r--r--app/views/notify/new_release_email.html.haml18
-rw-r--r--app/views/notify/new_release_email.text.erb12
2 files changed, 30 insertions, 0 deletions
diff --git a/app/views/notify/new_release_email.html.haml b/app/views/notify/new_release_email.html.haml
new file mode 100644
index 00000000000..45e99f3c07a
--- /dev/null
+++ b/app/views/notify/new_release_email.html.haml
@@ -0,0 +1,18 @@
+- release_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: @target_url }
+- description_details = { tag: @release.tag, name: @project.name, release_link_start: release_link_start, release_link_end: '</a>'.html_safe }
+
+%div{ style: "font-family: 'Helvetica Neue',Helvetica,Arial,sans-serif;" }
+ %p
+ = _("A new Release %{tag} for %{name} was published. Visit the %{release_link_start}Releases page%{release_link_end} to read more about it.").html_safe % description_details
+
+ %p
+ %h4= _("Assets:")
+ %ul
+ - @release.links.each do |link|
+ %li= link_to(link.name, link.url)
+ - @release.sources.each do |source|
+ %li= link_to(_("Download %{format}") % { format: source.format }, source.url)
+
+ %p
+ %h4= _("Release notes:")
+ = markdown_field(@release, :description)
diff --git a/app/views/notify/new_release_email.text.erb b/app/views/notify/new_release_email.text.erb
new file mode 100644
index 00000000000..e03cf2d5fd1
--- /dev/null
+++ b/app/views/notify/new_release_email.text.erb
@@ -0,0 +1,12 @@
+<%= _("A new Release %{tag} for %{name} was published. Visit the Releases page to read more about it:").html_safe % { tag: @release.tag, name: @project.name } %> <%= @target_url %>
+
+<%= _("Assets:") %>
+<% @release.links.each do |link| -%>
+ - <%= link.name %>: <%= link.url %>
+<% end -%>
+<% @release.sources.each do |source| -%>
+ - <%= _("Download %{format}:") % { format: source.format } %> <%= source.url %>
+<% end -%>
+
+<%= _("Release notes:") %>
+<%= @release.description %>