CLI Magic: Using command history in the bash shell

Posted by dcparris on Jul 3, 2006 9:38 AM EDT
Linux.com; By Mark Sobell
Mail this story
Print this story

The Bourne Again Shell's history mechanism, a feature adapted from the C Shell, maintains a list of recently issued command lines, also called events, providing a quick way to reexecute any of the events in the list. This mechanism also enables you to execute variations of previous commands and to reuse arguments from them. You can replicate complicated commands and arguments that you used earlier in this login session or in a previous one and enter a series of commands that differ from one another in minor ways. The history list also serves as a record of what you have done. It can prove helpful when you have made a mistake and are not sure what you did, or when you want to keep a record of a procedure that involved a series of commands.

Full Story

  Nav
» Read more about: Story Type: Tutorial; Groups: Linux

« Return to the newswire homepage

Subject Topic Starter Replies Views Last Post
nice stuff tuxchick2 8 1,178 Jul 5, 2006 2:30 AM

You cannot post until you login.