NAME
CfgTie::filever -- a simple module for substituting newer versions into a file system.
SYNOPSIS
This module allows a newer version of file to be safely placed into the file system.
DESCRIPTION
This is a set of utilities for manipulating files.
File's_Rotate
($Old, $New)
This is the file space equivalent to the variable exchange or swap. The old file will be renamed (with a .old extension) and the new file will be renamed to old. This is extremely useful for many semi-critical functions, where modifying the file directly will cause unpredictable results. Instead, the preferred method is to modify old sending the results to new in the background and then doing a very quick switcheroo.
It preserves the permissions and ownership of the original file.
If this routine fails, it will make an attempt to restore things to their original state and return.
Return Value: 0 on success, -1 on error;
Roll(
path,depth,sep)
This convert the specified files into a backup file (the original file is renamed, so you had better have something to put there).
- Depth
-
(optional) Controlls the number of backup copies
- Sep
-
(optional) Controlls the seperator between the main name and the backup number
The defaults for depth and sep are controlled by following two variables in the package:
RollDepth
-
Controlls the number of of older versions that are kept around as backup copies. [Default: 4]
RollSep
-
Controls the separator between the file name and the backup number. [Default:
~
]
RCS_path (
RCSObj,path)
For the given RCS object, this sets the working directory and the file.
find_by_user
This function attempts to locate all of the files in the system that are owned by the specified users. It takes the following parameters:
Base
-
Base
can be a string to the base path or a reference to a list of base paths to search.
Return Value:
Author
Randall Maas (randym@acm.org, http://www.hamline.edu/~rcmaas/)