I need to cut some first characters from file name in current mc panel and create hard link in pasive mc panel with this name. Example:
ls 001-a\ b.flac | cut -c 5- | xargs -0 -I{} echo ln %p %D/{}
I get expectet result:
ln 001-a b.flac /srv/Music/a b.flac
But, without echo:
ls 001-a\ b.flac | cut -c 5- | xargs -0 -I{} ln %p %D/{}
I get result:
ln 001-a b.flac /srv/Music/a b.flac.
With DOT at the end of file name in pasive panel
I've found similar question how to remove final “dot” from directory name. But how can I avoid this DOT at the end of file name in mc extension command?
PS
problem xpression in mc extension file:
regex/i/\.flac
Open=ls %p | cut -c 5- | xargs -0 -I{} ln %p %D/{}
ADDED SOLUTION ?
how make playlists with hard links and refactory names of songs in it I found in "How can i pass all arguments with xargs in middle of command in linux"
ln %p %D/"`ls %p | cut -c 5- `"
It works in mc envirounment only