summaryrefslogtreecommitdiff
path: root/app/helpers/auto_devops_helper.rb
blob: c455d18cff80ca4ece903d6b3d858ad00bd47fc4 (plain)
1
2
3
4
5
6
7
8
9
10
module AutoDevopsHelper
  def show_auto_devops_callout?(project)
    Feature.get(:auto_devops_banner_disabled).off? &&
      show_callout?('auto_devops_settings_dismissed') &&
      can?(current_user, :admin_pipeline, project) &&
      project.has_auto_devops_implicitly_disabled? &&
      !project.repository.gitlab_ci_yml &&
      project.ci_services.active.none?
  end
end