Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GitLab API support #26

Open
XVilka opened this issue Aug 6, 2014 · 17 comments
Open

GitLab API support #26

XVilka opened this issue Aug 6, 2014 · 17 comments

Comments

@XVilka
Copy link

XVilka commented Aug 6, 2014

See specification here:

https://gitlab.com/gitlab-org/gitlab-ce/tree/master/doc/api

@eleazan
Copy link

eleazan commented Dec 12, 2014

+1

1 similar comment
@dfeyer
Copy link

dfeyer commented Jan 13, 2015

+1

@manicminer
Copy link

You know there are plenty of Gitlab clients to choose from: https://about.gitlab.com/applications/

@agb80
Copy link

agb80 commented Feb 24, 2015

+1

2 similar comments
@b-sh
Copy link

b-sh commented Mar 1, 2015

👍

@gsmethells
Copy link

👍

@StephenOTT
Copy link

Has anyone tried this yet? Just looking at it, and thinking about giving it a try

@knvpk
Copy link

knvpk commented Nov 18, 2015

+1

@rauhryan
Copy link
Member

For anyone that is interested in claiming the GitLab support bounty.

Feel free to contact me personally via email or DM me on twitter if you have any questions regarding the somewhat unusual metaprogramming techniques in Ghee or my opinions on how the GitLab integration should best be implemented

Contant info:
📧 [email protected]
🐦 rauhryan

Ryan Rauh
CEO & FOUNDER
HuBoard, Inc
github: rauhryan | twitter: rauhryan

@stanhu
Copy link

stanhu commented Dec 1, 2015

I'm curious how you envision managing the differences between GitLab and GitHub APIs. For example, GitHub has a concept of organizations and teams, while GitLab only has namespaces/groups. Also, naming is a bit different:

  1. Pull requests -> Merge requests
  2. Gists -> Snippets

I have a feeling that some work would have to be made in the GitLab API to include all the features used by ghee. For example, the filtering parameters may not all be supported (e.g. mentioned).

@rauhryan
Copy link
Member

rauhryan commented Dec 1, 2015

I think the easiest way is to make Ghee behave as similarly to the GitHub API as possible.

Perhaps Ghee can be an abstraction that provides the lowest common denominator to both API's

For example, the filtering parameters may not all be supported (e.g. mentioned).

HuBoard currently doesn't use this functionality, it's probably "ok" to have some filters that silently don't work when in GitLab mode.

I think the first step to GitLab support, or at least where *I* would start, is namespacing all the GitHub stuff under a Module

@rauhryan
Copy link
Member

rauhryan commented Dec 1, 2015

It's worth noting that whomever picks up this bounty can expect that myself and my team will be available to mentor and help whenever needed

@stanhu
Copy link

stanhu commented Dec 1, 2015

Thanks, @rauhryan. I'll take a crack at it since I'm fairly familiar with the GitLab and GitHub APIs.

@rauhryan
Copy link
Member

rauhryan commented Dec 1, 2015

Awesome!

Open a PR as early as possible and we'll keep an eye on it and give you feedback.

Let me know if you need help getting the test suite going, it's currently a bit of a pain in the ass because it's technically integration tests directly against the GitHub API

@discorick
Copy link
Member

@rauhryan @stanhu , I propose we divide individual steps for this project into Ghee issues with the label "GitLab", and track them via https://huboard.com/huboard/ghee

@stanhu
Copy link

stanhu commented Dec 1, 2015

@rauhryan Not sure if this is the right place to ask, but I've set up my settings.yml appropriately, and I can run Ghee commands just fine with those credentials. But when I try to run the spec, I get odd Unauthorized errors:

$ rspec spec/ghee/api/authorizations_spec.rb 
Failures:

  1) Ghee::API::Authorizations#authorizations#list should return a list of auths
     Failure/Error: auth.size().should > 0
     Ghee::Unauthorized:
       Requires authentication
     # ./lib/ghee/errors.rb:91:in `on_complete'
     # ./lib/ghee/resource_proxy.rb:68:in `subject'
     # ./lib/ghee/resource_proxy.rb:51:in `method_missing'
     # ./spec/ghee/api/authorizations_spec.rb:11:in `block (4 levels) in <top (required)>'
     # ./spec/ghee/api/authorizations_spec.rb:8:in `block (3 levels) in <top (required)>'

Finished in 0.02637 seconds
1 example, 1 failure

I've verified the connection is setting the headers appropriately. Have you seen this before?

@rauhryan
Copy link
Member

rauhryan commented Dec 1, 2015

That test is particularly interesting, it requires a username and password and basic auth.

Please ignore it for the time being because I wouldn't recommend putting your username and password on disk in the settings.yml

Is there a way to tag a test as explict in rspec?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests