diff options
author | Douwe Maan <douwe@gitlab.com> | 2015-07-30 15:12:57 +0200 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2015-07-30 15:12:57 +0200 |
commit | 0b5acdd88fb745821cd49f539e7e6cd4874a58ab (patch) | |
tree | 5a6857e94424dab17f29ee6f922e439fa0fbd8a4 /app/views/projects/show.html.haml | |
parent | 1e4b3264637a5b66a9bfb04fe9444bcf1f7e18ed (diff) | |
download | gitlab-ce-0b5acdd88fb745821cd49f539e7e6cd4874a58ab.tar.gz |
Show buttons to add license, changelog and contribution guide if they're missing.
Diffstat (limited to 'app/views/projects/show.html.haml')
-rw-r--r-- | app/views/projects/show.html.haml | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/app/views/projects/show.html.haml b/app/views/projects/show.html.haml index 769dd68f089..4577b84ab89 100644 --- a/app/views/projects/show.html.haml +++ b/app/views/projects/show.html.haml @@ -22,19 +22,34 @@ %li = link_to namespace_project_tags_path(@project.namespace, @project) do = pluralize(number_with_delimiter(@repository.tag_names.count), 'tag') + - if @repository.changelog %li - = link_to changelog_url(@project) do + = link_to changelog_path(@project) do Changelog - if @repository.license %li - = link_to license_url(@project) do + = link_to license_path(@project) do License - if @repository.contribution_guide %li - = link_to contribution_guide_url(@project) do + = link_to contribution_guide_path(@project) do Contribution guide + - if current_user && can_push_branch?(@project, @project.default_branch) + - unless @repository.changelog + %li.missing + = link_to add_changelog_path(@project) do + Add Changelog + - unless @repository.license + %li.missing + = link_to add_license_path(@project) do + Add License + - unless @repository.contribution_guide + %li.missing + = link_to add_contribution_guide_path(@project) do + Add Contribution guide + - if @project.archived? .text-warning.center.prepend-top-20 %p |