diff options
author | Douwe Maan <douwe@selenight.nl> | 2017-05-03 01:42:37 +0300 |
---|---|---|
committer | Douwe Maan <douwe@selenight.nl> | 2017-05-04 16:50:12 +0300 |
commit | 0f58eb6bde35009b69ef871534d9ff80fc38bbf7 (patch) | |
tree | 0a5065d9fc05822a81a9379f5a6a64f8105f9503 /lib/gitlab/ci | |
parent | 4faa65d8381f3e1e45bdf3a9bc9785b588891b66 (diff) |
Add artifact file page that uses the blob viewer
Diffstat (limited to 'lib/gitlab/ci')
-rw-r--r-- | lib/gitlab/ci/build/artifacts/metadata/entry.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/gitlab/ci/build/artifacts/metadata/entry.rb b/lib/gitlab/ci/build/artifacts/metadata/entry.rb index 6f799c2f031..2e073334abc 100644 --- a/lib/gitlab/ci/build/artifacts/metadata/entry.rb +++ b/lib/gitlab/ci/build/artifacts/metadata/entry.rb @@ -37,6 +37,12 @@ module Gitlab !directory? end + def blob + return unless file? + + @blob ||= Blob.decorate(::Ci::ArtifactBlob.new(self), nil) + end + def has_parent? nodes > 0 end |