Link to home
Start Free TrialLog in
Avatar of sam shah
sam shah

asked on

replacing file name with spaces in ibm aix.

I am using the following code  for renaming file name with white spaces to '_': -

find . -type f -name "* *.csv" -exec bash -c 'mv "$0" "${0// /_}"' {} \;

I am getting the following error: -

find: 0652-083 Cannot execute bash:: A file or directory in the path name does not exist.


please help.

Thanks in advance
ASKER CERTIFIED SOLUTION
Avatar of woolmilkporc
woolmilkporc
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of sam shah
sam shah

ASKER

thanks a lot