Add copy-pipe mode command to copy selection and also pipe to a command.

This commit is contained in:
Nicholas Marriott
2013-03-22 15:52:40 +00:00
parent 8478895eeb
commit 58932295fc
4 changed files with 94 additions and 23 deletions

View File

@ -138,9 +138,12 @@ cmd_list_keys_table(struct cmd *self, struct cmd_ctx *ctx)
mode = "c";
cmdstr = mode_key_tostring(mtab->cmdstr, mbind->cmd);
if (cmdstr != NULL) {
ctx->print(ctx, "bind-key -%st %s%s %*s %s",
ctx->print(ctx, "bind-key -%st %s%s %*s %s%s%s%s",
mode, any_mode && *mode == '\0' ? " " : "",
mtab->name, (int) width, key, cmdstr);
mtab->name, (int) width, key, cmdstr,
mbind->arg != NULL ? " \"" : "",
mbind->arg != NULL ? mbind->arg : "",
mbind->arg != NULL ? "\"": "");
}
}