You are not logged in.
Pages: 1
Just a thought - would we want a pipemenu for xbindkeys?
#!/bin/bash
mapfile -t lines <"$HOME/.xbindkeysrc"
for i in "${!lines[@]}"; do
# Look for the lines that begin with double quote
[[ ${lines[i]} == \"* ]] || continue
# Print the comment which @johnraff has helpfully added before
# as well as the actual keybinding on the following line
printf '%s\n' "${lines[i-1]/\# /} ${lines[i+1]/ /}"
done
Offline
^Looks ideal.
Added to ToDo list - thanks!
John
--------------------
( a boring Japan blog, idle Twitterings and GitStuff )
In case you forget, the rules.
Offline
@malm, What/Where is 'mapfile'?
Offline
@brontosaurusrex
It's a bash builtin which reads a file into an array.
See Bash-Builtins.html
It's fast and clean
Offline
Thanks ^.
Offline
Pages: 1