0

Hi would like to add a "Are you sure?" prompt when deleting an item (file, folder) from the finder (like the one when emptying the trash...).
Can this be enabled?

1
  • I would try an Automator folder action. – fd0 Sep 7 '15 at 21:08
1

Yes, just lock it!

Right click the item and Get info, or select the item and hit CMD + i.

enter image description hereenter image description here

3
  • Nice, but I'm rather looking for a global solution... – OlivierLarue Sep 7 '15 at 21:06
  • This is it my friend, you might want to update the original question though. – eethirteenzz Sep 7 '15 at 21:16
  • Done : from 'an item' to 'any item' – OlivierLarue Sep 7 '15 at 21:42
0

You may configure a folder action:

  1. Enable view all files:

    defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder
    
  2. Navigate to your user folder

  3. Right-click the usually invisible Trash folder and choose Services -> Folder Actions Setup...
  4. Add a new folder action by hitting the +-sign below the right pane and add the script "add - new item alert.scpt". You may change the script by hitting the button "Edit Script" (e.g. replacing the standard message by "Are you sure?"). If you want to keep the original file "add - new item alert.scpt" make a duplicate, rename it to an arbitrary name and modify it. The script resides in /Library/Scripts/Folder Action Scripts
  5. Hit the radio button "Enable Folder Actions".
  6. Disable view all files:

    defaults write com.apple.finder AppleShowAllFiles -boolean false ; killall Finder
    

In my Yosemite VM the folder action is slightly unresponsive and the alert occurs not until after 2-3 seconds.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .