-
Notifications
You must be signed in to change notification settings - Fork 350
Add integration with Github/Bitbucket/Gitlab web hooks #163
Comments
maybe it needs some kind of per-project configuration to set the proper web hooks. in this way, you'll have a modular system that supports thirth party services. |
What about creating a gem per provider just like omniauth does for Facebook, Twitter, etc.? |
The long term goal for service integrations like these is to be API compliant with Pivotal Tracker. This means that anything that can work with tracker will work with Fulcrum with a change of URL. So for example with Github we would just modify the URL in https://github.com/github/github-services/blob/master/lib/services/pivotal_tracker.rb and get it added as a github service hook. This of course relies on the service providers like github adding the hooks, and they may not all accept them, but I think the API compliance support is the best approach. |
💯 👍 |
Should the commit information be stored as a note or reside in its own model? I'm thinking class Commit < ActiveRecord::Base
attr_accessible :commit_url, :author, :commit_message
end
class GithubCommit < Commit
end
class BitbucketCommit < Commit
end as a way to avoid storing links in the note messages and separating different providers during view generation. |
@skinnyjames what about a provider field in Commit class ? :-) if you want to to use different views on a per-provider basis, then you could do it anyway. for example:
|
@apeacox Agreed - STI was just proposed to keep options open in case different providers required different information (doubtful), and perhaps to make developing a service api more modular (the provider field storing a class rather than a string) https://gist.github.com/skinnyjames/6055085 Any thoughts? |
@skinnyjames my reply in commented code https://gist.github.com/apeacox/6062010 :-P |
@apeacox :) Here's working model using Grape API with a Github Service It adds a commit model, github_commits API file & a controller |
This could be kind of challenging because Github, Bitbucket, and Gitlab all have different payloads that they deliver for web hooks.
The text was updated successfully, but these errors were encountered: