Smaller Code Better Runtime
This function uses xmllint to evaluate xpaths. Usage: xpath /some/xpath XMLfile Show Sample Output
Produces a CSV file containing fronts/backs of cards with specified tag ("mytag" above). This command pulls these cards from different card databases, and allows them to be merged into one (by importing the resulting CSV file). The CSV file is not directly produced; instead of commas, "||" are inserted. In your editor of choice, modify the resulting file to put quotes around the text before || and after ||, then change || to a comma (for every line).
It will just start playing and will not stop at the point that it has downloaded up to when the video starts
Shows a sigclass 0x20 (Key revocation) signature packet on a key, including all subpackets. Subpacket 2 is the date of revocation, subpacket 26 the relevant policy, subpacket 29 the reason of revocation (cf. http://rfc.askapache.com/rfc4880/rfc4880.html#section-5.2.3.23 ) and subpacket 16 the issuer of the revocation certificate (usually should be the same as the revoked key). Show Sample Output
Need to encrypt something from the command line? I've used this before to encrypt passwords with a master password that was shared amongst a team. To decrypt: ~$ echo -n 'jA0EAwMCPdknsznAww5gySL1/quqhXg6QgQkIz5abzGP5EZgTbXCFU+y6dP8ySWovytc' | base64 --decode | gpg --decrypt gpg: CAST5 encrypted data Enter passphrase: secret gpg: encrypted with 1 passphrase HelloWorld! Show Sample Output
This command is for producing GNU sha256sum-compatible hashes on UNIX systems that don't have sha256sum but do have OpenSSL, such as stock IBM AIX. 1.- Saves a wrapper script for UNIX find that does the following: A.- Feeds a file to openssl on SHA256 hash calculation mode B.- Echoes the output followed by the filename 2.- Makes the file executable 3.- Runs find on a directory, only processing files, and running on each one the wrapper script that calculates SHA256 hashes Pending is figuring out how to verify a sha256sum file on a similar environment. Show Sample Output
This command drops all the sequences of the 'public' schema from the database. First, it constructs a 'drop sequence' instruction for each table found in the schema, then it pipes the result to the psql interactive command. See it scripted here : https://gist.github.com/cuberri/6868774#file-postgresql-drop-create-sh
recursive cowsay Show Sample Output
Useful for big systems with lots of cards. (Update: does not work with USB disks)
seed the random number generator, find all matches in a file put all matches from the capture group into an array return a random element from the array Show Sample Output
Clear Cached Memory on Ubuntu based distributions, and also display memory status. Please do not use this on a production machine unless you really really know what you are doing. Echo 3 is a kinder way of purging the memory, you can also use 'echo 2' or 'echo 1' if #1 You know what you are doing, and #2 refer to number 1 :-)
get a list of temps of your hard-drives. Show Sample Output
Or,
aumix -v -5
Map these to key combinations in your window manager and who needs special buttons?
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: