Class: Gitlab::Git::Patches::CommitPatches
- Inherits:
-
Object
- Object
- Gitlab::Git::Patches::CommitPatches
- Includes:
- WrapsGitalyErrors
- Defined in:
- lib/gitlab/git/patches/commit_patches.rb
Instance Method Summary collapse
- #commit ⇒ Object
-
#initialize(user, repository, branch, patch_collection) ⇒ CommitPatches
constructor
A new instance of CommitPatches.
Methods included from WrapsGitalyErrors
Constructor Details
#initialize(user, repository, branch, patch_collection) ⇒ CommitPatches
Returns a new instance of CommitPatches.
9 10 11 12 13 14 |
# File 'lib/gitlab/git/patches/commit_patches.rb', line 9 def initialize(user, repository, branch, patch_collection) @user = user @repository = repository @branch = branch @patches = patch_collection end |
Instance Method Details
#commit ⇒ Object
16 17 18 19 20 21 22 |
# File 'lib/gitlab/git/patches/commit_patches.rb', line 16 def commit repository.with_cache_hooks do wrapped_gitaly_errors do operation_service.user_commit_patches(user, branch, patches.content) end end end |