[vte/wip/rishi/command-notify: 3/3] vte.sh: Emit OSC 777 from PROMPT_COMMAND
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte/wip/rishi/command-notify: 3/3] vte.sh: Emit OSC 777 from PROMPT_COMMAND
- Date: Fri, 30 Jan 2015 17:19:22 +0000 (UTC)
commit de1def7a5cd5d22cd45b73fb94e8afd0ed3c034b
Author: Debarshi Ray <debarshir gnome org>
Date: Thu Jan 29 13:09:17 2015 +0100
vte.sh: Emit OSC 777 from PROMPT_COMMAND
https://bugzilla.gnome.org/show_bug.cgi?id=711059
src/vte.sh | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/vte.sh b/src/vte.sh
index 2d211ca..c74cdbb 100644
--- a/src/vte.sh
+++ b/src/vte.sh
@@ -50,9 +50,10 @@ __vte_osc7 () {
}
__vte_prompt_command() {
+ local command=$(history 1 | cut -c 8- | sed s/\;/\ /g)
local pwd='~'
[ "$PWD" != "$HOME" ] && pwd=${PWD/#$HOME\//\~\/}
- printf "\033]0;%s %s:%s\007%s" "${USER}" "${HOSTNAME%%.*}" "${pwd}" "$(__vte_osc7)"
+ printf "\033]777;notify;%s;\007\033]0;%s %s:%s\007%s" "${command}" "${USER}" "${HOSTNAME%%.*}" "${pwd}"
"$(__vte_osc7)"
}
case "$TERM" in
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]