I've been making changes to my .inputrc file to improve my command line experience in bash shell and other readline interfaces. I like enabling vi mode to use the key bindings of my preferred editor. I recently was made aware that the setting to do this unsets all previously set custom key bindings in the .inputrc, even for keys that aren't directly used by the mode. This led to some confusion for me when my custom keys weren't working.
shell posts
Using pipes to augment IO of command with bash script
I like the interactive mode of the bc command line calculator because it is ubiquitous, but wanted to augment its functionality a bit to add a couple features I liked from another calculator program. I wanted to make modifications to the text I typed before sent to bc and modify the text it outputted. This can be done on standard POSIX shells with mkfifo, but it took me a good while to figure out how to do this with both input and output and get something working nicely without it freezing or leaving artifacts. So I'm sharing how to do this in a bash script.
Color shell prompt for available colors
I wanted to make my command line shell prompt to be more noticeable and nicer with some color. I wanted to take advantage of 256 colors when available, but fall back to a simpler color scheme when only 8 colors are available, and to no colors if none are available.
Continue reading post "Color shell prompt for available colors"Replacing text in PDF
I recently found myself needing to replace some text in a PDF for confidentiality reasons. Continue reading post "Replacing text in PDF"
Simple shell calculator
I've made myself a simple command line calculator using bc.
Continue reading post "Simple shell calculator"
Moving folder symlink and trailing slash
It caught me by surprise that if you use mv on a symlink to a folder and have a…
Continue reading post "Moving folder symlink and trailing slash"The Happs
Shell Games I have been toying with some shell alternatives to bash; fish and z…
Continue reading post "The Happs"