diff options
author | Kamil Trzciński <ayufan@ayufan.eu> | 2016-12-22 00:34:45 +0300 |
---|---|---|
committer | Kamil Trzciński <ayufan@ayufan.eu> | 2016-12-22 00:34:45 +0300 |
commit | 68d89aa96b1ae7ea742cc5ac708bd8d08492826b (patch) | |
tree | ad3394558392e189cb406ddea227429240d6e88f /lib | |
parent | bdc4a9f290ae9624f7a1822e42e7fbf5288ca132 (diff) | |
parent | 4a1e1281ac862a0c86d62473ab09d559c7ec5485 (diff) |
Merge branch 'adam-auto-deploy' into 'master'
Auto deploy
Closes #23580
See merge request !8135
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/template/gitlab_ci_yml_template.rb | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/gitlab/template/gitlab_ci_yml_template.rb b/lib/gitlab/template/gitlab_ci_yml_template.rb index 8d1a1ed54c9..d19b0a52043 100644 --- a/lib/gitlab/template/gitlab_ci_yml_template.rb +++ b/lib/gitlab/template/gitlab_ci_yml_template.rb @@ -13,8 +13,9 @@ module Gitlab def categories { - "General" => '', - "Pages" => 'Pages' + 'General' => '', + 'Pages' => 'Pages', + 'Autodeploy' => 'autodeploy' } end @@ -25,6 +26,11 @@ module Gitlab def finder(project = nil) Gitlab::Template::Finders::GlobalTemplateFinder.new(self.base_dir, self.extension, self.categories) end + + def dropdown_names(context) + categories = context == 'autodeploy' ? ['Autodeploy'] : ['General', 'Pages'] + super().slice(*categories) + end end end end |