Ȼ/09

Top / Ȼ / 09

Revision Control Software: С, RCS

Computer 򤷤Ф餯ȤäƤȵŤ ϰĤΥե٤⽤뤳Ȥ롥

Υե뤬礭äƤʣäꤹ硤 ϾˡֲפǤȤϸ¤餺ֲפǤ뤫⤷ʤ ȤΤΤΥߥˤꡤտޤʤܤƤޤȤ⤢롥 ޤˤäʾʤȤʤȤ¸ߤ
Ȥξ֤ΥեƥХååפ¸ƤС ϲǤ롥 Ĥޤꡤ֥եΥС㤤ǤפȤŬڤ˹ԤɤΤ

եΥСѹˤޤĤġ ֥СեȡפȸƤ֡

ֵܹǤϡСեȤȤơRCSפؤ֤Ȥˤ롥 RCS ϸĿͥ桼ȤΤŬƤꡤŪȤ䤹ġ unix ˾ͳΤǤꡤǽ˳ؤ֤ˤϺŬǤ. ޤñʬñȤΥեˤϸҤΤΤŬƤȤ롥
ޤʲСեȤȤ¾ CVSפSubversionפ롥 ϵǽٲͥ줿ġǤ뤬ʬȤϤˤϤߵ郎⤯ޤ Ŀͥ桼ˤϤ over spec ʴ롥 ǡRCS εǽ򴶤褦ˤʤä餳ѤƤФ褤

ʤֵܹǤ RCS ͤñȤǻȤȤ˲⤹롥 ʣοʹ֤ƱեԽݤˤϤޤۤʤäդɬפǤ뤬 Ūˤ CVS Subversion ŬƤΤǡȤΤɤ



Reference: RCS ͻ

RCS 1982 ǯˤϴ˻Ѥ򸫤ƤСեȤǤꡤ Ť褯ΤƤ롥 ǰϥץǡȤޥɤ⤽ʣǤϤʤ ͤȤʤФ⿼ޤ





Introduction for RCS: RCS γǰ

RCS 򤹤ˤϡäѤ˸ä С Сե롤å󡤥åȡå Ȥǰʬɤ ˤĤ褦

С(Version), ӥ(Revision)
ܸǸȡ֥С = ǡס֥ӥ = ǡפȤȤˤʤ롥 ե򹹿ֿǤˤʤä=С󤬾夬äפȹͤС ʬ

Сե
оݤΥեƤΥСξ󤬵ͤޤäե롥
оݤΥե̾㤨 dummy.tex ǤȤȡ dummy.tex,v Ȥ̾ˤʤΤ̤Ǥ롥 ĤޤꡤΥե̾ ",v" Ĥե뤬СեǤȻפɤ
warning.png OS ǰ㤦Ȥ⤢*2.

ʤСեϡƥå󤹤Ȥ˼ưŪ˺롥

ΤȤ̾ϡե뤬¸ǥ쥯ȥ( dirA Ȥ)β RCS Ȥ̾Υǥ쥯ȥ꤬Ф(dirA/RCS)ˡ̵ФΥǥ쥯ȥ(dirA), Сե뤬*3

å
ϥСեˡָפ򤫤뤳ȡǤ롥 ̣ȤƤϡ֤޻䤬ԽʤΤǡ¾οͤϤޤפȤȤˤʤ롥
ºݡեåȡåܿͤСΥեϿǤʤ
warning.png ξǤ⡤¾ͤϤΥեɤ߽ФȤϤǤ롥

εˤäơRCS ʣοʹ֤ˤñեΥСԤäƤ롥 ֥å󥰤ˤեͤɻߡפȤ֡

å
եСեˡ֤Υե뤬ǿСǤפϿȤ
warning.png : åƤե뤷ϿǤʤΤդ뤳ȡ
åƤʤեϥåǤʤ rcs␣-l␣ե̾ Ȥȥե뤬å졤åǤ褦ˤʤ롥 ܤϸҤ rcs ޥɤ򻲾Ȥ뤳ȡ

Ͽˤϡ֤Υե뤬ɤʥեʤΤפҤͤƤΤǡǫ˵Ҥ褦
warning.png Ѹ(^-^)
warning.png Emacs Version Control ǽѤܸǵҤ뤳ȤǤ뤫Τʤ

Ͽ뤿Ӥˡ֤ΥեΤɤɤΤ褦ѹΤפҤͤƤΤǡ 塹Τǫ˵ҤƤ٤(Ѹ).

å
Сե뤫եФȤ
warning.png : åƼФԽǽˡ åʤǼФԽԲĤˤʤ뤳Ȥդ补

ͤǻȤϡ˥å֤ǺȤ뤫 å̵ˤ뤫Ф褤 å̵ˤˡҤ rcs ޥɤ򻲾Ȥ뤳ȡ



Flow of operations: RCS ǤΥեԽή


RCS ĿͰͤѤϡ̾Ͼοޤˤ褦 ֥åĤפǥå󡤥åȤƤФޤϤʤ(äȼƻ)

ή⤦ܤ񤯤ȡRCS Ǥ

  1. ե֥Сեפ å
    warning.png Сեϡƥå󤹤Ȥ˼ưŪ˺롥

  2. Сե뤫顤Ȥե åĤǥå ƼФ

  3. եԽ롥

  4. 1. 롥

Ȥ֤ѤΤ̤Ǥ롥
̤ʤȤ򤷤̤ΤȤ򤹤Ф褤

OK.png ¤ϡǼ ci␣-l␣-zLT ȤޥɤФƤФʤȤʤ롥



notes.png ½: ʲμ˽rcs Ƥߤʤ򤻤.

  1. RCS ѤŬʥǥ쥯ȥ˰ư롥

  2. Υǥ쥯ȥβˡСե֤̤ʥǥ쥯ȥ RCS äƤ
    Ūˤ

    mkdir␣RCS

    Ȥ.

  3. ƤΥץե򡤥ե̾ dummy.txt Ǻ롥
     Sample File
     My name is hogehoge.
     ʤǤ⤤񤱡
     $Id$
     $Date$

    warning.png Ǹ2Ԥɬ뤳ȡ

  4. ƤΥåԤ
    Ūˤ åդǥå & åȤƤߤ롤ȤȤˤʤ롥
    ºݤˤϡ

    ci␣-l␣dummy.txt

    Ȥ
    OK.png ci␣-l ϡ֥å󤷤塤ưŪ˥åդǥåȡ ȤʥޥɤǤ롥

    ȡǽϼΤ褦˥åФ롥
     dummy.txt,v  <--  dummy.txt
     enter description, terminated with single '.' or end of file:
     NOTE: This is NOT the log message!
     >>
    Ǥ ֤ΥեƤ򵭽ҤפȸƤΤǡ 塹Τˤ(Ѹ)ȵ뤳ȡ ʤä顤 " . "(ԥꥪ)ΤߤιԤСֵפȤʤ롥

    ȡ
     initial revision: 1.1
     done
    ȤɽФơС 1.1 ȤСǤΥե뤬Ͽ줿Ȥʬ롥

  5. ǥ쥯ȥ RCS ˥Сե뤬ǤƤ뤫ǧ롥

    ls␣RCS

    ȤФ褤

  6. ci␣-l μưåȤޤäĤޤꡤ åȤ줿ե dummy.txt ¸ߤ뤫ǧ롥

    ls␣dummy.txt

    ȤФ褤

  7. åȤ줿ե뤬ɤѤäƤߤ롥

    less␣dummy.txt

    ȤФ褤 ɤɤѤä褯Ƥߤ补
    ޤ֤ɤҤƤ뤫ʬӻפʤɤ٤Ƥߤ补

  8. ץեȤԽѤƤߤ롥
    warning.png $Id$, $Date$ ʬϤʤȡ

  9. Ƥӥå & åȤԤäƤߤ롥
    ƺ٤ϡ-zLTȤ̤ʥץĤ

    ci␣-l␣-zLT␣dummy.txt

    ȤƤߤ褦
    warning.png -zLT ϡ֥֤Ѥƻɽ򵭽ҤפȤץǤ롥 Ǥϡܻ֡פǻ֤ɽȤȤˤʤ롥

    ȡ
     RCS/dummy.txt,v  <--  dummy.txt
     new revision: 1.2; previous revision: 1.1
     enter log message, terminated with single '.' or end of file:
     >>
    ȤɽФ롥 Ǥ ֤ΥեɤѹҤפȸƤΤǡ 塹Τˤ⤳(Ѹ)ȵ롥 ʤä顤 " . "(ԥꥪ)ΤߤιԤСֵפȤʤΤƱͤǤ롥 ٤Ͻλñʤ
     done
    ɽǤ롥

  10. åȤ줿ե뤬ɤѤäƤӸƤߤ롥

    less␣dummy.txt

    ȤФ褤 ɤɤѤä褯Ƥߤ补
    Ȥ˻֤εҤɤѤäʬӻפʤɤ٤Ƥߤ补

  11. dummy.txt õƤߤ!

    rm␣dummy.txt

    ȤƤߤɤ

  12. dummy.txt !
    Сե뼫ȤϾäƤʤΤǡ åȤСե뤬褹뤳Ȥˤʤ롥
    Ūˤϡ

    co␣-l␣-zLT␣dummy.txt

    ȤФ褤
    warning.png åȥޥ co ä˻ꤷʤкǿСΥեФ

  13. ŤСȤΰ㤤Ĵ٤Ƥߤ롥
    Ūˤϡ

    rcsdiff␣-zLT␣-r1.1␣dummy.txt

    ȤФ褤 ϡǿСȥС 1.1 dummy.txt ٤衤 Ȥޥɤˤʤ롥

  14. ޤ dummy.txt ˲äԽ򸫤롥
    Ūˤϡ

    rlog␣-zLT␣dummy.txt

    ȤФ褤 ȡޤǤΥåκݤ˵ҤѹƤʤɤꥹȥåפ롥

  15. dummy.txt Ǥ륭(Id, Date)ФƤߤ롥
    Ūˤϡ

    ident␣dummy.txt

    ȤФ褤 ȡ$Id$ $Date$ Ƚ񤭹ʬϤ롥

    warning.png εǽϥХʥեФƤͭǤΤǡ ܳŪʥץߥ󥰤ˤŬѤǤ롥
    㤨СХʥǤ륳ޥ rcs ȤˤϤɤΤ褦ʥɤޤƤΤ Ĵ٤Ƥߤ补



Embedding of keywords: RCS: ɤ

ˤФƤ褦ˡ $Id$ $Date$ ʤɤȥեΤʤ˷ޤäɤǤȤǡ RCS ͡ʾưŪ˵Ҥ뤳ȤǤ롥 ʲˡɤΤ褦ʥɤΤ򼨤Ƥ

̣
$Id$ե̾Сԡ֡å
ȤΤϤǽʬ
$Header$$Id$ ȤۤƱˤʤ뤬ե֥̾եѥפǵҤ롥
̵̤ĹʤʤΤǰ̤ˤޤȤʤȤ̤⤢뤫Τʤ
$Date$ΥС󤬥å󤵤줿
$Revision$С
$Author$ΥСå󤷤桼̾
$Locker$ߤΥեåƤ桼̾
$RCSfile$ե̾
$Source$ե̾եѥ
$State$ΥСΡ־֡ס̾ Exp ˤʤäƤ
$Log$ΥåκݤΡѹҡפɽ롥
ե뤬礭ʤäƤޤΤȡrlog ƱȤǤȤȤ顤ޤȤʤ



notes.png ½: Υɤƽ񤭹եå & åȤơɤɤѤƤ뤫ǧ.



Commands: RCS ޥ

ʲˡRCS ΥޥɤˤĤƴñʰܤ褦 ܤ man ޥɤĴ٤ɤ̾Ϥ줰餤ΤäƤнʬʤϤǤ롥

ci␣ץ␣ե̾
å󥳥ޥɡ
⥪ץĤʤȡե뤬Ͽ & ۼƤޤäơ긵˸Υե뤬̵ʤ뤬Ƥʤ褦ˡ ϹƤ˥åȤɤ
ץ(ĤʤƤ褤)ϰʲ̤ꡥ

-l   å塤ưŪˡ֥åդǡץåȤ롥
-u   å塤ưŪˡ֥åʤǡץåȤ롥
-zLT   ɽ֥֡פǹԤ 줬̵Ȥϡ˥åɸǻɽ롥
-rӥֹ   ꤷӥֹǥå󤹤롥 ӥ礭ȤȤʤɤѤ롥
-f   ե뤬ѹƤʤƤ⶯Ū˥å󤹤롥

co␣ץ␣ե̾
åȥޥɡ
ץʤĤʤƤ褤ˤϰʲ̤ꡥ

-l   ֥åդǡץåȤ롥
-u   ֥åʤǡץåȤ롥
-zLT   ɽ֥֡פǹԤ 줬̵Ȥϡ˥åɸǻɽ롥
-rӥֹ   ꤷӥֹΥСΥեåȤ롥
-f   ˥ե뤬¸ߤƤƤ⡤åȤƶŪ˾񤭤롥

ident␣ץ␣ե̾
եΥɤɤ߽Фޥɡ
礭ưѤ륪ץʤĤʤƤ褤ˤϤʤ

rlog␣ץ␣ե̾
СեΥ(Ͽ)å䡤ϢϤ륳ޥɡ
ץʤĤʤƤ褤ˤϰʲ̤ꡥ

-L   åƤեоݤȤ롥
-R   Сե̾ɽ롥
-h   Ϣɽ롥
-t   Ϣɽ롥-h ץ⾯¿
-rӥֹ   ꤵ줿ӥֹΥեξΤߤɽ롥

rcsdiff␣ץ␣-rֹ1␣-rֹ2␣ץ␣ե̾
СƤեΥС㤤٤롥

ĤֹϾάǽǡֹθĿˤäƼΤ褦ư롥
ֹ1 ֹ2 ͿƤ   ơĤΥСΥեӤ롥
ֹ1 ΤߤͿƤ   ֹ1 ΥСΥեȡ¸ߤեȤӤ롥
ֹϰĤͿƤʤ   ϿѤߤκǿСȡ¸ߤեȤӤ롥

rcs␣ץ␣ե̾
Сե͡ѹ롥
ץ(άǤʤ)ϰʲ̤ꡥ

-l   եå롥
-u   եå롥
-L   å̩˹Ԥ⡼ɤˤ(̤ϥǥե)
-U   å̵ۤʥ⡼ɤˤ롥 Υ⡼ɤǤϡåƤʤեǤåǤ롥 ޤ˥åΩĤȤΤǡåΤΤ̵ˤ뤳ȤϤޤꤪᤷʤ



Report: ݡ

ʲβˤĤǽ¤긭ĴȹͻԤ
AppliedMath7-Report-09
Ȥ̾Ĥ e-mail ˤƶ˥ݡȤȤФ. ʤݡȤ e-mail TeX Ǻ̤ˤФƤ褤.

Exercises:

  1. μȤǤޤǤ˺եƤ RCS ǤΥСߤƤߤ补
    κݡ$Log$ ǽǤߤƻپ㤬ʤɤå补 ⤷پ㤬ʤСɤäƲ褹ɤޥ˥奢Ĵ٤ʤɤƹͤ补

  2. RCS 򤤻ȤʤͤƤߤ补

  3. RCS GUI(ե桼󥿡ե)ǤȤ٤եȥ̵õƤߤ补 ĤʤСȤäƤߤƥӥ塼补

  4. RCS οʲǤȤ⤤СեȤ CVS, Subversion ˤĤĴ١ RCS Υå󡤥åȤ CVS, Subversion ǤϤɤʤäƤΤ򵭤.



about Icons, ClipArts

For details, see JNorth_arrow-right-sm.png this.


*1 webäƤ⤹ƤϤʤԴǤϤ뤬桹ˤϲޥ󤬤ǤϤʤ!
*2 㤨СĥҤ3ʸޤǤȤ¤ DOS Ȥ OS Ѥ RCS ǤϳĥҤκǸ1ʸŪ v ѹȤˡȤäƤ
*3 ɤ뤫ҤͤƤ뤳Ȥ⤢롥λϹɤ

źեե: filercs-howto.png 11 [ܺ]