mirror of
https://github.com/danog/gift.git
synced 2024-11-30 04:19:37 +01:00
two bugs: repo#commit's optional options parameter and repo#sync's required branch parameter
This commit is contained in:
parent
6b759b7fbf
commit
fbb3f3943b
@ -215,6 +215,7 @@ module.exports = class Repo
|
||||
#
|
||||
commit: (message, options, callback) ->
|
||||
[options, callback] = [callback, options] if !callback
|
||||
options ?= {}
|
||||
options = _.extend options, {m: "'#{message}'"}
|
||||
@git "commit", options, (err, stdout, stderr) ->
|
||||
callback err
|
||||
@ -246,7 +247,7 @@ module.exports = class Repo
|
||||
#
|
||||
# callback - Receives `(err)`.
|
||||
#
|
||||
sync: (callback) ->
|
||||
sync: (branch, callback) ->
|
||||
@git "stash", {}, ["save"], (err) =>
|
||||
return callback err if err
|
||||
@git "pull", {}, branch, (err) =>
|
||||
|
Loading…
Reference in New Issue
Block a user