summaryrefslogtreecommitdiff
path: root/app/views/projects/buttons/_artifacts.html.haml
blob: a52677ebf0a2292b9601a4c81f4014cc24486607 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
- pipeline = project.pipelines.latest_successful_for(ref)
- if pipeline
  - artifacts = pipeline.builds.latest.with_artifacts
  - if artifacts.any?
    %li.dropdown-header Artifacts
    - unless pipeline.latest?
      - latest_pipeline = project.pipeline_for(ref)
      %li
        .unclickable= ci_status_for_statuseable(latest_pipeline)
      %li.dropdown-header Previous Artifacts
    - artifacts.each do |job|
      %li
        = link_to latest_succeeded_namespace_project_artifacts_path(project.namespace, project, ref, 'download', job: job.name), rel: 'nofollow' do
          %span Download '#{job.name}'