Bennovations Knowledgebase
Search:     Advanced search
Browse by category:
Contact Us

VI editor Backup (VIB) Utility

Views: 1131
Votes: 9
Posted: 24 Jul, 2008
by: Patridge B.
Updated: 05 Aug, 2008
by: Patridge B.
CURRENT RELEASE: v1.9

Download VIB Here

INSTALLATION:

1. Verify the path to bash or ksh is the path on the first line of VIB
i.e. #!/usr/bin/bash

# cp vib /usr/local/bin

# alias vi='/usr/local/bin/vib
*note: It is recommended to add this parameter to your SHELL profile: i.e. .bashrc ,.profile ,

Installation complete!

#./vib

USAGE:

#########################################
VI Editor Backup Utility: (VIB)
#########################################
usage:
     vi <filename>
OR
     vi <path_to_filename>/<filename>
readme:
     vi [-?][/?][-h][-help][--h][--help]
#########################################

REQUIREMENTS:

This script runs in BASH or KSH

VI Editor must be aliased to vib (i.e. alias vi='/usr/local/bin/vib')


FEATURES:

1. Keeps backup of all files to either the current directory in the ".backup" directory (configurable parameter)

OR

Keeps backups in a specified "backup" directory

2. Keeps up to $MAX number of backups per file; (configurable parameter)

3. Keeps a log of all file changes to /var/log/vib-history.log; (configurable parameter)

4. Rotates the /var/log/vib-history.log if filesize > 30Meg; (configurable parameter)

5. Allows you to include the file path in the backup file filename; (configurable parameter)

6. Allows you to either commit changes or roll back changes before saving the file after editing it with VI.

7. Allows you to configure to automatically save all changes; (i.e. no prompts)


Others in this Category
document Setting the date forward on Linux/UNIX
document VI Command to delete till end of file (eof)
document Remove whitespace using sed
document Recursively copy files using find
document Commands to remove blank lines
document Convert Hex to Decimal in UNIX
document Mapping SCSI Return Code Errors on Linux
document RedHat Linux Filesystem is mounted Read Only after EXT3-fs errors.
document Mounting ISO Image on Solaris
document Recursively change or edit all files in a directory using sed
document Trim whitespace around variable in unix shell script
document Purge (flush) the PostFix mail queue after deferred, suspended or timed out issues



RSS