Class: ModuleSync::GitService::GitLab
- Defined in:
- lib/modulesync/git_service/gitlab.rb
Overview
GitLab creates and manages merge requests on gitlab.com or private GitLab installations.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(token, endpoint) ⇒ GitLab
constructor
A new instance of GitLab.
Methods inherited from Base
extract_hostname, #open_pull_request
Constructor Details
#initialize(token, endpoint) ⇒ GitLab
Returns a new instance of GitLab.
10 11 12 13 14 15 16 17 |
# File 'lib/modulesync/git_service/gitlab.rb', line 10 def initialize(token, endpoint) super() @api = Gitlab::Client.new( :endpoint => endpoint, :private_token => token, ) end |
Class Method Details
.guess_endpoint_from(remote:) ⇒ Object
19 20 21 22 23 24 25 |
# File 'lib/modulesync/git_service/gitlab.rb', line 19 def self.guess_endpoint_from(remote:) endpoint = super return nil if endpoint.nil? endpoint += '/api/v4' endpoint end |