debian-mirror-gitlab/app/uploaders/external_diff_uploader.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
379 B
Ruby
Raw Normal View History

2019-03-02 22:35:43 +05:30
# frozen_string_literal: true
class ExternalDiffUploader < GitlabUploader
include ObjectStorage::Concern
2023-05-27 22:25:52 +05:30
storage_location :external_diffs
2019-03-02 22:35:43 +05:30
alias_method :upload, :model
def filename
"diff-#{model.id}"
end
def store_dir
dynamic_segment
end
private
def dynamic_segment
File.join(model.model_name.plural, "mr-#{model.merge_request_id}")
end
end