mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 10:57:58 +01:00
Fix double command output for things like :ls|ls
This commit is contained in:
@@ -359,10 +359,7 @@ const Buffer = Module("buffer", {
|
||||
* @property {string} The current top-level document's URL, sans any
|
||||
* fragment identifier.
|
||||
*/
|
||||
get URI() {
|
||||
let loc = window.content.location;
|
||||
return loc.href.substr(0, loc.href.length - loc.hash.length);
|
||||
},
|
||||
get URI() window.content.document.documentURI,
|
||||
|
||||
/**
|
||||
* @property {number} The buffer's height in pixels.
|
||||
|
||||
@@ -519,7 +519,10 @@ const CommandLine = Module("commandline", {
|
||||
commandOutput: function (xml) {
|
||||
XML.ignoreWhitespace = false;
|
||||
XML.prettyPrinting = false;
|
||||
this.echo(<>:{this.command}<br/>{xml}</>, this.HIGHLIGHT_NORMAL, this.FORCE_MULTILINE);
|
||||
if (this.command)
|
||||
this.echo(<>:{this.command}</>, this.HIGHLIGHT_NORMAL, this.FORCE_MULTILINE);
|
||||
this.echo(xml, this.HIGHLIGHT_NORMAL, this.FORCE_MULTILINE);
|
||||
this.command = null;
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@@ -328,13 +328,12 @@ const Dactyl = Module("dactyl", {
|
||||
|
||||
modifiers = modifiers || {};
|
||||
|
||||
if (!silent)
|
||||
commandline.command = str.replace(/^\s*:\s*/, "");
|
||||
for (let [command, args] in commands.parseCommands(str.replace(/^'(.*)'$/, "$1"))) {
|
||||
if (command === null)
|
||||
throw FailedAssertion("E492: Not a " + config.appName + " command: " + args.commandString);
|
||||
|
||||
if (!silent)
|
||||
commandline.command = str.replace(/^\s*:\s*/, "");
|
||||
|
||||
command.execute(args, modifiers);
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user