Carefully arrange the desktop

  1. Recording Actions

Let’s say that you want to always start up your computer with three folders open: your Desktop, your Documents, and your Downloads.

Go into Script Editor and get rid of whatever is currently there. Click “Record” and then switch to the Finder.

Hold down the Option key, pull down the Finder menu, and choose “Close All”.

Use Command-N to open a new window, and from that window open your Desktop folder.

Move your Desktop window to the upper left, and then arrange it to take up a bit less than a quarter of the screen.

Do the same for your Documents folder, but put it in the upper right.

Then do it again for your Downloads folder, but put it in the lower left.

Go back to AppleScript Editor and click “Stop”. You should have something like this:

tell application "Finder"

activate

close every window

close Finder window 1

make new Finder window

set target of Finder window 1 to folder "Desktop" of folder "jerry" of folder "Users" of startup disk

set position of Finder window 1 to {99, 44}

set bounds of Finder window 1 to {99, 44, 995, 699}

make new Finder window

set position of Finder window 1 to {1008, 44}

set bounds of Finder window 1 to {1008, 44, 1934, 700}

set target of Finder window 1 to folder "Documents" of folder "jerry" of folder "Users" of startup disk

make new Finder window

set target of Finder window 1 to folder "Downloads" of folder "jerry" of folder "Users" of startup disk

set position of Finder window 1 to {102, 730}

end tell

Next, test it. There’s one odd thing in it: after it closes every window, it tries to close each window individually. But it can’t do that, because it just closed all of them.

Delete the lines that look like “Close Finder window 1”. Your script will look like:

tell application "Finder"

activate

close every window

make new Finder window

set target of Finder window 1 to folder "Desktop" of folder "jerry" of folder "Users" of startup disk

set position of Finder window 1 to {99, 44}

set bounds of Finder window 1 to {99, 44, 995, 699}

make new Finder window

set position of Finder window 1 to {1008, 44}

set bounds of Finder window 1 to {1008, 44, 1934, 700}

set target of Finder window 1 to folder "Documents" of folder "jerry" of folder "Users" of startup disk

make new Finder window

set target of Finder window 1 to folder "Downloads" of folder "jerry" of folder "Users" of startup disk

set position of Finder window 1 to {102, 730}

end tell

You can save this as “Arrange Folders” with File Format “Application”, and every time you run it it will close all of your Finder windows and open up just the three you want, arranged the way you want them.

  1. Recording Actions