News for hackers. Stuff that matters.
Re:Interesting Bash Prompts by whimsy on Sunday September 06, 2009 @01:24AM (#807499)
If you're particularly worried about this sort of thing, you can wrap your prompt in : and ; i.e. : user@host $ ;

Source is http://www.faqs.org/docs/Linux-HOWTO/Bash-Prompt-HOWTO.html#...

Re:Interesting Bash Prompts by there on Sunday September 06, 2009 @05:01PM (#808157)
or use something like 'set noclobber' (at least in tcsh)

    jcs@smug:~% echo asdf > file
    jcs@smug:~% echo fdsa > file
    file: File exists.
    jcs@smug:~% echo fdsa >! file
    jcs@smug:~% 
this has saved me quite a few times when accidently typing > instead of >> or similar.