commandlinefu.com is the place to record those command-line gems that you return to again and again.
Delete that bloated snippets file you've been using and share your personal repository with the world. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.
If you have a new feature suggestion or find a bug, please get in touch via http://commandlinefu.uservoice.com/
You can sign-in using OpenID credentials, or register a traditional username and password.
First-time OpenID users will be automatically assigned a username which can be changed after signing in.
Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.
Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):
Subscribe to the feed for:
works the same, but uses festival instead of espeak
allows command to use switches
Will finish automagically when mplayer quits. Can be run from any directory.
It seems to finish by it self rarely, probably because of some timing issue? There's probably a way around that which I can't think of right now
The previously-posted one-liner didn't work for me for whatever reason, so I ended up doing this instead.
Useful contexts :
You are doing yoga or some other physical training in which you are holding a position.
Or you practice the pomodoro productivity technique.
Or your girlfriend said "We're leaving in 40 minutes".
sleep executes before espeak to give you a 5 seconds head start.
espeak is run in the background so it doesn't mess up the timing.
combination of several of the above
change the time that you would like to have as print interval
and just use it to say whatever you want to
Use the excellent sensiblepasswords.com to a generate random (yet easy-to-remember) password every second, and copy it to the clipboard. Useful for generating a list of passwords and pasting them into a spreadsheet.
This script uses "madebynathan"'s "cb" function (http://madebynathan.com/2011/10/04/a-nicer-way-to-use-xclip/); you could also replace "cb" with
xclip -selection c
Remove "while true; do" and "; done" to generate and copy only 1 password.
Found on https://bitcointalk.org/index.php?topic=55520.0
Checks whether your power supply is still plugged in.
If not it will trigger an alarm at maximum volume.
Yeah yeah, another "render man page in pdf", but this time it creates a temporary PDF that stays resident in memory for viewing, but is eliminated on the filesystem.
Replace evince with your PDF viewer of choice.
There are a lot of commands, which invokes your player at specified time. But I prefer not to jump from by bed, when alarm start to play. Instead, this script increases volume of mpd over time, which much more pleasant when you just woke up :)
Original submitted version would break if any filenames had whitespaces in them. The command is a Bad Idea anyhow, because you will end up `cat`ing a binary or something else specacularly bad.
The better alternative to #9756.
I don't think I'd ever use the original command, but this one was so bad I had to post this. Sorry.
1. $(ls) is dumb, and will give errors if you have an alias like "ls -Fs"
2. clear is better and more portable than reset state.
3. if you're interested in differences, then use diff, not cat.
poorman's ifstat using just sh and awk. You must change "eth0" with your interface's name.
this will open a new tab in firefox for every line in a file
the sleep is removable but i found that if you have a large list of urls 50+, and no sleep, it will try to open all the urls at once and this will cause them all to load a lot slower, also depending on the ram of your system sleep gives you a chance to close the tabs before they overload your ram, removing & >2/dev/null will yield unpredictable results.
This uses curl to find out the access times of a web service
I'm flat-out surprised that minecraft directory services require servers install multiple modifications to their server code, when the directories could fetch this information on their own.
Testing in a TTY terminal , not emulator .
In this case it runs the command 'curl localhost:3000/site/sha' waiting the amount of time in sleep, ie: 1 second between runs, appending each run to the console.
This works well for any command where the output is less than your line width
This is unlike watch, because watch always clears the display.
shell loop to scan netstat output avoiding loolback aliases (local/remote swap for local connections)
Automation click every 4 second on a macro slot bar to world of warcraft for prospecting item
enable auto loot and create macro, put mouse over slot on the bar
/use Elementium Ore
When aliens invade Earth, be first to warn your neighbours by placing your computer screen at a window and executing this potentially Earth-saving command.
Ctrl C when aliens are defeated.
No need to install additional packages