Module: LogCabin::Modules::GitlabApi
- Defined in:
- lib/prospectus/helpers/gitlab_api.rb
Overview
Provide an api method for modules to query GitLab
Instance Method Summary collapse
Instance Method Details
#gitlab_api ⇒ Object
9 10 11 12 13 14 |
# File 'lib/prospectus/helpers/gitlab_api.rb', line 9 def gitlab_api @gitlab_api ||= Gitlab.client( endpoint: gitlab_endpoint + '/api/v3', private_token: gitlab_token ) end |
#gitlab_slug(repo) ⇒ Object
16 17 18 |
# File 'lib/prospectus/helpers/gitlab_api.rb', line 16 def gitlab_slug(repo) repo.sub('/', '%2F') end |