From e831a3b869cbb82e9a4294a5f9309ba56df46589 Mon Sep 17 00:00:00 2001 From: Zeger-Jan van de Weg Date: Fri, 19 Feb 2016 11:58:02 +0100 Subject: Link in the note when started a new branch from an issue --- app/services/system_note_service.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/services/system_note_service.rb b/app/services/system_note_service.rb index 751815c5b18..b65ac47bce3 100644 --- a/app/services/system_note_service.rb +++ b/app/services/system_note_service.rb @@ -212,7 +212,10 @@ class SystemNoteService # # "Started branch `201-issue-branch-button`" def self.new_issue_branch(issue, project, author, branch) - body = "Started branch `#{branch}`" + h = Gitlab::Application.routes.url_helpers + link = "#{Gitlab.config.gitlab.url}#{h.namespace_project_compare_path(project.namespace, project, from: project.default_branch, to: branch)}" + + body = "Started branch [#{branch}](#{link})" create_note(noteable: issue, project: project, author: author, note: body) end -- cgit v1.2.1