[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference smurf::buildhelp

Title:USG buildhelp questions/answers
Moderator:SMURF::FILTER
Created:Mon Apr 26 1993
Last Modified:Mon Jan 20 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2763
Total number of notes:5802

1510.0. "preserving comments in scripts" by AOSG::FILTER (Automatic Posting Software - mail to flume::puck) Mon Jun 05 1995 18:18

Date Of Receipt: 	 5-JUN-1995 13:16:47.40
From: 	SMURF::ALPHA::frank "Douglas Frank USG  05-Jun-1995 1315"
To: 	buildhelp@DEC:.zko.alpha
CC: 	
Subj: 	preserving comments in scripts

Does anyone know how to keep comments from being stripped from installed
scripts?

thanks

--Doug

T.RTitleUserPersonal
Name
DateLines
1510.1Re: preserving comments in scriptsAOSG::FILTERAutomatic Posting Software - mail to flume::puckMon Jun 05 1995 18:1924
Date Of Receipt: 	 5-JUN-1995 13:27:05.12
From: 	SMURF::WASTED::"vandyck@cardinal.zk3.dec.com" "05-Jun-1995 1325"
To: 	frank@zk3.dec.com
CC: 	buildhelp@zk3.dec.com
Subj: 	Re: preserving comments in scripts

Don't put them between the $Log and $EndLog$ delimiters in the file. This area 
is the one that gets stripped and is intended for RCS file history only. Given 
that information in there might contain comments like "fixed bug that ..." 
it's considered propriatary and should not go to customers and thus gets 
auto-stripped in every creation of the output tree.


		-Grant

| Does anyone know how to keep comments from being stripped from installed
| scripts?
| 
| thanks
| 
| --Doug



1510.2Re: preserving comments in scriptsAOSG::FILTERAutomatic Posting Software - mail to flume::puckMon Jun 05 1995 22:5726
Date Of Receipt: 	 5-JUN-1995 17:56:04.18
From: 	SMURF::FLUME::jmcg "Jim McGinness"
To: 	frank@DEC:.zko.flume
CC: 	buildhelp@DEC:.zko.flume
Subj: 	Re:  preserving comments in scripts

If the script is really a script and not a DATAFILE, the comments are
stripped by action of one of the macros:

  SED_KSH_STRIP
  SED_SH_STRIP
  SED_CSH_STRIP

declared in usr/lib/makefiels/scripts.mk.  To override this macro, you
would modify the Makefile to include a line like

SED_OPTIONS =-e 's/^//' -e t

or, if you only want this treatment for one specific target named
"myscript", a line like

myscript_SEC_OPTIONS =-e 's/^//' -e t

This substitution always succeeds, so the t branch to end-of-script is
always taken.  This branches around the comment-stripping action.