create the "newer than" file by: touch -t 201011151300 ./201011151300.txt the format for the time is [[CC]YY]MMDDhhmm[.SS] Show Sample Output
The same command, but with a base64 filter, more forgiving for special characters than tr. Show Sample Output
usage: where COMMIT for instance: where 1178c5950d321a8c5cd8294cd67535157e296554 where HEAD~5 Show Sample Output
finger - gets logged in users grep $(whoami) - greps only the current user (if there are more logged in) head -n1 - just one line awk '{print $2 " " $3}' - second and third word, seperated with a space (the users name) OT: My first commandlinefu-command :) Show Sample Output
Changed wget to curl and it doesn't create a file anymore. Show Sample Output
Will work with filenames with spaces inside. Will not break in case of someone making directory that matches *.pm. And sorts from largest. Where largest is file size, not line count.
This is a simple command which makes electricsheep render directly to your background
Pros: the format is very simple, there is no need to show every columns, and full command with args the first column is memory consumption % the second column is pid the third is just the command (without full arguments, most application's arguments are too long) You can decide which application to kill then. Show Sample Output
Uses UNIX time for sorting.
You can actually do the same thing with a combination of head and tail. For example, in a file of four lines, if you just want the middle two lines:
head -n3 sample.txt | tail -n2
Line 1 --\
Line 2 } These three lines are selected by head -n3,
Line 3 --/ this feeds the following filtered list to tail:
Line 4
Line 1
Line 2 \___ These two lines are filtered by tail -n2,
Line 3 / This results in:
Line 2
Line 3
being printed to screen (or wherever you redirect it).
This does the same thing that the command 'j_melis' submitted, but does it a lot quicker. That command takes 43 seconds to complete on my system, while the command I submitted takes 6 seconds. Show Sample Output
Enhancement for the 'busy' command originally posted by busybee : less chars, no escape issue, and most important it exclude small files ( opening a 5 lines file isn't that persuasive I think ;) ) This makes an alias for a command named 'busy'. The 'busy' command opens a random file in /usr/include to a random line with vim.
Using urandom to get random data, deleting non-letters with tr and print the first $1 bytes.
Use this command if your file may contain empty lines and you need to optain the first non-empty line.
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.
Show Sample Output
Returns the most recently modified file in the current (or specified) directory. You can also get the oldest file, via: ls -t1 $* | tail-1 ;
A tweak using Patola's code as a base, this full-width green matrix display has all the frills (and all the printable characters). You don't need the surrounding parens if you don't care about losing globbing capabilities. Z-shell (/bin/zsh) needs neither the parens nor the `set -o noglob` Screen shot (animated): http://desmond.imageshack.us/Himg32/scaled.php?server=32&filename=matrixh.gif&res=landing If it's too slow, try lowering the `sleep 0.05` or even replacing it with `true` (which is faster than `sleep 0`). I squashed it as narrow as I could to conserve space, though somebody could probably squeeze a char or two out. Enjoy!
Doesn't depend on curl and doesn't use thumbnails as wallpaper (which has the unfortunate effect of only allowing imgur links)
commandlinefu.com is the place to record those command-line gems that you return to again and again. 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.
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.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
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: