Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- #This script allows files with the same name and different extension to be sorted in a folder with name, same as the file name. This is useful, when I download my Linux Journal magazines in different file formats and have to import them into Calibre
- books="*.*"
- for f in ${books}
- do
- dirname=$(echo $f | cut -f1 -d'.' )
- echo $dirname
- mkdir -p $dirname
- mv $f $dirname
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement