How to Add a Delete Option to the Context Menu in Mac

If you are a Mac user, you will be aware that it doesn’t lets you permanently delete files through the context menu. There is only an optio...



automator-delete-option-thumbIf you are a Mac user, you will be aware that it doesn’t lets you permanently delete files through the context menu. There is only an option “Move to Trash” that move your file for the trash and you've got to manually empty the trash to delete the file. Wouldn’t you choose great if you possibly could add a “Delete” option in the context menu in order to quickly and easily delete the file/folder?

In terminal, we can easily easily delete (or remove) a file or folder while using command “rm“. Coupled with all the “-rf” flag, we can get the system to forcefully delete personal files or folder without prompt. In this tutorial, I will explain to you how you can make use of this command, in addition to Automator, to put in a “Delete” option towards the context menu.

1. Open Automator and select “Services”.

automator-select-services

2. At the top of the correct pane, select “files or folders” in “Finder”.

automator-select-files-in-finder

3. On the left most pane, select “Utilities” and drag the “Ask for Confirmation” option towards the workflow. Enter the message to exhibit up within the confirmation dialog.

automator-confirmation-message

4. Next, drag “Run Shell Script” for the workflow. Change the “Pass input” field to “as arguments”.

automator-run-shell-script

Paste the next lines in to the shell script body:

for f in "$@" do rm -rf "$f" done   afplay "/System/Library/Components/CoreAudio.component/Contents/SharedSupport/SystemSounds/finder/empty trash.aif"

5. Lastly, save the service using the name “Delete”.

automator-delete-option

That’s it. Now when you right visit any file or folder, you ought to see a “Delete” option. Select it and it will delete the file/folder.


Binding a shortcut step to Delete file


An additional thing you can do with this newly created “Delete” service is to bind a keyboard shortcut with it. You can then press the shortcut answer to quickly delete the file.

1. In Finder, head to “Finder -> Services -> Services Preferences” in the menu bar. Locate the “Delete” option, select it and select “Add shortcut”.

services-add-delete-shortcut-key

2. Once you have set your shortcut key, you can press it once you've selected the file(s) and this will delete the selected file(s).

Enjoy!

COMMENTS

http://videohive.net/?ref=gimmegfx

http://themeforest.net/?ref=gimmegfx

http://audiojungle.net/?ref=gimmegfx

Name

blogging,255,computing,705,ebook,53,ebooks,354,freebies,358,graphics,225,IFTTT,3,internet,207,mobile,252,news,99,sharedtutor,78,slider,2,video tutorials,5,VideoHive,1156,YouTube,1005,
ltr
item
SharedTutor Tutorials For Everyone: How to Add a Delete Option to the Context Menu in Mac
How to Add a Delete Option to the Context Menu in Mac
http://i2.wp.com/imagecdn5.maketecheasier.com/2013/08/automator-delete-option-thumb.png
SharedTutor Tutorials For Everyone
http://www.sharedtutor.com/2013/09/how-to-add-delete-option-to-context.html
http://www.sharedtutor.com/
http://www.sharedtutor.com/
http://www.sharedtutor.com/2013/09/how-to-add-delete-option-to-context.html
true
1970043136941886328
UTF-8
Loaded All Posts Not found any posts VIEW ALL Readmore Reply Cancel reply Delete By Home PAGES POSTS View All RECOMMENDED FOR YOU LABEL ARCHIVE SEARCH ALL POSTS Not found any post match with your request Back Home Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sun Mon Tue Wed Thu Fri Sat January February March April May June July August September October November December Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec just now 1 minute ago $$1$$ minutes ago 1 hour ago $$1$$ hours ago Yesterday $$1$$ days ago $$1$$ weeks ago more than 5 weeks ago Followers Follow THIS PREMIUM CONTENT IS LOCKED STEP 1: Share. STEP 2: Click the link you shared to unlock Copy All Code Select All Code All codes were copied to your clipboard Can not copy the codes / texts, please press [CTRL]+[C] (or CMD+C with Mac) to copy