Olaf Corten's OCUS help page for pro_rename

Help and/or history for pro_rename

See also entry in DESCRIPTION file
Usage: pro_rename [options] [file]
 
	pro_rename goes through a renaming session in a directory using
	a configuration file.

	******* USE WITH EXTREME CAUTION *************
	
	pro_rename ALWAYS uses current directory. 
	In this directory the file pro_rename.cfg should be present. 
	Specify the renaming names in this file as follows: 
 
		fromname.ext	toname  [internal options]
 
	The first filename must have an extension and the name should have 
	6 characters or more. The extension must be .prt, .asm, .drw., .frm,
	.mfg or .lay.
	e.g:
		assembly.asm	newassy
		part1.prt	newpart1
		part2.prt	newpart2
		drawing_part2.drw	newpart2
		etc...

	If a drawing of an assembly or a part exist with the same name
	pro_rename will automatically rename the drawing also.

	First run a pre run check and carefully read the feedback:
		% pro_rename -aldt

	If this check has finished succesfully, give the GO option:
		% pro_rename -aldtg

	The newest fromfile will be copied to the tofile. Internally all
	string  sequences with FROMNAME will be transformed to TONAME (both
	in upercase). 
	You can also add internal options which will override the external
	-a or -l option. Append the words 'pro_noall' or 'pro_nolower' to
	the end of a line.
 
	options:	-h =>	help screen 
			-d =>	delete specified files (move to dumpster)
			-dd =>	remove specified files
			-t =>	create check trail file 
			-a =>	rename internally in all files 
			-l =>	rename also the lower case strings 
			-i =>	also rename in .idx file.
			-f =>	force renaming short names
			-s =>	run strip_pdm_data on every renamed file.
			-g =>	Go for it; Run the session;
				ONLY WITH THIS OPTION THE COPY AND DELETE
				ACTIONS WILL BE PERFORMED. 
				Otherwise pro_rename runs in a pre-
				pro_rename check mode.
			-b =>	Batch mode: pro_rename will NOT wait for
				a confirmation when the -g option is given.
			-n  => 	Do not add spaces if new name is shorter.
 
	If the -a option is specified a transformation to the toname (upper-
	case) will be made in all .prt, .asm, .drw, .frm, .lay and .mfg files. 
	If the -l option is specified the actions will also be done on all
	.drw files for the names in lower case. 
	If the -d option is specified the fromfile's will be deleted if the 
	copy to the tofile was succesfull. 
	If the -t option is specified a trailfile will be created which
	enables you to check the retrieval of all the created models. 
	If the -o option is specified only the given model (and drawing) will
	be renamed, otherwise a search will also be done for a part resp.
	assembly for a given assembly resp. part.

	The -l option only works in conjunction with the -a option.
	The -d and -t options only with -g option. 
 
	file:	If you specify this commandline option pro_rename will use 
		this configuration file instead of pro_rename.cfg.

	BUGS:	If a question marks appears on a line of the configuration
		file this line will be ignored.

Author: Olaf Corten, the Netherlands
E-Mail: olafc@molding.fico.nl or ocorten@knoware.nl

################################################################################
# History:
#
# 19990419 Another fixed serious bug for SUN: newest rev. not always found
#	   ('sort +2 -3n' changed to 'sort -n +2 -3')
# 19990219 Changed SCRIPTS_DIR extraction.
# 19971009 Upgraded to R18. Give warning if new name size is not the same.
# 19970327 Added -dd option.
# 19970312 Added .mfg files. Fixed hang-up for DEC-Alpha with -a option.
#	   Added -b option.
# 19970211 Added -s option. Removed -o option. Fixed various bugs. 
# 19970204 Fixed bug for SUN: newest rev. not always found (sort +2 -n =>
#	   sort +2 -3n)
# 19970130 Added -f option.
# 19961118 Changed /bin/split to /usr/bin/split (fix for non-SGI users)
# 19960723 Changed SCRIPTS_DIR setting.
# 19960704 Added -i option.
# 19960229 Fixed error when renaming in directory with only one file.
# 19960105 Fixed 'undefined from_string' bug when renaming drawings.
# 19951215 Changed split to /bin/split
# 19940712 Removed description option. Cleaned internal options.
#	   Replaced some 'ls -l' with '$LS_COMMAND -l'.
# 19940501 Removed -s option.
# 1st version: 7-7-93	
#
# BE CAREFULL USING THIS SCRIPT!
#
################################################################################