How do you rename the files(*.sh) with file names containing space in it?for example "interview question.sh" needs to rename to "interview-question.sh".
Appreciate your inputs.Thanks.
Answer Posted / indusharma5
I tried following, but it doesn't work.
find . -name "*.sh" -0 -print0| xargs -n1 -I{} -0 sh -c '`mv {} echo "{}"|sed -n 's/ /-/g'`'
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is the significance of the shebang line in shell scripting?
What is the difference between scripting and coding?
What does egrep mean?
What is option in shell script?
What are scripts in psychology?
Is powershell a bash?
Is shell scripting easy to learn?
What is the command to find out users on the system?
how to print the matrix form of 2-d, 3-d arrays in unix c shell scripts ?
What is the fastest scripting language?
What is the use of a shebang line?
Explain about the exit command?
What is scripting autism?
How do I run a shell script on a mac?
Write a shell script that adds two numbers if provided as the command line argument and if the two numbers are not entered throws an error message.