5,938 reputation
622
bio website timkennedy.net
location Virginia
age 43
visits member for 3 years, 5 months
seen Jul 20 at 0:25
Father, Husband, SysAdmin, Brother, Son. In reverse chronological order.

Oct
28
answered Download using wget to a different directory than current directory
Oct
28
comment VIM: Create a function to generate several lines of buffer
i think snipMate adds some nice functionality over what vim alone can do. Thanks for the tip.
Oct
28
answered VIM: Create a function to generate several lines of buffer
Oct
28
comment vi - how to join differents specific lines
ah, I was having problems doing it in a single command. thanks. :)
Oct
28
answered vi - how to join differents specific lines
Oct
27
answered Is there a command which will force Linux to flush cache of one file on an NFS share?
Oct
27
answered ksh cannot cp from location with space in it?
Oct
26
comment How can I find out the estimated power use of my desktop computer?
thanks for the tip on Tweet-a-Watt. that's very interesting.
Oct
25
comment How to keep a line from being remembered in the history?
each ARG to HISTIGNORE is separated by :. Much like $PATH. The &, when supplied to HISTIGNORE, tells bash not to log history if the command you just ran is identical to the one before it. It's a serial-deduplicator for shell history, I suppose.
Oct
25
answered Read first line of a command's output. Command connects me to a remote terminal
Oct
25
comment Syntax error comparing floats with bc
keen observation. expr only does numerical comparison if both arguments are integers. that said, all the greater than comparisons that I've done have worked as expected. I suppose awk could do it too: echo 3.2 3 | awk '{if ($1 > $2) print "1"; else print "0";}'
Oct
25
comment How to keep a line from being remembered in the history?
Thanks for the HISTIGNORE tip. :)
Oct
25
comment How to keep a line from being remembered in the history?
I've been playing with the HISTIGNORE setting below, and that will do what you want. HISTIGNORE="git push production:&" will tell bash to ignore the git push production command, as well as any duplicate commands (which cleans up history, especially if you run the same tail command or ls command repeatedly)
Oct
25
comment How to keep a line from being remembered in the history?
that's much better, thanks for clarifying. i've run into problems a few times, where I just type bash$ !rsync or something, and end up running the wrong rsync account. I can see how being able to keep the git push production command out of your history could be helpful.
Oct
25
answered Syntax error comparing floats with bc
Oct
25
comment Switch VI to use backspace key instead of Control+H for backspace?
posted below, with the entries to map the arrow keys as a bonus. :)
Oct
25
answered Switch VI to use backspace key instead of Control+H for backspace?
Oct
25
comment Switch VI to use backspace key instead of Control+H for backspace?
try setting :map! ^? ^H in your .exrc file. note that ^? is not simply a ^ (shift+6) and a question mark, it's character created by pressing control+v control+shift+backspace, and ^H is created by pressing control+v control+h.
Oct
25
comment For loops in zsh and bash
@intrpc both are zsh specific. zsh was specifically designed to support both bourne, korn, and c-shell syntax, as it's a hybrid of all three.
Oct
25
comment For loops in zsh and bash
for the example that "doesn't work", which is a csh style for loop, you're missing the parentheses. for x ($d); do print $x; done will work, and it will match the first syntax that you have enumerated at the beginning of your question.