📄 beta.mex
字号:
may prove prohibitively cumbersome.In this case,just.L vithe fileto review your changes..LPWhen you've finished,and you're satisfied that you prefer the merged versions,you need to move them onto the files in.L index.pages:.LS 4cd \fIyour-home-directory\fP/index.pagesmv pages.merged/*.[1-8]* ..LE.H C "Updating the Index \(em Phase Two".H 2 "Using the \fL.IX\fP Macro".LPThe usage of the.SM \fL.IX\fPmacro is as follows:.LS 4\&.IX "\fI1st-index-term\fP" "\fI2nd-index-term\fP" "\fIformat-of-1st\fP" "\fIformat-of-2nd\fP".LEThe first argument,.I 1st-index-term ,is the unformatted primary index termand specifies where the entry will appear in the index.The second argument,.I 2nd-index-term ,is the unformatted secondary index term andwill appear as a subentry in the index under.I 1st-index-term .The third argument,.I format-of-first ,specifies how.I 1st-index-termshould be formatted in the index.And the fourth argument,.I format-of-second ,specifies how.I 2nd-index-termshould be formatted in the index..I format-of-first .and.I format-of-secondshould be similar enough to.I 1st-index-termand.I 2nd-index-term ,respectively,to ensure that the entries will appear in the rightplaces in the index!.H 2 "Review \fLtrial.index\fP".LPThe next step in the indexing process is tocompare the trial index you have just generatedwith the extant manual index.Print out.L trial.index :.LS 4lpr -n trial.index.LELook over the printed copy and mark any ghastlyerrors that you find. Look specifically forprimary entries with only one secondary entry,entries out of order,formatting errors,misleading or confusing entries and typos.A primary entry that has only one secondary entryin the trial index may well have several in the extantindex.That is,it may not be a problem.Be sure to check for this..LPIt is sometimes difficult to determine the page onwhich problem entries are indexed.You may just have to make a few guesses untilyou find the right pages..L grep "" (is your friend.)Usually,though,the name of the page in which a particular index entry occurs will appearin the entry itself..H 2 "Fix the Bad Index Entries".LPNow that you've identified the bad entries,.L vithe offending files and fix them.Indexing can best be described as a black art,and the best way to learn it is to learn byexample.Look at the sources for the current release of the man pagesand see how indexing is done there,and when in doubt,ask someone about it..H 2 "Index the New Pages".LPOnce you've fixed the bad index entries,you need to generate index entries for thepages that have been added since the last release.Many of these pages will not have been indexed at all,and many others may have been indexed incorrectly.Recall that.L FILES.addcontains a list of added pages in each section:.LS 4cd /usr/src/man/man\fIsection\fPvi `cat FILES.add`.LEIn generating index entries,try making each name listed in the.SM NAMEline a primary entry,checking frequently with the extant index for precedents,rotating the NAME line to generate primary entries,looking at.SM "SEE ALSO"entries to help indentify groups of related pages,borrowing and modifying secondaries form other pages in such groups,and converting new entries to secondaries when they belong logicallyto some existing primary.Remember,it'll take some practice to get good at this..H 2 "Merge in the Indexing Changes".LPOnce you've satisfied yourself that the new pages are adequatelyindexed,you'll need to confirm the changes you've made and check thenew pages in on the release machine.Use.L filemergejust as you did for the formatting fixes.(See the chapter on reviewing page formatting.).LPNow go to the release machine:.LS 4cd /usr/src/man.LECheck out the files in question:.LS 4foreach i (man[1-8])cd$isccs edit `cat FILES.index`cd ..end.LECopy the merged sources from your machine onto the sources on therelease machine:.LS 4foreach i (1 2 3 4 5 6 7 8)cd man$ircp \fIyour-machine\fP:\fIyour-homedir\fP/index.pages/*.$i* .cd ..end.LECheck these copies in:.LS 4foreach i (man[1-8])cd $isccs delget -y"indexing fixes for \fIrelease\fP" `cat FILES.index`cd ..end.LE.H C "Updating Makefiles and Printfiles".LPYou're now nearly ready to clone the sources and print the document,but in order to do that,you'll need to update the Makefiles and Printfiles.The Makefiles will go on the release tape,and the Printfiles will be used to generate the hard copy of the manual..H 2 "\fLmake update\fP".LPGo to the release machine:.LS 4cd /usr/src/manmake update.LEThis will append lists of pages deleted from and added to each sectionto the Makefile and Printfile in each section..H 2 "Edit the Makefiles".LPNow edit the Makefiles:.LS 4cd /usr/src/man/man\fIsection\fPvi Makefile.LECheck the deletion and insertion lists for any obvious errors.Delete all filenames ending with.L .eqnfrom these lists..L .eqnfiles do not ship on the release tape.Position the cursor on the first line of the.L FILESlist definition.You need to break the list out so that there's one filename per line:.LS 4!}.LEAt the prompt,type:.LS 4make show.LENow go through the expanded.L FILESlist and delete those filenames which appearin the delete list.You can do this by hand,since the delete list won't ordinarily be large.Be sure to keep a record of the deleted pages!.LPWhen you've made the deletes and noted them down,delete the delete list and position the cursor on the firstline of the insert list.Remove the comment characters and the extra spaces:.LS 4:.,$s/# //.LENow you need to add the insert list to the.L FILESlist.Again position the cursor on the first line of the insert list.Delete the list:.LS 4dG.LEPosition the cursor on the line.L "FILES= \e" ''. ``.L "FILES= \e" '' (``should be by itself on a line.)Now get the list from the delete buffer and insert it at the topof the.L FILESlist:.LS 4p.LENow position the cursor on the first line following the line.L "FILES= \e" ''. ``Sort and repack the.L FILESlist and append a backslash.L \e ) (to eachline:.LS 4!}.LEAt the prompt,type:.LS 4sort -u | fmt | sed 's/$/ \e\e/'.LEThere will be a backslash at the end of the last line.Delete it..LPRepeat the above in the Makefile for each section..H 2 "Review the Makefiles".LPIn each section,review the changes you've made:.LS 4make show | more.LEDoes the list look right?.H 2 "Edit the Printfiles".LPNow edit the Printfiles,doing just as you did in the Makefiles,with the following exceptions:.LPDo not delete the.L .eqnfiles from the list.You'll need them to print the manual.Instead,delete all.L . \fIsection\fPfilesthat correspond to.L .eqnfiles..LPDelete all thefiles containing.L .sorequests.If you're not sure whether a file contains.L .sorequests,you'll just have to look at it to find out.A little experience will make these identifications easier..LPFinally,when dealing with the Printfiles,use.LS 4make showprint.LEinstead of.L "make show"in all sections but Section 3.In section 3, for each of the subsections (3, 3L, 3M, 3R and 3V):.LS 4!}.LEAt the prompt,type:.LS 4tr ' ' '\e012' | sed '/\e\e/d'.LE.LPNote:.L List. \fIsection\fPdoes not appear in the.L FILESlists in the Printfiles.This is as it should be..H 2 "Review the Printfiles".LPWhen you've edited the Printfiles,review them:.LS 4make showprint | more.LE.H 2 "Compare the Makefiles and Printfiles".LPFor a last sanity check,compare the.L FILESlists in the Makefiles and Printfiles..LS 4cd /usr/src/man/man\fIsection\fP.LECreate a file called.L Print.listcontaining.L showprintoutput:.LS 4make showprint > Print.list.LECompare the contents of.L Print.listwith the output of.L "make show" :.LS 4make show | comm -3 Print.list - | more.LEAll you should see is.L .sofiles in the right column(pages in the.L Makefilelist,but not in the.L Printfilelist).and.L .eqnfiles in the left column(pages in the.L Printfilelistbut not in the.L Makefilelist).Investigate any other files that appear,since they're either extraneousor are missing from one of the lists..LPRepeat this check for all sections..H 2 "Check in the Makefiles and Printfiles".LPOnce you've satisfied yourself that the Makefiles and Printfiles arecorrect,check them in on the release machine:.LS 4foreach i (man[1-8])cd $isccs delget -y"updated FILES list for \fIrelease\fP" Makefile Printfilecd ..end.LE.H C "Cloning the Sources".LPNow you're ready to clone the sources.Check to see if there are any files still checked out:.LS 4cd /usr/src/manls man?/SCCS/p*.LEIf you find any such file,you'll have to force the owner off the file.This is serious matter!.LPGo to the.L man\fIsection\fPdirectory that contains the errant file,and save the file to the archive:.LS 4cd man\fIsection\fPmv \fIerrant-file\fP ../arch/\fIerrant-file\fP.\fIowner\fP.LENow you need to remove the.L p.file from the.SM SCCSdirectory:.LS 4rm SCCS/p.\fIerrant-file\fP.LEWhen you do this,mail the release engineer and the owner of the filethat you have done so!.H 2 "\fLmake clean\fP".LPOnce you're very sure that all the files are under.SM SCCSand are all checked in,Remove all the extant versions of the files beforeyou extract just the printable versions from.SM SCCS .This is just to make verification easier..LS 4cd /usr/src/manmake clean.LENow examine all the sections..LS 4cd man\fIsection\fP.LEInvestigate any files you find still lying around,as you may need to.L "sccs create"them..LPThere should be nothing left in the.L man \fIsection\fPdirectories but the.SM SCCSsubdirectories..LPNote:When you find a file that's been sneaked in after the freeze date,make sure that it's under.SM SCCSbefore you do a.L "make clean" !.H 2 "Retrieve Only the Printable Sources".LPNow retrieve only the printable sources from.SM SCCS :.LS 4cd /usr/src/manmake -f Printfile all.LE.H 2 "Make a Local Copy on the Release Machine".LPThe actual cloning of the sources will happen in two steps.First,make a local copy of the sources on the release machine..LS 4cd /usr/src/man.LEFind out how much storage the sources require:.LS 4du.LEThis command will display filesystem usage in k-bytes for thecurrent directory and its subdirectories..LPFind a filesystem partition with enough free space to hold the sourcescomfortably:.LS 4df.LEThis command will display (among other things) available storage on eachmounted filesystem and the directories on which those filesystemsare mounted..LPFind a directory with enough room in it,and create a subdirectory there called.L man :.LS 4cd \fIdirectorywithenoughroominit\fPmkdir man.LEYou now need to edit.L Printfileand redefine the.L CLONEDIRmacro:.LS 4cd /usr/src/manvi Printfile.LERedefine.L CLONEDIRto be.LS 4\fIdirectorywithenoughroominit\fP/man.LENext, execute the.L clonetarget in.L Printfile .Preview the actions of this target:.LS 4make -nf Printfile clone.LEThis displays what the.L clonetarget will do.Look it over carefully.If it's correct,execute.L clone :.LS 4make -f Printfile clone.LEVerify this copy by looking through.L CLONEDIR ..LPOnce you're satisfied that the copy was successful,restore the online sources .L .so "" (files) so that people who mount theman pages from the release machine won't get nasty messages whenthey invoke.L man :.LS 4cd /usr/src/manmake all.LEBefore doing the second step,make some general sanity checks:.LS 4cd CLONEDIR.LEAre all the Printfiles there?:.LS 4ls man?/Printfile.LE.H 2 "Make a Remote Copy to Your Doctools Host".LPNow you're ready to copy the sources from.L CLONEDIRto your doctools host.Edit the Printfile on the release machine and redefine the.L DESTHOSTand.L DESTDIRmacros:
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -