这是indexloc提供的服务,不要输入任何密码
Skip to content
This repository was archived by the owner on Aug 23, 2024. It is now read-only.

Github Merge API - Merge branch #301

Merged
merged 1 commit into from
Dec 25, 2017
Merged

Conversation

udiudi
Copy link
Contributor

@udiudi udiudi commented Dec 17, 2017

Hi,
I'm using this package for internal tool and needed an ability to create a merge, so I've added it quickly based on this api doc.

Maybe it can be useful to anyone else.

Cheers!

Copy link
Owner

@pksunkara pksunkara left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's not have a separate class for this. Just add a merge function to Repo class

create: (obj, cb) ->
@client.post "/repos/#{@repo}/merges", obj, (err, s, b, h) ->
return cb(err) if err
if s isnt 201 then cb(new Error("Merge info error")) else cb null, b, h
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merge create error

@udiudi
Copy link
Contributor Author

udiudi commented Dec 24, 2017

@pksunkara ok, will do.

Copy link
Owner

@pksunkara pksunkara left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, please remove yarn.lock and merge.js. Once that's done, please squash all the commits.

@@ -24,6 +24,9 @@ octonode = module.exports =
# [Pr](octonode/pr.html) class for github
pr: require './octonode/pr'

# [Merge](octonode/merge.html) class for github
merge: require './octonode/merge'

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't need this now.

@udiudi
Copy link
Contributor Author

udiudi commented Dec 25, 2017

@pksunkara done!
Thank you for you patience!

@pksunkara pksunkara merged commit b0e2cba into pksunkara:master Dec 25, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants