From 789e2efda151fe7d4f71813c0b5211c4f37ee4df Mon Sep 17 00:00:00 2001 From: Peter Cottle Date: Sun, 30 Jul 2017 14:23:23 -0700 Subject: [PATCH] Resolves #435 -- pushing tags --- src/js/git/index.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/js/git/index.js b/src/js/git/index.js index ce996c57..83ed6b8f 100644 --- a/src/js/git/index.js +++ b/src/js/git/index.js @@ -1052,6 +1052,12 @@ GitEngine.prototype.push = function(options) { } var sourceBranch = this.refs[options.source]; + if (sourceBranch && sourceBranch.attributes.type === 'tag') { + throw new GitError({ + msg: intl.todo('Tags are not allowed as sources for pushing'), + }); + } + if (!this.origin.refs[options.destination]) { this.makeBranchOnOriginAndTrack( options.destination,