dvtm

dynamic virtual terminal manager - with my changes
git clone https://pi.duncano.de/git/dvtm.git
Log | Files | Refs | README | LICENSE

commit 9dde63bc5131ddcc0aa13bdbfa9051d21ad98509
parent 9506759835b714620ecd3461b23e5f50e82f9e55
Author: Marc Andre Tanner <mat@brain-dump.org>
Date:   Sat, 18 Oct 2008 17:02:00 +0200

Introduce $DVTM environment variable which is set to the current version

$DVTM can be used in shell login scripts to check whether the shell
is running within dvtm.

 [ ! -z "$DVTM" ] && echo "Welcome to dvtm!";

Diffstat:
dvtm.c | 11++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/dvtm.c b/dvtm.c @@ -621,10 +621,15 @@ create(const char *args[]) { c->id = ++client_id; char buf[8]; snprintf(buf, sizeof buf, "%d", c->id); - const char *env[] = { "DVTM_WINDOW_ID", buf, NULL }; -#else - const char *env[] = { NULL }; #endif + const char *env[] = { + "DVTM", VERSION, +#ifdef CONFIG_CMDFIFO + "DVTM_WINDOW_ID", buf, +#endif + NULL + }; + c->window = newwin(wah, waw, way, wax); c->term = madtty_create(height - 1, width, scroll_buf_size); c->cmd = cmd;