1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-02-04 22:05:46 +01:00

Fix gathering of config.version from hg.

This commit is contained in:
Kris Maglione
2011-01-24 06:15:48 -05:00
parent bd431b92b5
commit 198879bc04
2 changed files with 4 additions and 3 deletions

View File

@@ -113,7 +113,7 @@ var ConfigBase = Class("ConfigBase", {
io.pathSearch("hg")) {
return io.system(["hg", "-R", uri.file.parent.path,
"log", "-r.",
"--template=hg{rev} ({date|isodate})"]);
"--template=hg{rev} ({date|isodate})"]).output;
}
}
let version = this.addon.version;

View File

@@ -436,7 +436,7 @@ var IO = Module("io", {
*
* @param {string} command The command to run.
* @param {string} input Any input to be provided to the command on stdin.
* @returns {string}
* @returns {object}
*/
system: function (command, input) {
util.dactyl.echomsg("Calling shell to execute: " + command, 4);
@@ -472,7 +472,8 @@ var IO = Module("io", {
__noSuchMethod__: function (meth, args) this.output[meth].apply(this.output, args),
valueOf: function () this.output,
output: stdout.read().replace(/^(.*)\n$/, "$1"),
returnValue: res
returnValue: res,
toString: function () this.output
};
}) || "";
},