Enable AIX to ksh the previous command

Source: Internet
Author: User

http://blog.csdn.net/wangjialiang/article/details/7106393

Http://www.blogjava.net/03081626/archive/2008/12/14/224460.html

Http://blog.sina.com.cn/s/blog_5623cddb0100cyl8.html

1, in Ksh, run Set-o VI, this time the entire command state is the VI editor, the operation of the method and VI editor A touch, to repeat the last command, in the current status bar press ESC, and then enter K, you can see the next command, press K can query the previous command, H can move forward one character in the current line, and L can move backward one character in the current line, which is equivalent to the state of VI, and all commands for single-line operations in the VI state can be used. Just press ENTER when you're done editing.
2, if not under the Ksh, then you can run under the command Window Ksh-o VI, the other commands and the first method of the same
3, set the EDITOR=VI in KSH environment variable, the method of modification is to add Editor=vi;export editor directly in the. Profile.
4, delete the history command, can be in the current user's home directory, query to a. sh_history file, which contains all of your current user input commands. You can edit the file and then delete the command. Of course, you can put your favorite commands or longer commands in the inside, and then you can directly call on it. Of course, from this document can see the above points of the use of VI command to obtain the last command, in fact, Ksh is to obtain the information in this file.
5, the following tips:
A. Repeat the previous command to enter R directly in the Ksh state
b, you can execute R a=b in Ksh state, meaning that the a character in the previous command is replaced with the B character and then run.

Enable AIX to ksh the previous command

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.