@postcd
About copying a single file with long name and giving such copy an “incremented” name: there’s no simple way to perform what you’re asking in a shell, but a less complicated one is this:
f=$(echo "long_file - name here! ěščřžýáíé") ; cp "$f.ext" "$f - backup.ext"
If you want to copy multiple files and rename each one of them during the same process, and you want it all done in the shell, then you need to create a shell script, as explained here.
I’d however strongly recommend you to install the Thunar file manager instead, because it’s capable of bulk renaming files, i.e. you can use Thunar to create a duplicate (copy) of all desired files and then use Thunar’s bulk-renaming capabilities in order to rename all such duplicates at once (e.g. replace blablabla*-copy.ext
for blablabla*_backup.ext
).
If you happen to be running Linux in a console-only terminal (i.e. no GUI / no Desktop Environment), you may install and use Midnight Commander in order to perform bulk file renaming (it also performs bulk file copying). This program’s name in the shell is mc
, and on Debian-based distros (such as Ubuntu and Mint) you install it by issuing this command:
sudo apt install mc -y
You therefore run Midnight Commander by issuing the command mc
at the shell terminal. If you run e.g. mc /tmp
then Midnight Commander will be started showing you the contents of /tmp
. If however you just run mc
, then Midnight Commander will be started showing you the current directory. If prior to running mc
you want to know what is your current directory in the shell terminal, run pwd
to print the working directory.