summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorFatih Acet <acetfatih@gmail.com>2016-08-02 14:52:40 +0000
committerFatih Acet <acetfatih@gmail.com>2016-08-02 14:52:40 +0000
commit97163340403db355df80eec37002e54feb2ba952 (patch)
treee3cdc9555be9005173b79c0d0940d0526e5f74e4 /app
parentb4b7adbed5fb95ca7c7d1997d2206894c24c2e18 (diff)
parentafca25ed8abddf4f9f3767fbc26a990a6e61dc8b (diff)
downloadgitlab-ce-97163340403db355df80eec37002e54feb2ba952.tar.gz
Merge branch '20101-ci-configuration' into 'master'
Resolve ""CI configuration" button when `.gitlab-ci.yml` is present" ## What does this MR do? Adds `CI configuration` button to project overview page ## What are the relevant issue numbers? Closes #20101 ## Screenshots (if relevant) ![Screen_Shot_2016-07-28_at_11.51.32_AM](/uploads/499d942d203d287ae98b7589ef12673c/Screen_Shot_2016-07-28_at_11.51.32_AM.png) See merge request !5558
Diffstat (limited to 'app')
-rw-r--r--app/helpers/projects_helper.rb4
-rw-r--r--app/views/projects/show.html.haml4
2 files changed, 8 insertions, 0 deletions
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb
index a733dff1579..505545fbabb 100644
--- a/app/helpers/projects_helper.rb
+++ b/app/helpers/projects_helper.rb
@@ -263,6 +263,10 @@ module ProjectsHelper
filename_path(project, :version)
end
+ def ci_configuration_path(project)
+ filename_path(project, :gitlab_ci_yml)
+ end
+
def project_wiki_path_with_version(proj, page, version, is_newest)
url_params = is_newest ? {} : { version_id: version }
namespace_project_wiki_path(proj.namespace, proj, page, url_params)
diff --git a/app/views/projects/show.html.haml b/app/views/projects/show.html.haml
index dd1cf680cfa..a666d07e9eb 100644
--- a/app/views/projects/show.html.haml
+++ b/app/views/projects/show.html.haml
@@ -43,6 +43,10 @@
%li
= link_to 'Contribution guide', contribution_guide_path(@project)
+ - if @repository.gitlab_ci_yml
+ %li
+ = link_to 'CI configuration', ci_configuration_path(@project)
+
- if current_user && can_push_branch?(@project, @project.default_branch)
- unless @repository.changelog
%li.missing