Chapter 7. Text Editors (vim, jed)

You will most likely come across situations where you need access to a text editor. You will find both vim (for the vi users), and jed (for the emacs users) available.

Figure 7.1. Using vim to Edit .bashrc

[root@probe root]# vim ~/.bashrc
# $Id: first_steps.xml,v 1.20 2004/11/15 04:56:32 rwhalb Exp $
                                                                                
# NST User: root bash shell settings....
# --- ----- ---- ---- ----- ------------
                                                                                
# source global definitions...
# ------ ------ --------------
if [ -f /etc/bashrc ]; then
  . /etc/bashrc
fi
                                                                                
# set options...
# --- ----------
set -o ignoreeof
set -o emacs
                                                                                
# set up LANG env variable...
# --- -- ---- --- -----------
export LANG=en_US
export LANGUAGE=en_US
export LC_ALL=en_US
                                                                                
                                                                                
:q!
[root@probe root]# 

Figure 7.2. Using jed to Edit httpd.conf

[root@probe root]# jed /etc/httpd/conf/httpd.conf
F10 key ==> File   Edit   Search   Buffers   Windows   System   Help
# $Id: first_steps.xml,v 1.20 2004/11/15 04:56:32 rwhalb Exp $
#
# Apache configuration file tweaked for a NST boot system.
#
# Mimics much of the original RedHat 9.0 initial config.
                                                                                
#
# Don't give away too much information about all the subcomponents
# we are running.  Comment out this line if you don't mind remote sites
# finding out what major optional modules you are running
ServerTokens OS
                                                                                
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# Do NOT add a slash at the end of the directory path.
                                                                                
ServerRoot "/etc/httpd"
                                                                                
                                                                                
#
-------+(Jed 0.99.15) Emacs: httpd.conf    (SH)  1/1037   6:10pm----------------loading /usr/share/jed/lib/modeinfo.slc
[root@probe root]#