Check These Out
I always add this to my .profile rc so I can do things like: "vim *.c" and the files are opened in tabs.
handles file names with spaces and colons, fixes sort (numeric!), uses mplayer, same output format as other alternatives
This works in some situations where 'reset' and the other alternatives don't.
This command lets you see and scroll through all of the strings that are stored in the RAM at any given time. Press space bar to scroll through to see more pages (or use the arrow keys etc).
Sometimes if you don't save that file that you were working on or want to get back something you closed it can be found floating around in here!
The awk command only shows lines that are longer than 20 characters (to avoid seeing lots of junk that probably isn't "human readable").
If you want to dump the whole thing to a file replace the final '| less' with '> memorydump'. This is great for searching through many times (and with the added bonus that it doesn't overwrite any memory...).
Here's a neat example to show up conversations that were had in pidgin (will probably work after it has been closed)...
$sudo cat /proc/kcore | strings | grep '([0-9]\{2\}:[0-9]\{2\}:[0-9]\{2\})'
(depending on sudo settings it might be best to run
$sudo su
first to get to a # prompt)
Same as above, but modified to show human readable output
I often use it to find recently added ou removed device, or using find in /dev, or anything similar.
Just run the command, plug the device, and wait to see him and only him
For editing files added to the index:
$ vim `git diff --name-only --cached`
To edit all changed files:
$ vim `git diff --name-only HEAD`
To edit changed files matching glob:
$ vim `git diff --name-only -- '*.html'`
If the commands needs to support filenames with whitespace, it gets a bit hacky (see http://superuser.com/questions/336016/invoking-vi-through-find-xargs-breaks-my-terminal-why for the reason):
$ git diff --name-only -z | xargs -0 bash -c '