]> git.madduck.net Git - etc/xsession.git/commitdiff

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

store temp xsession errors file on cleanup master
authormartin f. krafft <madduck@madduck.net>
Thu, 3 Feb 2022 06:36:01 +0000 (07:36 +0100)
committermartin f. krafft <madduck@madduck.net>
Thu, 10 Feb 2022 09:27:53 +0000 (10:27 +0100)
.Xresources
.bin/xconfig
.config/autorandr/postswitch
.config/vcsh/hooks-enabled/post-clone.xsession-update [moved from .config/vcsh/hooks-enabled/xsession.post-clone with 100% similarity]
.config/vcsh/hooks-enabled/post-enter.xsession-update [moved from .config/vcsh/hooks-enabled/xsession.post-enter with 100% similarity]
.config/vcsh/hooks-enabled/post-pull.xsession-update [moved from .config/vcsh/hooks-enabled/xsession.post-pull with 100% similarity]
.config/vcsh/hooks-enabled/post-run.xsession-update [moved from .config/vcsh/hooks-enabled/xsession.post-run with 100% similarity]
.xkb/symbols/madduck
.xsession

index 46cf3648c1f94bdec1b0800d35ebb4489c527e7a..ec47849a3f215d5a377c7f7d94d34ccb38c812f4 100644 (file)
@@ -71,7 +71,7 @@ URxvt.matcher.rend.1:          Uline
 // URxvt.background:              rgba:0000/0000/0000/dddd
 URxvt.transparent:             false
 
 // URxvt.background:              rgba:0000/0000/0000/dddd
 URxvt.transparent:             false
 
-URxvt.termName:                 rxvt-unicode
+URxvt.termName:                 rxvt-unicode-256color
 
 URxvt.keysym.A-t:               eval:{ use POSIX qw(strftime); $self->{term}->tt_write_user_input($self->{term}->locale_encode(POSIX::strftime("%F", localtime))) }
 URxvt.keysym.A-T:               eval:{ use POSIX qw(strftime); $self->{term}->tt_write_user_input($self->{term}->locale_encode(POSIX::strftime("%F-%H%M%S", localtime))) }
 
 URxvt.keysym.A-t:               eval:{ use POSIX qw(strftime); $self->{term}->tt_write_user_input($self->{term}->locale_encode(POSIX::strftime("%F", localtime))) }
 URxvt.keysym.A-T:               eval:{ use POSIX qw(strftime); $self->{term}->tt_write_user_input($self->{term}->locale_encode(POSIX::strftime("%F-%H%M%S", localtime))) }
index 6d09d4ad3ce77aa0efa9d26fe49ab97e5d6c0ea9..06fac0cafee3cfb884a29dedcbf54ba697487f1c 100755 (executable)
@@ -32,9 +32,20 @@ load_xresources() {
   xrdb -load ~/.Xresources
 }
 
   xrdb -load ~/.Xresources
 }
 
+config_xinput() {
+  echo -n >&2 " xinput"
+  xinput set-float-prop "TPPS/2 IBM TrackPoint" "Device Accel Constant Deceleration" 0.7 2>/dev/null || :
+
+  WIRELESS_RECEIVER=$(xinput | sed -rne 's,.*Lenovo USB Receiver[[:space:]]+id=([[:digit:]]+).*pointer.*,\1,p')
+  if [ -n "$WIRELESS_RECEIVER" ]; then
+    xinput set-button-map $WIRELESS_RECEIVER 1 2 3 4 5 6 7 0 0 0 >/dev/null || :
+  fi
+}
+
 echo -n >&2 "Configuring X ["
 [ -n "${SKIP_XKB:-}" ] || config_xkb
 [ -n "${SKIP_XSET:-}" ] || config_xset
 [ -n "${SKIP_XSETROOT:-}" ] || config_xsetroot
 [ -n "${SKIP_XRESOURCES:-}" ] || load_xresources
 echo -n >&2 "Configuring X ["
 [ -n "${SKIP_XKB:-}" ] || config_xkb
 [ -n "${SKIP_XSET:-}" ] || config_xset
 [ -n "${SKIP_XSETROOT:-}" ] || config_xsetroot
 [ -n "${SKIP_XRESOURCES:-}" ] || load_xresources
+[ -n "${SKIP_XINPUT:-}" ] || config_xinput
 echo >&2 " ] done."
 echo >&2 " ] done."
index 49325d034690570d63d5ba0913582d5e0ef7ef21..fcabf4664ad89fcf3256277c378d195e23622a7c 100755 (executable)
@@ -9,3 +9,7 @@ if command -v awesome-client >/dev/null; then
   echo "handle_new_autorandr_profile(\"$AUTORANDR_CURRENT_PROFILE\")" |
     awesome-client >&2
 fi
   echo "handle_new_autorandr_profile(\"$AUTORANDR_CURRENT_PROFILE\")" |
     awesome-client >&2
 fi
+
+sleep $DELAY
+
+~/.bin/xconfig >&2
index 3471a8d32e34753a8b552ec9d29139b45d5a1d55..ef781b3ccefbb8c61977471c204705c0d7945052 100644 (file)
@@ -72,6 +72,9 @@ xkb_symbols "group2_intl" {
   key <BKSP> {
     symbols[Group2] = [ BackSpace, BackSpace ]
   };
   key <BKSP> {
     symbols[Group2] = [ BackSpace, BackSpace ]
   };
+  key <SPCE> {
+    symbols[Group2] = [ nobreakspace, nobreakspace ]
+  };
   key <TAB> {
     symbols[Group2] = [ Tab, Tab ]
   };
   key <TAB> {
     symbols[Group2] = [ Tab, Tab ]
   };
index 1c92e340e1db595b3f46548bd19e2922d4b0aaea..ea1683e9623d456e64333dabdd9a9d8ec0cc332f 100755 (executable)
--- a/.xsession
+++ b/.xsession
@@ -11,6 +11,15 @@ elif [ -L /tmp/xsession-$LOGNAME ]; then
 fi
 chmod 600 $NEW_ERRFILE
 ln -sf $NEW_ERRFILE $HOME/.xsession-errors
 fi
 chmod 600 $NEW_ERRFILE
 ln -sf $NEW_ERRFILE $HOME/.xsession-errors
+
+TRAPS="0 1 2 3 4 5 6 7 8 10 11 12 13 14 15"
+cleanup() {
+  rm -f $HOME/.xsession-errors
+  mv $NEW_ERRFILE $HOME/.xsession-errors
+  trap - $TRAPS
+}
+trap cleanup $TRAPS
+
 exec >>$NEW_ERRFILE 2>&1
 
 set -u
 exec >>$NEW_ERRFILE 2>&1
 
 set -u