diff --git a/screen.changes b/screen.changes index 31a9857..533bc45 100644 --- a/screen.changes +++ b/screen.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Feb 18 09:04:34 UTC 2013 - trenn@suse.de + +- Introduce Xx string escape showing the executed command of a window + patch: show_all_active.patch + ------------------------------------------------------------------- Tue Feb 5 19:06:46 UTC 2013 - trenn@suse.de diff --git a/screen.spec b/screen.spec index 90789bf..b5f0099 100644 --- a/screen.spec +++ b/screen.spec @@ -51,6 +51,7 @@ Patch9: use_locale.diff Patch10: screen-poll-zombies.patch Patch11: screen_enhance_windows_list_1_3.patch Patch12: screen_enhance_windows_list_2_3.patch +Patch13: show_all_active.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %description @@ -75,6 +76,7 @@ Documentation: man page %patch10 -p1 %patch11 -p1 %patch12 -p1 +%patch13 -p1 %build CFLAGS="-DMAXWIN=1000 $RPM_OPT_FLAGS" %configure --prefix=/usr --infodir=%{_infodir} \ diff --git a/show_all_active.patch b/show_all_active.patch new file mode 100644 index 0000000..8de546e --- /dev/null +++ b/show_all_active.patch @@ -0,0 +1,50 @@ +screen: Introduce Xx string escape showing the executed command of a window + +either only the executed command ('X') or the whole command line ('x') of +each window is shown. + +Signed-off-by: Thomas Renninger + +diff --git a/doc/screen.1 b/doc/screen.1 +index 7a0c1de..57352f1 100644 +--- a/doc/screen.1 ++++ b/doc/screen.1 +@@ -3750,6 +3750,10 @@ window; with '+' qualifier: starting with the window after the current + one. + .IP W + all window numbers and names except the current one ++.IP x ++the executed command including arguments running in this windows ++.IP X ++the executed command without arguments running in this windows + .IP y + last two digits of the year number + .IP Y +diff --git a/screen.c b/screen.c +index efb73d3..e8a553c 100644 +--- a/screen.c ++++ b/screen.c +@@ -2681,6 +2681,23 @@ int rec; + } + p += strlen(p) - 1; + break; ++ case 'X': case 'x': ++ if (!win) ++ break; ++ if (win->w_cmdargs[0]) { ++ sprintf(p, "%s", win->w_cmdargs[0]); ++ p += strlen(p); ++ } ++ else ++ break; ++ if (*s == 'x') { ++ for (i = 1; win->w_cmdargs[i]; i++) { ++ sprintf(p, " %s", win->w_cmdargs[i]); ++ p += strlen(p); ++ } ++ } ++ p--; ++ break; + case 'l': + #ifdef LOADAV + *p = 0;