Terminal: Bulk Actions
Change Filenames
Example:
Change the string Bildschirmfoto
to Screenshot
in all filnames in the current dir.
for i in *Bildschirmfoto*.png; do [[ -e ${i/Bildschirmfoto/Screenshot} ]]
Alternative:
mv "$i" "${i/Bildschirmfoto/Screenshot}"; done
Download files with curl
Download several files with curl:
curl -O https://domain.com/image.jpgcurl -O https://domain.com/image2.jpg
Search folder (and subfolders) for a specific file type (e.g. jpg
, jpeg
or png
) and copy the files to another folder:
find 'path/to/folder' -type f -name "*png" -exec cp {} 'path/to/another/folder' \;
Create folders from .txt file
Create a folders.txt
file with folder names (no blank spaces!) in seperate lines:
Folder-01Folder-02Another-Folder
Open terminal and cd
to dir with the folders.txt
file (i.e. the Desktop)
cd /Users/username/Desktop
then run
cat folders.txt | xargs mkdir