1. Massie's Avatar
    Anyone who grew up on PCs will be familiar with the old Shift+Delete trickthat combination of keystrokes that immediately and permanently nukes a file. For many, it's a surprise to find that OS X doesn't offer that functionality without cumbersome Terminal commands or third-party apps. Instead, you must first move a file to Trash, and then "empty" the Trash. Only then is a file truly gonealong with everything else in your Trash.

    But what if you only want to delete a particular file at a given time? With Automator, you can add the functionality to your context menus ("right-click" menus) using the Services workflow.

    You can create an Automator service or application to facilitate executing the rm shell commando, which will permanently delete files or folders and skip the trash.

    To begin, start by creating a new Service in the Automator app.

    Select "files or folders" as input; you may also want to limit the availability of this service to the Finder app.

    Optionalbut highly recommended to prevent accidental deletionis the addition of an Ask for Confirmation step to the workflow. Drag it into your workflow from the column at left, then customize the message and the Cancel and OK buttons to your liking.

    Finally, add the Run Shell Script step to the workflow, again dragging from left. Make sure to pass input "as arguments". Then you can put in the following script:

    for f in "$@"
    do
    rm -rf "$f"
    done

    To complete the process with a bit of audio confirmation, add the OS X "emptied trash" sound by including the following command at the end of the shell script:

    afplay "/System/Library/Components/CoreAudio.component/Contents/SharedSupport/SystemSounds/finder/empty trash.aif"

    Save your service, and it should be ready to use in Finder from the Services menu in the menu bar. You can also configure a keyboard shortcut to your service in the Keyboard preference pane of System Preferences.

    Source/Screenshots : mountain lion - How can I skip the Trash when deleting a file? - Ask Different
    Just_Me_D likes this.
    07-12-2013 09:10 PM
  2. Just_Me_D's Avatar
    07-12-2013 09:55 PM

Similar Threads

  1. I can't get Twitter to shut up!
    By blessed2bamommie in forum iPad 3
    Replies: 12
    Last Post: 11-25-2014, 12:45 PM
  2. How's tmobile treating you?
    By Vanti in forum T-Mobile
    Replies: 8
    Last Post: 03-10-2014, 05:22 AM
  3. Switch from AT&T to T-Mobile
    By grape8pe in forum AT&T
    Replies: 22
    Last Post: 12-17-2013, 10:05 PM
  4. Replies: 3
    Last Post: 07-12-2013, 11:41 PM
  5. Replies: 1
    Last Post: 07-12-2013, 09:59 PM
LINK TO POST COPIED TO CLIPBOARD