Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

fastest clear command prompt 1

Status
Not open for further replies.

peac3

Technical User
Jan 17, 2009
226
AU
hi guys,

Just wondering I used to know there is a way to clear one long command in unix which I couldn't find it now. So at the moment i'm using ctrl-C instead which is not ideal.

say :
previous command
master $ cp file123231231 dir12312312
expected command
master $ ls /dir/dir/dir/dir/file

I want to clear the previous command above and replace it by expected command, if we use backspace, sometimes taking too long..

any idea guys?
cheers,
 
Have you tried ctrl-U or whatever else your kill character is set to (use stty -a to find out)



HTH,

p5wizard
 
esc dd

or use history

esc k forward
esc j backward

Mike

"Whenever I dwell for any length of time on my own shortcomings, they gradually begin to seem mild, harmless, rather engaging little things, not at all like the staring defects in other people's characters."
 
Thanks p5wizard

ctrl-U that I'm looking for..

cheers mate,
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top