Date: Thu, 15 May 2008 15:12:15 -0700 From: Christopher Cowart <ccowart@rescomp.berkeley.edu> To: Agus <agus.262@gmail.com> Cc: freebsd-questions <freebsd-questions@freebsd.org> Subject: Re: How to delete One line on tcsh history....?? Message-ID: <20080515221215.GI18488@hal.rescomp.berkeley.edu> In-Reply-To: <fda61bb50805151407l6b787100m2ee135b4acf32828@mail.gmail.com> References: <fda61bb50805151407l6b787100m2ee135b4acf32828@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--7SrMUQONj8Rl9QNG Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Agus wrote: > I've been trying to delete one line from my user tcsh history cause i mad= e a > su and it seems didnt hit enter very well so i typed the password on the > console...Now anyone that can look my history will see my pass... >=20 > I tried to edit and delete a few lines but it all comes again....tried > history clear but when i login again it apperas all again..hehe... > Its so secure and cool tcsh taht i have no idea how to do it...been a bash > user... I use this strategy with bash, so YMMV: $ vim .bash_history (kill line) $ kill -9 $$ $$ should expand to the pid of the running shell; if it doesn't in tcsh, sub it out yourself.=20 The kill -9 prevents the shell from doing it's normal exit stuff (like writing out the history) and just kills the process. You'll need to kill -9 any shell that you launched while the "bad" line was in the history file. --=20 Chris Cowart Network Technical Lead Network & Infrastructure Services, RSSP-IT UC Berkeley --7SrMUQONj8Rl9QNG Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.4 (FreeBSD) iQIVAwUBSCy1PyPHEDszU3zYAQJvbw//U36ozSK2OK44rnZR1pK9u/rYY26jjL8f 9EeZ8pEztmgFe1k5hmExqVZxV/soSocvXwnIsnWgNFSeI6Zh2AF9HH9jwxTaeWTS gXw+277HLolaIzvr1rgn1LU4Q5SM1x+C8eX/55S4ycEKaFevWzG0WZ3Hkyry1Lv2 b9sKIAu56oNIR1Pr2VnQaWkpD/TvQLoE5evpkGp2DOQWTJK7PmPeGWaE8uKa/NVD zNIOg3I0f4Qb3L6TmSPtWe5CDNiXLYM6X19DvLeqNjRqQqLwXmUDpPCTGF2KjBvC dMFh8c0nCDRXaAMCHuEtJtLXXPcea+JDYbq0WnT84eFx3baTVOqNfZ6KK2sM5Xhv dh//Kcx2sheE3fqrzH3w8XHDfrPAEcLuDWc85Kx1FljRmOwjAdycivoGCTNVW4t0 xCv2AXnZpInB+xhvmvQZO2x9PgOXdDCjlfBslSVMES91CrxTR8Va+EqTsGJ/yIlu Z70HbHkwtw8EZE+CrTTTGzMiya2STWXSTthY+o8QD4fMVEuGtvPXr1tXINPqGaHO eBMg6x5bA1weal+lNYu6eAj/wVgP/J/jq3mDa/aUJqc3I4HZlYB0IcuZPGo4Hftk UG3E9ibXMAp8CuFY9/14CIl+r9c/E/BZtMtCQFpE+hCoKCuTmO4j4LJwmf7XZTvF 67F34iqw9bM= =Ho9q -----END PGP SIGNATURE----- --7SrMUQONj8Rl9QNG--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080515221215.GI18488>