dimanche 1 mars 2015

How do I swap the two last command line arguments?



$ ln -s ./dir/target.txt /path/to/source.txt{cursor here}


How do swap file typed filenames in command line? Alt+T swaps words, not filenames, resulting in ln -s ./dir/target.txt /path/to/txt.source.


Ideally the solution should also interpret "filenames with quotes.txt" correctly.


Can it be done by some readline and/or bash configuration, or by some clever use of existing shortcuts?



Aucun commentaire:

Enregistrer un commentaire