I have many files with .txt extension. How to remove .txt extension for multiple files in linux?
I found that
rename .old .new *.old
<
In Fish, you can do
for file in *.old
touch (basename "$file" .old).new
end
The Perl version of rename can remove an extension as follows:
rename 's/\.txt$//' *.txt
This could be combined with find in order to also do sub-folders.
execute in bash linux
for i in *;do mv ${i} ${i/%.pdf/} ;done