Jump to content
Ginfuru

Run Simple Terminal Command in Alfred

Recommended Posts

Here is a simple workflow the combines several basic (and frequently used) commands to help speed up your processes. There are several other workflows that do one or a couple of these... but I just combined them into one.

 

Keyword Trigger run followed by:

purge, flush, ip, show or hide, finder, dock or ow

 

purge - frees up RAM

flush - flushes your DNS

ip - shows your public IP

show - shows hidden files

hide - hides file that should be hidden

finder - relaunches the Finder.app

dock - relaunches the Dock

ow - relaunches the Finder.app and clears out the Open with Menu to only show the current versions of those Apps (bug in Mt. Lion) 

 

UPDATE - a collection of a bunch of workflows and terminal commands. 

relaunch - kills finder

desktop - hides items on your desktop

hidden - show/hide hidden files

purge - frees up RAM

owrest - ow - relaunches the Finder.app and clears out the Open with Menu to only show the current versions of those Apps (bug in Mt. Lion) 

lprest - resets launch pad

flush - OS Mavericks flushing of the DNS

wifi - turn on wifi see current network and get current network IP

ip - get your internal and external (public) IP

zip (or set hotkey) - creates archive of selected items

empty downloads - cleans out the downloads folder

space - gives you the remaining and used space % of internal and attached drives

subl - opens a file or project in Sublime Text 

 

Simple to edit and modify to add more... 

 

 

Download link : http://d.pr/f/1hMXB

Edited by Ginfuru

Share this post


Link to post

Here is a simple workflow the combines several basic (and frequently used) commands to help speed up your processes. There are several other workflows that do one or a couple of these... but I just combined them into one.

 

Keyword Trigger run followed by:

purge, flush, ip, show or hide, finder, dock or ow

 

purge - frees up RAM

flush - flushes your DNS

ip - shows your public IP

show - shows hidden files

hide - hides file that should be hidden

finder - relaunches the Finder.app

dock - relaunches the Dock

ow - relaunches the Finder.app and clears out the Open with Menu to only show the current versions of those Apps (bug in Mt. Lion) 

 

 

Simple to edit and modify to add more... 

 

Download it - http://rnydm.us/NeFX

 

Finally, a solution to the "open with.." list bug! Thanks so much :D

Share this post


Link to post

Finally, a solution to the "open with.." list bug! Thanks so much :D

No problem :D

 

Also if you have other commands you find helpful, please share ! 

Share this post


Link to post

uptime ! Haha :D
But i think i already saw a workflow with that command.

Seriously, nice & useful workflow ! Thanks :)

Share this post


Link to post

Now that i tried it, i've got a tiny feedback : when the text of the echo is too long, it's truncated instead of returning.

Share this post


Link to post

Now that i tried it, i've got a tiny feedback : when the text of the echo is too long, it's truncated instead of returning.

which command are you running? 

Share this post


Link to post

which command are you running? 

 

Well the command dock for instance. Or even the fallback echo when you typed wrong.

Is it just me ?

Share this post


Link to post

I'm using Growl for my notifications... I'm assuming you're using Notification Center instead or maybe your Growl theme is causing an issue??

 

my growl output:

Screen%20Shot%202013-03-20%20at%209.57.4

 

my notification center output: (assuming this is what you're seeing??)

Screen%20Shot%202013-03-20%20at%209.59.1

To get around that I would create separate keyword triggers,  for each terminal command and Set the output to this: 

 

Screen%20Shot%202013-03-20%20at%2010.03.  NOTIFICATION CENTER OUTPUT →→→Screen%20Shot%202013-03-20%20at%2010.02.

 

rts.png

 

Out put will look similar to this: 

output.png

Edited by Ginfuru

Share this post


Link to post

Actually i'm not using Notification Center, i'm on OSX 10.7.

So it's really Growl but an old version (1.2.2), maybe it's the issue.

Share this post


Link to post

Actually i'm not using Notification Center, i'm on OSX 10.7.

So it's really Growl but an old version (1.2.2), maybe it's the issue.

Well if you find out a fix... please share it 

Share this post


Link to post

Well if you find out a fix... please share it 

I think i got something. The easiest i could find.

It appears that, in the notification object, when you don't specify anything, the echo goes in the first place it can find, in this case the title.

Simply, type {query} in the text slot and now you're good.

Well, it's not bold text, but stil better that truncated text :3

Share this post


Link to post

I've updated the link... but the workflow has changed a lot since then... you'll need to modify it to fit your computer. 

 

 

Download link is not working.

 

Can you update it please? Thanks.

Share this post


Link to post

Hi,

 

Your link...Download link : http://i.makitra.in/TOcT...seems to be broken again.  Mind you it is 2 years after the post.

 

I am still using MTn Lion and many of your workflows work for me

This one works - http://d.pr/f/1hMXB

 

If you want to flush your DNS be sure to update the script since you're on Mt Lion 

dscacheutil -flushcache | sudo killall -HUP mDNSResponder
Edited by Ginfuru

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...