Linu-實驗六-vi文本編輯器_第1頁
Linu-實驗六-vi文本編輯器_第2頁
Linu-實驗六-vi文本編輯器_第3頁
已閱讀5頁,還剩6頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

1、實驗六vi文本編輯器上機實驗內(nèi)容:1.rooWlocaltiost、#cd/rootroot(aiocalhost-#mkdirvitestraotlocalhostIsanaconda'ks.cfginstall.log請在/root這個目錄下建立一個名為vitest的目錄;in3taU,log.5yslag公共的視獨文檔音親vitest摸械圖片下載桌面進入vitest這個目錄當中;rooteiocaUiostcdF./rbat/vitestrootglocalhostvitest#|將/etc/man.config拷貝到本目錄底下;roottaiocalhost-#cd-Vroof

2、/uitestrooWlocalhostvitest#cp/etc/man.config/root/vitestrootlocalhostvitest#Isman.config# 使用vi開啟本目錄下的man.config這個檔案;R"Generatedutomaticallyfromman.conf.inbytheconfigurescript.# #man.corffromman-1.6f#Formoreinformationaboutthisfile,seethemanpagesmandlandman.conf(5),#Thisfileisreadbymantoconfigur

3、ethedefaultmanpath(alsousedwhenMANPATHcontainsanemptysubstring),tofindoutvfherethecatpagescorrespondingtogivennoanpagesshouldbestored,andto叫eathPATHelementtoamanpathelement.# Itmayalsorecordthepathnameofthemanbinary.Thisisunused.Theformatis:# #WANBINpathnameMANPATHrnanpathelementcorrespondingcatdirM

4、ANPATHHAPpath_elenieiitmanpathelenient一-Ifnocatdirisgiven,itisassumedtobeequaltothemandir(sathatthisdirhasbothmanletc.andcatletc.subdirs).# ThisisthetraditionalUnixsetup.2. 在vi中設(shè)定一下行號;n#MANBIN#MANPATH#MANPATHMAP26#212223# Ifnocatdirisgiven,itisassumed(sothatthisdirhasbothmanletc.ThisisthemditiunalUn

5、ixsetup.tobeequaltotheniandirandcatletc,subdirs).;486:找不到模式:1.1頂端TRQFF/usr/bin/groff-Tps-mardocNROFF/usr/bin/nroff-c-mardoc2>/dev/null37EQN/usr/bin/geqn-Tp5NEON/usr/bin/geqn-TutfBTBL/usr/bin/gtbld#COL/usr/bin/coV1G1REFER/U5r/bin/greferI:setnumber3. 移動到第62行,向右移動40個字元?:62G;4G|#Thebelowmappingsaresu

6、perfluouswhentherighthandsideis4inthemandatorymanpathalready,keepmanfromstatting.63#lotsofothernearbyfilesanddirectories.7.移動到第一行,并且向下搜尋一下teTeX這個字串?2 #Generatedaiitcmaticallyfromman.conf.inbythe#configurescript.3 #man.conffromuan-l,6f#Formareinfornationaboutthisfile,seethemanpagesman(l)#andman.conf(

7、5).11 9希le#Thisfileisreadbymantoconfigurethedefaultmanpathalsoused#whenMANPATHcontainsanemptysubstring),tofindoutwherethecat#pagescorrespondingtogivenmanpagesshouldbestored,#andtomapeacnPATHelementtoamanpathelement.12 #Itmayalsorecordthepathnameofthemanbinary.Thisisunused.#Theformatis:#pathnamemanpa

8、theleirentcorrespondingcatdirlpath_elementmanpathelement8.接著下來,我要將50到100行之間的man改為MAN,并且一個一個挑選是否需要修改?40#41jj,4344454647484959515253545556575859606162_唇換為MAN(y/n/a/q/l/ErY)?|EveryMANPATHMANPATHMANPATHMANPATHHANPATH#automaticallygeneratedMANPATHincludesthesefields/usr/a|/usr/share/pn/usr/local/pn/usr/t

9、ocal/share/riar/usr/XllR6/ianUncomnient#MANPATHMANPATHMANPATHMANPATH#ifSetupPATHyouwanttoincludeoneofthesebydefault/opt/*/_/usr/lib/*/usr/share/-/usr/kerberos/rnantoMAhPATHmappingIfpeopleaskfar"|nanfoo"andhave"/dir/bin/foo"intheirPATHin*/dir7i施r|thennomappingisrequired!.#Thebelow

10、mappingsareinthelatoryran|path_alreadyfbutwillkeepmanfromstatting一51,18*24andthedocsarefoundsuperfluouswhentherighthandsideis9.修改完之后,突然反悔了,要全部復(fù)原?44454b474Q495051525354555657505960MANPATHMANPATHMANP4IHMANPATHUncommentMANPATHMAXPATHMAKPATHMANPATH#/dsr/share/usr/local/usr/locaWshare/uir/XURfluEU11youwa

11、nttoincludeoneofthesebydefault/opt/-/HAN/usr/lib/MAhl/usr/share/*/MAN/usr/kerberos/MANSetupPATHtoMANPATHmaopingIfpeopleaskforMMANancthedocsarefoundfoohrandhaveh7dir/bin/fooHintheirPATHin'Vdir/MAN,',thennomappingi5required.61#Thebelqwmappingsaresuperfluouswhentherighthandsideis'<2#inth

12、eMANdatoryMANpathalready,butwillkeepMANfromstatting63#lotsofothernearbyfilesanddirectories.-64#65 MANPATH咐P/bin/usr/share/MAhMANPFTH咐P/usr/share/TO替換為rVM(y/n/a/q/l/"E/AY)?I&6,32-5233招44 KANPATH/usr/share/iTian45 -1ANPATH/u$r/local/Han4CArjp.-.TH/usr/local/&iiare/|idri47 HANPATH/USF/XUR6

13、/H#4950515253545556575B59616263646566#UncommentMANPATH日MANPATH/MANPATH#MANPATHifyouwanttoincludeoneofthesebydefault/opt/*/HAN/usr/Ut/*/j/usr/share/7|»n/usr/kerberos/nan#SetupPATHtoMANPATHmapping等Ifpeopleaskfor"ndnfandhave"/dir/bin/fintheirPATH#andthedocsarefoundin'/dir/ianthennoma

14、ppingisrequired.# ThebelowmappingsaresuperfluoushentherighWiandsideis# inthenandatory# Lotsofother#HANPATHMAPHANPATHMAPpathalread/,butwillkeepmanfromstattingnearbytilesanddirectories./bin/sbin/usr/share/usr/share/1行沒生改變;before#2GQ:47:2252,L3310.我要復(fù)制51到60行這十行的內(nèi)容,并且貼到最后一行之后;149.1/bin/zcat141 .F142 .Y1

15、43 #144 #Enable/disablemakewhatisdatabasecronupdates.145 #IfMAKEWHATISDBUPDATESvariableisuncommented146 #andsettonorM*cronscripts147 #/etc/cron-daily/nakewhatis*cron148 #/etc/cron.weekly/makewhatis.cron149 #willnotupdatenakewhatisdatabase.15Q#Otherwisethedatabasewillbeupdated.151#15215315AL551561571

16、58159#MAKEWHATISP6UPDATESn# MANPATB/opt/*/j2# MANPATH/usr/lib/*/|an# MANPATH/usr/share/*7|ian# MANPATH/usr/kerberos/#SetupPATHItoHANPATHmapping15S#Ifpeopleaskfor"Bantoo"andhave"/dir/bin/foa'intheirpath161 #andthedocsarefoundinVdir/n"Fthennonappingisrequired.162 S多了16行162a底端.c

17、onf.inbythe45678.conffrom# Formoreinformationaboutthisfile,seeandman.conf(5),thepagesrari(i|#E#ThisfileisreadbymantoconfiguretheExplicitlygivencatdirsoverride.defaultpath(alsoused# #Generatedautomaticallyfromconfigurescript.13 #FSSTND14 FHS15 #Thisfileisalsoreadbyiraninordertofindhowtocallnroff,less

18、,etcr16 #andtodeterminethecorrespondencebetweenextensionsanddecompressors.17 #18 #MANBIN/usr/local/bin/|iian2Q#21 #EveryautomaticallygereratedMANPATHincludesthesefields22 #12. 少2。仃】L1項端將這個檔案另存成一個man.test.config的檔名;1 #2 #Generatedautonaticallyfromian.conf.inbythe3 #configurescript.4 #5 #man.conffromn

19、an|-l,6f#Fornoreintonationaboutthisfile,seethemanpagesmarf18 #andiifan|.conf(5:.9 #I #Thisfileisreadbymantoconfigurethedefaultitanaath(alsouedII #Explicitlygivencatdirsoverride.12 #13 #FSSTND14 FHS15 #Thisfileisalsoreadbyrnaninordertofiidhowtocallnroff,less,etc.,16 #andtodeterminethecorrespondencebe

20、tweenextensionsanddecompressors.17 #18 #MANBIN/usr/local/bin;|Bi|29#21 #EveryautomaticallygeneratedMANPATHincludesthesefields22 #13. wman.tst.config去到第29行,并且刪除15個字符;(29G之后,15x即可刪除15個字符)1#2#3#4#5#6#7#8#9#ie#ii#12#13#14Fl15#16#c171819#20#21#22#Generatedautomaticallyfromman.conf.inbytheconfigurescript.

21、manconffromL5nFormoreinformationaboutthisfile,seeand.conf(5).ThisfileisreadbyExplicitlygivencatdirsoverride.toconfiguretheFSSTNDThisfileisalsoreadbyiifTTinordertothepages(1)defaultnidnpath(alsousedfindhow1ocallnrofftless,etandtodetermineThecorrespondencebetweenextensionsanddecompressors.MANBIN/usr/local/bin/|ianEveryautomaticallygeneratedMANPATHincludesthesefields29,15艱14.儲存后離開吧!:wq|1.把操作目錄轉(zhuǎn)到/tmprootglocalhostcd/tmpn)otlocalhosttmp#|使用vim同時新建并編輯兩個文件t1,t2在兩個文件中分別輸入內(nèi)容并保存文本toocaIhost:-文件舊Hf(y)型索(3恣端利助舊)|567S9123456tlpt2"LL,7C4.把t1的第一行復(fù)制粘貼到t2

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論