Skip to content

Commit

Permalink
Merge branch 'fixMessages' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
Javier Mendiara Cañardo committed Dec 17, 2014
2 parents 1b3b6e0 + e03cdf7 commit bcf8200
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 19 deletions.
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "gitftw",
"version": "0.1.0",
"version": "0.1.1",
"description": "Basic git commands wrapped in node for using in your workflows",
"main": "index.js",
"scripts": {
Expand Down Expand Up @@ -37,20 +37,20 @@
"which": "^1.0.5"
},
"devDependencies": {
"mocha-lcov-reporter": "0.0.1",
"coveralls": "^2.11.2",
"async": "^0.9.0",
"chai": "^1.10.0",
"eslint": "^0.10.0",
"istanbul": "^0.3.2",
"coveralls": "^2.11.2",
"eslint": "^0.10.2",
"istanbul": "^0.3.5",
"jaguarjs-jsdoc": "0.0.1",
"jscs": "^1.7.3",
"jscs-jsdoc": "^0.2.0",
"jsdoc": "3.2.2",
"jscs-jsdoc": "^0.3.2",
"jsdoc": "^3.2.2",
"mocha": "^2.0.1",
"mocha-lcov-reporter": "0.0.1",
"mock-spawn": "^0.2.2",
"proxyquire": "^1.1.0",
"sinon": "^1.12.1",
"proxyquire": "^1.3.0",
"sinon": "^1.12.2",
"sinon-chai": "^2.6.0"
}
}
13 changes: 8 additions & 5 deletions src/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,10 @@ module.exports = function commonCommands(git) {

var args = [
'commit',
'-m"' + options.message + '"',
options.force ? '--amend' : null,
options.noVerify ? '-n' : null
options.noVerify ? '-n' : null,
options.message ? '-m' : null,
options.message ? options.message : null
];

return git(args)
Expand Down Expand Up @@ -358,7 +359,8 @@ module.exports = function commonCommands(git) {
'merge',
options.noFF ? '--no-ff' : null,
options.remote ? (options.remote + '/' + options.branch) : options.branch,
'-m"' + options.message + '"'
'-m',
options.message
];

return git(args)
Expand Down Expand Up @@ -458,8 +460,9 @@ module.exports = function commonCommands(git) {
var args = [
'tag',
options.tag,
options.message ? '-m "' + options.message + '"' : null,
options.annotated ? '-a' : null
options.annotated ? '-a' : null,
options.message ? '-m' : null,
options.message ? options.message : null
];

return git(args)
Expand Down
8 changes: 5 additions & 3 deletions test/command.commit.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ describe('commit command', function() {
var call = mockSpawn.calls.pop();
expect(call.args).to.be.eql([
'commit',
'-m"cha"',
'--amend',
'-n'
'-n',
'-m',
'cha'
]);
});
});
Expand Down Expand Up @@ -55,7 +56,8 @@ describe('commit command', function() {
var call = mockSpawn.calls.pop();
expect(call.args).to.be.eql([
'commit',
'-m"cha"'
'-m',
'cha'
]);
});
});
Expand Down
6 changes: 4 additions & 2 deletions test/command.merge.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ describe('merge command', function() {
'merge',
'--no-ff',
'origin/develop',
'-m"merge it"'
'-m',
'merge it'
]);
});
});
Expand All @@ -38,7 +39,8 @@ describe('merge command', function() {
'merge',
'--no-ff',
'develop',
'-m"merge it"'
'-m',
'merge it'
]);
});
});
Expand Down

0 comments on commit bcf8200

Please sign in to comment.