Get Keyboard Maestro —http://www.keyboardmaestro.com/main/At the very least, watch their intro video. There is nothing you can't do in Keyboard Maestro ( KM ). It is turing complete as far as I can tell. A keyboard mapping tool that sort of combines Automator, Applescript and it's own drag and drop ( though you can hand code stuff if you desire ) method to creating actions.
You can exclude an action from all apps but one, or include it to all apps but one, or any combination thereof, or run only when a certain app is activated, trigger by keyboard command, time, date, temperature sensors, alerts, pretty much anything your mac does, KM can grab ahold of it. It has a full blown web admin, a large community of pre-made scripts that you just double click and they will be installed in a simple folder in Application Support. Technical Support is great aside from one issue I have had for going on 8+ years or more now, in that sometimes KM will just go deaf. In that amount of time I have had multiple different computers, various OS's, reinstalls, clean OS reinstalls, etc. I have never been able to trigger this issue on demand, it just happens at random.
With the help KM, I have been able to: ( keep in mind, it can run any native language to OS X, so python, perl, php, etc., etc., you have access to that if you desire, and you can nest that code inside of if/else conditions or triggers, or have one macro call another into a loop, or plain loops. So far, the ones I remember: Google used to have an API attached to it's "are you sure you didn't mean "bro" instead of "brow". It was one of my most used macros. I could select a word, it would take that word, pass it to googles API, and google would send me back an array of listed words that it though would better spell the word I was trying to spell. It always got it right, and I managed to get it to work with phrases as well. Then the API died and I can't decode the JS well enough to figure out how to get into it. There is also the latency issue, which was rarely noticed, but at times, it was very noticeable, due probably to my connection, not googles. Ideally I could use a local dictionary, but I have no idea how to write a spellchecker and the logic it would need to be able to perform spell checks as well as phrase checks. I need the data of billions of queries to make it work. It was really cool, select a word, press control-D for Dictionary, the word was passed to google, I got an array back. Initially I had it set to allow to to chose the word I wanted out of the list, but this was slowing me down too much and 99.9999% of the time, the first item in the army was the correct one. So I went back to just putting my cursor in the middle of a suspect word, or to the far left of right of the word. Press control-D, and KM was told to go to the beginning of the word, select right to grab the entire word, before all that, google did it's spelling magic which I shoved on the clipboard waiting for when I needed it. Since I had the word selected, and the correct word in my pasteboard, at that point, it was just a matter of KM being told to paste and I was done.
i use control as my meta key in KM often, which can run you the wrong way since the terminal is so driven by the control key. But a simple exclusion of the terminal from all of KM solves that, I rarely needed to script the terminal, the terminal is made for making scripts more or less.
I have an actual pretty much insoluble "extension" for dropbox. You install it, it is a 60 line or so bash file. It accepts files and folders dropped onto the application that I end up saving. On installation, I dig around in the .dropbox directory which is hidden in your home directory. They store your user-ID in there though. I write a temp file of your user-id for stuff I will need it for later. Now, if I have 30 jpgs I need to share with someone, I select them all, drop them on the app's icon, and they are copied to dropbox, dropbox then uploads them, but not before I use the data I grabbed from .dropbox and build a public url of the form of: https://dl.dropboxusercontent.com/u/340087/drops/05.02.15/forums-d5-194232.png
It also has some smarts, in that one jpg, gif, png, pdf, etc, will yield just one link on your clipboard and the file put in a date stamped folder. Files and folders are stamped in a way to avoid collisions so no two file of the same name will ever be able to exist in the "drops" directory that this app I made works from. Notification center works with it, so I get alerts. If you feed it a folder/directory, that will be tar'd and then gzipped. It tries to be as smart as it can about files. If it finds a file has a resource fork or data fork that needs preserving, it does it's best to use a compression of merging tool that supports the RSRC Forks and such.
I need to add a url shortener to it, but wanted to use my own, which then makes this a much harder install, and can't be 100% local, though with the release of Caddy the other day, I may be able to embed my own http server.
The above url is a sample that took me all of a drag and drop to make happen. I have others like "set file to zero bytes" which i use when I have a season of videos to watch, after I am all caught up on say Season 01 EP 07 I need to keep that file around so next week I know to look for episode 08, but I don't want the 1GB of data laying around, so I pass it to an app I made that i believe started with KM, and is now a droppable app that communicates with notification center and takes 1 or more files and runs a shell command on them. It also works perfectly with launchers like Launcher ( My personal favorite ), Alfred, and others. The really nice thing about this is I don't break concentration, it just does what it needs to do. Same for the other one, which is even better. How may times have you found the answer to your question only to load the page and fine all the links to their sample code is gone? This solves that problem for me. DropBox has a folder in it called Drops with inside has a ton of folders all dated the date that I dropped something on the little app i made. So forever, the resources that we create and post on forms and other public places, are now back under your control. Want to delete the images as people are pestering you for putting up a wrong answer and you no longer have access to email to get to the account and edit your post? Just delete the links and references, at least then, the page gets broken and hopefully an admin cleans it up.
#!/bin/sh
set -o nounset # Referencing undefined variables (which default to "")
set -o errexit # Ignoring failing commands
filename="$1"
/bin/cat /dev/null > ${filename}
osascript -e 'display notification "Your file has been set to zero bytes in length" with title "Set File to Zero Bytes"'
As a side note, if you don't want to pay for an app that can launch other apps via keyboard, there is an app that lets you define keyboard commands by naming a file, usually a script, in a special way, so that it can be parsed and then run via the keyboard. Fast Scripts I believe it is called. But seriously, I have not met a person who has bought KM that has regretted it. FastScritps has limitations that will kick in and you will end up paying, so get KM if you are going to pay, if you just want to play, try fastScripts or KM, which I believe has a 30 day trial/demo
http://www.red-sweater.com/fastscripts/
One of the best things, as EN's AppleScripting dictionary is weak and there really is no other interface to it. I don't know how happier and IFTTT get the ability to feed data right into EN, but I sure would love that ability, to talk to their API, i think I could run a backgourjnf minimal version of WebKit to render the current open tab and hopefully bypass this entire Content Protection issue. As a result, I have made a number of scripts to export and import data. EN can't truly export it's data in a format that can then be imported into a clean EN. You lose your Tags for one, you lose your notebook collections, and would have to manually select each notebook or sub-notebook, export that one, move on to the next, etc. It can be automated, but generally, like with 1Password, it backs itself up on schedule once a day if I tell it to, fast, reliable, and portable to mac, Win, and Linux, and works without owning the app, it is actually a full blown app in a special .pkg. I worry that EN has no good way to backup, and am working on a solution that will be Mac only, though I am starting to understand how the app works behind the scenes. Files are on disk as well as in cloud. But the tags and some other meta data are on disk in sqlite. I just need to write a small app that rips through your EN and matches the GUID named folder for the record up with my code, and I should be able to backup and restore EN from one machine to another without even installing the app. Get it to a point where you can just click "Restore EN data" and it will do so, download and open EN and all your data will be there, probably syncing or uploading.
There is a lot I have done in EN with KM, give it a shot as you will soon find you could not live without it. Example, if I am reading and someone mentions a movie, I will want to look at the trailer. So I select the word, press control-Y and here is what happens… 1) word/phrase is copied 2) word/phrase is stored as a variable and the word "trailer" is appended to it so it becomes [Movie_name] + "Trailer". From there, I build a few urls, one that searches Youtube, one that searches apple trailers, and a few others, they all get spawned in new tabs, the last tab being a search on a torrent site for free documentaries and such, as I don't pirate stuff.
I think with the right tools anything can be done. I do think EN needs some work and is getting a little long in the tooth at times, and I am only a 3 week old user.