Thread: Shell Script Help
why isn't working ideas?
#!/bin/bash
# script take user input, extension, , remove files specific extension
echo "what extension u remove files names?"
read extension
rename '.$extension' '' *.$extension
echo "extension removed"
this works me:
code:#!/bin/bash # script take user input, extension, , remove files specific extension echo "what extension u remove files names?" read extension /usr/bin/rename "s/\.${extension}\$//" *.${extension} echo "extension removed"
Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [other] Shell Script Help
Ubuntu
Comments
Post a Comment