how to run 251th command from history in linux

In history command, there are 1432 commands. But I need to 251th command from that. Since i am using minimal i cant copy paste and also its hard to press up key for long time.

 

Is there any shortcut for that?

Tags: History command Linux
user image Author :   sebastian
0

There is a Special Symbol (!) for this. In case you need to run 251th command, do as follows.

# !251

It will run the command in that number.

user image
jagannatharumugam May 19, 2017
Add comment