Home IT Linux Windows Database Network Programming Server Mobile  
  Home \ Linux \ Bash added to the Vi mode indicator     - Each catalog Detailed Linux (Linux)

- SSH without password (Linux)

- CentOS 6.6 compile and install phpMyAdmin configuration PostgreSQL9.4.1 (Database)

- Oracle 11g maintenance partitions (Seven) - Modifying Real Attributes of Partitions (Database)

- Several Methods of SSH Auto - login (Linux)

- C ++ hash function (Programming)

- Android project using the command to create and install the package (Programming)

- Build your own Python coding environment (Linux)

- By way of a binary installation innobackupex (Database)

- To obtain installation package (RPM) under RHEL6 (Linux)

- Docker command Detailed (Linux)

- Java synchronization mechanism: synchronized, wait, notify (Programming)

- Linux more command Detailed (Linux)

- DB2 commonly used scripting sort out (Database)

- Oracle table Access Control (Database)

- wget command usage Explanation (Linux)

- Java semaphores (Programming)

- Node.js form --formidable (Programming)

- Arrow keys, backspace key garbled in Python-2.7.5 Interactive Mode under CentOS 5.8 (Linux)

- Distributed File System FastDFS deployment (Server)

  Bash added to the Vi mode indicator
  Add Date : 2018-11-21      
  With a long zsh the Vi command line editing mode, sometimes trance Where own patterns. As we all know, Vim status line can be displayed indicating mode, in order to illustrate the normal mode or insert mode. If this feature we can Vim zsh transplanted into the body, it would be perfect.

With a man zshzle looked at the documents, I found not difficult to implement, simply add the following to the .zshrc in:

function zle-line-init zle-keymap-select {
     VIMODE = "$ {$ {KEYMAP / vicmd / - NORMAL -} / (main | viins) / - INSERT -}"
     zle reset-prompt
zle -N zle-line-init
zle -N zle-keymap-select

RPROMPT = '% {$ fg [green]%} $ {VIMODE}% {$ reset_color%}'

Explain a little, we set the first variable VIMODE save the default state (insert), then use two widgets zle provided to replace the variable content and redraws the prompt. Then perform zle widgets, and set RPROMPT enable indicator appears on the right.
- A drop datafile Oracle bug (Database)
- Iptables on the request URL for IP access control (Linux)
- How to build a container cluster (Server)
- Debian (Wheezy) were installed wxPython GUI development (Linux)
- CentOS and RHEL to install IPython 0.11 (Linux)
- Ubuntu is expected to allow you to install the latest Nvidia Linux drivers easier (Linux)
- Disk Management LVM (Linux)
- Fedora10 use Git version Configuration Management (Linux)
- Use GLOBK batch command network adjustment (Linux)
- Using IE can also be easily remotely control the computer (Linux)
- Ubuntu 14.04 Enable root and disable the guest (Linux)
- OpenGL ES 3.0 vertex buffer (Programming)
- Python programming style (Programming)
- Dockerfile use to build a mirror-based CentOS 7 (Linux)
- Vi (Vim) keyboard map and its basic commands (Linux)
- Linux PXE unattended installation PXE-E32: TFTP OPen timeout the solution (Linux)
- C # Future: Tracking null reference (Programming)
- Oracle create a temporary table space group (Database)
- Differential test piece using MongoDB performance YCSB (Database)
- Analysis of memory mapping process in Linux x86-64 mode (Linux)
  CopyRight 2002-2016 newfreesoft.com, All Rights Reserved.