This bash function is one of my greatest creations ================================================== [Published 2020-01-17] This is the function: function o { if [[ $# -lt 1 ]]; then echo "Specify command." return 1 fi while read -ep "$* " arg; do export arg bash -ic "$* $arg" done echo } It simply lets you run a command repeatedly with optional extra arguments. Here is an example. Let's say you want to watch multiple videos in mpv with 50% volume and without having to type "mpv" or pressing up-arrow every time. This is the command: o mpv --volume=50 This will give you a prompt that looks like "mpv --volume=50 " and you can just fill in the video url or filename and press enter. When the video has finished you get the prompt again and can type or paste another argument. The great thing is that this works with your aliases and variables and you can literally write your own bash code as arguments and it will be executed. The "export arg" line makes it possible to put the argument anywhere in the command. Example: o echo x '$arg' z Give it the argument "y" and it will print "x y z y". If you don't want the last "y" you can comment it away: o echo x '$arg' z \#