mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-06-25 15:38:33 +02:00
more remote tests
This commit is contained in:
parent
04ce98fd7f
commit
d3c0fc40a3
3 changed files with 32 additions and 1 deletions
|
@ -876,6 +876,8 @@ GitEngine.prototype.descendSortDepth = function(objects) {
|
|||
|
||||
GitEngine.prototype.push = function(options) {
|
||||
options = options || {};
|
||||
var didMakeBranch;
|
||||
|
||||
if (options.source === "") {
|
||||
// delete case
|
||||
this.pushDeleteRemoteBranch(
|
||||
|
@ -887,6 +889,7 @@ GitEngine.prototype.push = function(options) {
|
|||
|
||||
var sourceBranch = this.refs[options.source];
|
||||
if (!this.origin.refs[options.destination]) {
|
||||
didMakeBranch = true;
|
||||
this.makeBranchOnOriginAndTrack(
|
||||
options.destination,
|
||||
'HEAD'
|
||||
|
@ -940,6 +943,14 @@ GitEngine.prototype.push = function(options) {
|
|||
var deferred = Q.defer();
|
||||
var chain = deferred.promise;
|
||||
|
||||
if (didMakeBranch) {
|
||||
chain = chain.then(_.bind(function() {
|
||||
// play something for both
|
||||
this.animationFactory.playRefreshAnimation(this.origin.gitVisuals);
|
||||
return this.animationFactory.playRefreshAnimation(this.gitVisuals);
|
||||
}, this));
|
||||
}
|
||||
|
||||
_.each(commitsToMake, function(commitJSON) {
|
||||
chain = chain.then(_.bind(function() {
|
||||
return this.animationFactory.playHighlightPromiseAnimation(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue