summaryrefslogtreecommitdiff
path: root/app/models/ci
diff options
context:
space:
mode:
authorKamil Trzcinski <ayufan@ayufan.eu>2016-01-20 21:48:22 +0100
committerKamil Trzcinski <ayufan@ayufan.eu>2016-01-20 21:55:13 +0100
commit9b0f57781e8c71eb0e627a63078fedcedfe62bbb (patch)
treec9e9708a8740e1f215a7ba08d97736bc29162c27 /app/models/ci
parent425f8d6f572a3ae47c971a48bfefc9907c7bda55 (diff)
downloadgitlab-ce-ci/recursive-artifacts-entries.tar.gz
Add method that calculates total size for artifacts subfolderci/recursive-artifacts-entries
Diffstat (limited to 'app/models/ci')
-rw-r--r--app/models/ci/build.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/models/ci/build.rb b/app/models/ci/build.rb
index 16a5b03f591..623edd8bc57 100644
--- a/app/models/ci/build.rb
+++ b/app/models/ci/build.rb
@@ -346,17 +346,17 @@ module Ci
end
def artifacts_browse_url
- if artifacts_browser_supported?
+ if artifacts_metadata?
browse_namespace_project_build_artifacts_path(project.namespace, project, self)
end
end
- def artifacts_browser_supported?
+ def artifacts_metadata?
artifacts? && artifacts_metadata.exists?
end
- def artifacts_metadata_entry(path)
- Gitlab::Ci::Build::Artifacts::Metadata.new(artifacts_metadata.path, path).to_entry
+ def artifacts_metadata_entry(path, **options)
+ Gitlab::Ci::Build::Artifacts::Metadata.new(artifacts_metadata.path, path, **options).to_entry
end
private