Automate Your Screenshots Organisation

In this tutorial, we'll make a shell script that executes every day at 12 pm on your Mac…

S10ry
1 min readApr 3, 2020

As a developer I find myself taking screenshots all the time and I end up with a clogged desktop crowed with screenshots. Let’s move these screenshots in a designated folder.

Here’s how to automate the process:

1 - Open your terminal and type

 cd ~/Documents && mkdir Screenshots Scripts 

This will create two folders named Screenshots and Scripts in the Documents folder.

2 - Open a text editor and type

cd ~/Desktop && mv Screenshot* ~/Documents/Screenshots

Save the file as screen_shots.sh in the /Documents/Scripts folder.

If you run this command you will have noticed that your screenshots are no longer on your desktop.

3 - Open your terminal and type

env EDITOR=nano crontab -e

This command will open crontab in your nano editor, which is used to run tasks in the background at regular intervals.

4 - In your nano editor type

 0 12 * * * ~/Documents/Scripts/screen_shots.sh

— Press CTRL + X.

— Press Y then press enter.

Your screenshots will now be moved automatically every day at 12 pm.

--

--