all repos — nixfiles @ 353a43e2df0b68b37415167ccd2b1b0af369ea11

System and user configuration, managed by nix and home-manager

zsh: New version of wprop alias to make class and instance names clearer
Alan Pearce alan@alanpearce.co.uk
Thu, 02 May 2013 09:05:57 +0100
commit

353a43e2df0b68b37415167ccd2b1b0af369ea11

parent

fe0c6cc671c9f8f2489f268856fbe98e2d759427

1 files changed, 3 insertions(+), 1 deletions(-)

jump to
M zsh/zshrczsh/zshrc
@@ -272,7 +272,9 @@ alias namecoin="~alan/applications/namecoin/src/namecoind" alias e="$EDITOR"
 alias E="SUDO_EDITOR=\emacsclient -c -a emacs\" sudoedit"
 alias aticonfig="DISPLAY=:0 \aticonfig"
-alias wprop="xprop | egrep WM_(CLASS|NAME|WINDOW_ROLE|TYPE)"
+alias wprop='xprop |awk '\''
+    /^WM_CLASS/{sub(/.* =/, "instance:"); sub(/,/, "\nclass:"); print}
+    /^WM_NAME/{sub(/.* =/, "title:"); print}'\'''
 
 alias -g ...='../..'