recentpopularlog in

inputrc

« earlier   
bash - How do I enable automatic history expansion for commands using 'magic space'? - Ask Ubuntu | https://askubuntu.com/
So what this does is expand, for example, "!!" into the last command entered when you press space. It's kinda nice.
bash  dotfile  inputrc  readline  magicspace  configfile 
december 2019 by kme
bash - How to set Readline key bindings using ALT (Meta) or some other control key as prefix instead of `C-` and `e`? - Unix & Linux Stack Exchange | https://unix.stackexchange.com/
There are too many questions in one question, but this one's interesting:
Furthermore, how can I control the "timeout" that should occur before a key binding, that is a prefix of a longer key binding, is executed?
macos  inputrc  keybindings  terminal.app  terminal 
december 2019 by kme
How to Set Readline key bindings in both vi-command and vi-insert modes - Unix & Linux Stack Exchange | https://unix.stackexchange.com/
The "bind" keyword should not be in inputrc. The following inputrc works as intended. Ctrl-B transpose words in both insert and command mode:
<code class="language-bash">
set editing-mode vi
$if mode=vi
set keymap vi-command
Control-b: transpose-words
set keymap vi-insert
Control-b: transpose-words
$endif
</code>
readline  inputrc  vikeybindings  configfile 
december 2019 by kme
bash vi-mode triggers (arg: 200) prompt when pasting · Issue #947 · Guake/guake | https://github.com/
This was affecting me on elementaryOS Juno with Guake *and* the elementary Terminal app.

Workaround is to 'set enable-bracketed-paste off', which isn't great?
vim  guake  vikeybindings  inputrc  readline  bracketedpaste  annoyance  sortof  solution 
december 2019 by kme
bash - Shell vi mode prints (arg: repetition): How to remove it? - Unix & Linux Stack Exchange | https://unix.stackexchange.com/
I was getting (arg: 200) because I had bracketed paste mode enabled in my ~/.inputrc. Turns out that was a bug (?) in an old version of vte. But this explains what that message actually means.
readline  inputrc  vikeybindings  reference 
december 2019 by kme
Shell Tricks: .inputrc binding fun - BrettTerpstra.com
In Bash, there are some great but lesser-known default bindings. You may know that Option-. will insert the last argument of the previous command (e.g. running ls ~/Desktop and then typing cd and pressing Option-. will turn it into cd ~/Desktop), but did you know you can actually yank the argument at any index from the last command (without using history or ! operators)?

Just press Option-[#], where # is the position of the argument you want, then type Option-. to insert it in the current command.
inputrc  bash  dotfile  configfile 
august 2019 by kme
Linuxart » Blog Archive » Super-useful inputrc | https://web.archive.org/
Not sure if really *any* of these work. Or maybe they just *work* now, by default, for most Linux distros, since this post was from 2005.
inputrc  dotfile  configfile 
april 2019 by kme
A ~/.inputrc for Humans - Top Bug Net | https://www.topbug.net/
<code class="language-inputrc">
$include /etc/inputrc
"\C-p":history-search-backward
"\C-n":history-search-forward

set colored-stats On
set completion-ignore-case On
set completion-prefix-display-length 3
set mark-symlinked-directories On
set show-all-if-ambiguous On
set show-all-if-unmodified On
set visible-stats On
</code>

I would add these, too:
<code class="language-inputrc">
$if mode=vi
set keymap vi-command
# these are for vi-command mode
"\e[A": history-search-backward
"\e[B": history-search-forward

set keymap vi-insert
# these are for vi-insert mode
"\e[A": history-search-backward
"\e[B": history-search-forward

# source: https://brettterpstra.com/2015/07/09/shell-tricks-inputrc-binding-fun/
"\e[1;5C": forward-word
"\e[1;5D": backward-word
$endif
</code>
bash  commandline  editing  configfile  dotfile  movein  essential  newbie  inputrc  readline 
april 2019 by kme
bash - .inputrc TAB not behaving as expected - Unix & Linux Stack Exchange | https://unix.stackexchange.com/
Readline doesn't know anything about a modifier called Shift, and quietly ignores unknown modifier names. Try wibble-TAB.
unix  bash  readline  inputrc  annoyance  workaround  solution 
november 2018 by kme
You can make readline (and bash) much more user friendly by adding a few options to ~/.inputrc : commandline | https://www.reddit.com/
set completion-prefix-display-length 2

This one is insanely useful when you have a folder with lots of similarly named files and you are not sure how far the completion has gone when you press TAB. The first part that has been completed will be replaced by "...", and it is simple to see what you need to type to finish the completion.
inputrc  input  readline  bash  cli  configfile  configsettings  example  newbie  movein  essential 
october 2018 by kme
readline - How do I reload .inputrc using a bash script? - Super User | https://superuser.com/
Use the bind command:
<code class="language-bash">
bind -f ~/.inputrc
</code>

See help bind for more information:
<code>
-f filename Read key bindings from FILENAME.
</code>
keybindings  macros  inputrc  bash  configfile  configsettings  solution 
october 2018 by kme
bash - How do I reload .inputrc? - Super User | https://superuser.com/
Interesting, but doesn't work for me.
By default, C-x C-r is bound to re-read-init-file.

See the Bash Reference Manual for explanation.


Maybe this does:
bind -f ~/.inputrc
bash  inputrc  keyboard  readline  configfile  dammitbrain 
october 2018 by kme
Disable beep of Linux Bash on Windows 10 - Stack Overflow
1) Turn off bell for bash

vi ~/.inputrc
set bell-style none
2) Turn off bell for vi

vi ~/.vimrc
set visualbell
set t_vb=
Setting the visual bell turns off the audio bell and clearing the visual bell length deactivates flashing.

--

In addition, you may have a ~/.profile file already and ~/.bash_profile may not be present, as was the case with me.
In this case, add setterm -blength 0 to the .profile.
If you create a .bash_profile, your .profile will be ignored and anything Windows wrote there will not work.
vi  vim  bash  disable  bell  inputrc  beep 
june 2018 by theskett

Copy this bookmark:





to read