bazaar v2.2b1 documentation · bazaar bazaar bzr bzr bzr help topic bzr help topics id id e bazaar...

395
(2.2b1) »

Upload: others

Post on 26-Sep-2019

41 views

Category:

Documents


0 download

TRANSCRIPT

  • (2.2b1) »

  • BazaarBazaar http://doc.bazaar-vcs.org/ http://bazaar-vcs.org/Documentation

    http://doc.bazaar-vcs.org/http://bazaar-vcs.org/Documentation

  • Bazaar

  • —VCS—VCS

    http://bazaar-vcs.org/BzrSwitchinghttp://bazaar-vcs.org/BzrMigrationhttp://bazaar-vcs.org/BzrGlossaryhttp://bazaar-vcs.org/FAQ

  • TortoiseBzrhttps://launchpad.net/bzr/+downloadbzr-setup-x.xxx.exe

    20091bzr-setup-1.9.exe

    Pythonbzr bzr.exe( C:\ProgramFiles\Bazaar)bzr.bat(C:\PythonXX\Scripts)bzrbzr.exebzr.batbzr.txt

    (2.2b1) »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    https://launchpad.net/bzr/+downloadhttp://sphinx.pocoo.org/

  • |(2.2b1) » »

  • Bazaar

  • “Bazaar”””(:)

  • (WebUnix)Bazaar

    Bazaar (branch)

    “ (revision) ”

    (:Theserevisionshaveotherusesaswell.)“Web”“sftp#595”

    sftp

  • “(checkout)”

    Bazaar ()((commit))

    Bazaar (revision)

    undoBazaar

    Bazaar‘’(ancestry)’’Bazaarlock-step

  • BazaarBazaar bzrbzr bzrhelptopicbzrhelptopics

    IDIDeBazaarBazaar

    1. bzrwhoamiIDID:

    %bzrwhoami"YourName"

    :

    %bzrwhoami--branch"YourName"

    2. ?/.bazaar/bazaar.conf[1] [DEFAULT]:

    [DEFAULT]email=YourName

    ?/.bazaar/locations.conf

    [/the/path/to/the/branch]email=YourName

    3. $BZR_EMAIL $EMAIL($BZR_EMAIL)

    [1]

    Windows?/.bazaar/branch.confC:\DocumentsandSettings\\ApplicationData\Bazaar\2.0\branch.conflocations.conf,ignore,plugins

  • .bzr

    bzrinit:

    %mkdirtutorial%cdtutorial%ls-a./../%pwd/home/mbp/work/bzr.test/tutorial%%bzrinit%ls-aF./../.bzr/%

    unknown,ignored,versioned addversioned:

    %echo'helloworld'>hello.txt%bzrstatusunknown:hello.txt%bzraddhello.txtaddedhello.txt%bzrstatusadded:hello.txt

    add unversioned bzr remove bzrremove [2]

    [2] (1,2)bzrremove --keep --force

  • svnsvk( bzrinit-repo)

    bzrhttpftp:

    %bzrloghttp://bazaar-vcs.org/bzr/bzr.dev/%bzrlogsftp://bazaar-vcs.org/bzr/bzr.dev/

    rsync

  • (commit)

    status diff

    bzrstatus

    status:

    %bzrstatusmodified:foo

    bzrstatusstatus

    bzrdiff

    diffunifieddiffpipe’‘patch’‘,‘’diffstat’‘,‘’fileterdiff’‘,‘’colordiff’’

    %bzrdiff===addedfile'hello.txt'---hello.txt1970-01-0100:00:00+0000+++hello.txt2005-10-1814:23:29+0000@@-0,0+1,1@@+helloworld

    -r

    %bzrdiff-r1000..#everythingsincer1000%bzrdiff-r1000..1100#changesfrom1000to1100

    --diff-optionsbzrdiff:

  • %bzrdiff--diff-options--side-by-sidefoo

    patch --prefix bzr diff -p1 patch-p1

  • (commit)

    bzrcommit

    commitID-m --message

    %bzrcommit-m"addedmyfirstfile"

    -Fdiff()

    -m -F bzr $VISUAL$EDITOR``/.bazaar/bazaar.conf`` editor$BZR_EDITOR

    commit --show-diffdiffdiffdiffdiffdiff

    commit

    %bzrcommit-m"documentationfix"commit.py

    bzr

  • %bzrcommit.

  • revertrevert bzrdiffrevertrevertrevert

  • .bzrignore

    addunknownfilebzr

    (”glob”):

    *.o*?*.tmp*.py[co]

    glob .o config.h doc/HTML:

    ./config.hdoc/*.html

    bzrignored:

    %bzrignoredconfig.h./config.hconfigure.in?*?

    ‘unknown’’ignored’

    .bzrignore

    %bzradd.bzrignore%bzrcommit-m"Addignorepatterns"

  • ~/.bazaar/ignoreignore

  • bzrlog

    bzrlog bzrlog--forward

    bzrdiff bzrlog -r:

    %bzrlog-r1000..#r1000%bzrlog-r..1000#r1000%bzrlog-r1000..1100#r1000r1100%bzrlog-r1000#r1000

  • bzrinfo

  • bzr:

    %mkdirsrc%echo'intmain(){}'>src/simple.c%bzraddsrcaddedsrcaddedsrc/simple.c%bzrstatusadded:src/src/simple.c

  • cvsremoveCVS

    bzrremove [2]

    %rm-rsrc%bzrremove-vhello.txt?hello.txt%bzrstatusremoved:hello.txtsrc/src/simple.cunknown:hello.txt

    bzrrevert

  • branch:

    %bzrbranchhttp://bazaar-vcs.org/bzr/bzr.dev%cdbzr.dev

    (log,annotate,branch)

    tarballrsync

  • “pull”

    %bzrpull

    pull‘’revision-history’’

    (pull)

  • () bzrmergemerge

    %bzrmergeURL

    (conflict)(basename)3“.BASE”“.THIS”“.OTHER”kdiff3“.THIS”resolve“.OTHER”“.BASE”.BASE,.THIS,.OTHERcommit

    %kdiff3file.BASEfile.OTHERfile.THIS%mvfile.THISfile%bzrresolvefile

    [TODO:explainconflictmarkerswithinfiles]

  • bzrWeb.bzrpush()3

    bzr

    %bzrpushsftp://servername.com/path/to/directory

    bzrtools rspushpushrsync

    tarballrsync

  • %cdNEWDIR%bzrmerge--uncommittedOLDDIR

    OLDDIRNEWDIRmergeNEWDIROLDDIRNEWDIR bzrrevertOLDDIR

    NEWDIROLDDIR

    |(2.2b1) » »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) » »

  • LaunchpadBazaar

  • Bazaar””Bazaar

    - --

    :

    KarlFogel-ProducingOpenSourceSoftware-

    (CollaborativeDevelopmentEnvironments:CDEs)WEBSourceForge java.net SAPCommunityNetworkCDEs

    :

    PyhonPHPRubyJavaPerlgccJDKzlibopensslZopeRubyonRailsSpring

    FirefoxThundervirdOpenOffice.orgDrupalWordpressJoomla

    http://www.producingoss.com/http://sourceforge.nethttp://java.nethttps://www.sdn.sap.com/irj/sdn

  • :

    XYZ10OS5

    Launchpad:

    UbuntuCanonicalLaunchpad(https:launchpad.net)LaunchpadCDEs:

    Launchpad

    Bazaar:Launchpad

    BazaarLaunchpad:

    1. BazaarLaunchpad2. LaunchpadBazaar

    https://launchpad.nethttp://www.ubuntu.comhttps:launchpad.net

  • FindingandbrowsingbranchesusingLaunchpad

    Findingavailablebranches

    While there are many advantages in adopting distributed versioncontrol,oneof the things thatdisappears is theall-knowingcentralserver with knowledge about all available branches. Indeed in adistributed environment, interesting branches can literally exist in100s of locations across the Internet (orwithin an Intranet for thatmatter).

    Launchpadfillsthisgapbyprovidingaregistryofbranches.

    Registeringbranches

    Branches can be uploaded to Launchpad or simply registered asbeingavailableinanexternallocation.BranchescanalsobegivenaStatussuchasNew,Development,MatureorAbandoned.

    Note: External branches can even be hosted in legacy versioncontrol tools, i.e.CVSandSubversion.Code in thesesystemswillbescannedandconvertedtoBazaarbranchesonaperiodicbasis.Formaximumfidelityofcourse,itispreferableforexternalbranchestobehostedinBazaar.

    Browsingbranches

    Branches can be listed, filtered and sorted by numerous attributesincluding Name, Registrant, Author, Status, Age and time of lastcommit.Browsingofbranchesisalsoprovidedmakingiteasytoseethingssuchas:

  • wherethebranchcanbedownloadedfromhowtouploadchangesrecentcommitsandthechangesmadebyeachthesourcecodeofindividualfilesforagivenversion.

  • AccessingcodeinLaunchpadusingBazaar

    Gettingthecodeforanopensourceproject

    AsLaunchpadkeepstrackofthousandsofopensourceprojectsandtheir latest code whether it be managed by Bazaar, CVS orSubversion,Bazaaruserscangrabthatcodeaseasilyasthis:

    bzrbranchlp:project-name

    where project-name is the Launchpad project ID. Here are someexamples:

    bzrbranchlp:inkscapebzrbranchlp:amarokbzrbranchlp:pythonbzrbranchlp:railsbzrbranchlp:java-gnome

    You can then browse the code locally using your favorite editor orIDEandchangethecodeifyouwish.

    Ifaprojecthasmultipleseriesregistered(e.g.adevelopmentseriesandamaintenanceseries),thelatestcodeforagivenseriescanbefetchedusing:

    bzrbranchlp:project-name/series

    Publishingyourchanges

    Having fixed that annoying bug or added that cool feature you’vealwayswanted,it’stimetoimpressyourfriendsandmaketheworldabetterplacebymakingyourcodeavailabletoothers.Asexplainedearlier,LaunchpadisafreeBazaarcodehostingservicesoyoucan

  • pushyourbranchtoitandotherscanaccessyourcodefromthere.For example, assuming you are a member of the relevant team,logintolaunchpadlikethis:

    bzrlaunchpad-loginuserid

    whereuserid is your Launchpad user ID. You can then push yourchangestoateambranchlikethis:

    bzrpushlp:~team-name/project-name/branch-name

    Otherscanthendownloadyourcodelikethis:

    bzrbranchlp:~team-name/project-name/branch-name

    Personalbranches

    Evenifyouarenotamemberofateam,Launchpadcanbeusedtopublishyourchanges.Inthiscase,simplycreateapersonalbranchlikethis:

    bzrpushlp:~userid/project-name/branch-name

    Otherscanthendownloadyourcodelikethis:

    bzrbranchlp:~userid/project-name/branch-name

    Note:Evenwhenpublishingtoapersonalbranch,itispolitetonotifythe upstream developers about your branch so they can pull yourchangesfromitiftheyaregenerallyapplicabletoallusersandmeettheproject’squalitystandards.

  • LinkingbranchesusingLaunchpad

    Associatingabranchwithabug

    After registering a branch, you can associate it to a bug so thatpeople interested in that bug can track and download the fix as itbecomesavailable.

    Todothis,thestepsare:

    1. Navigatetothebuginquestion.2. SelectAddbranchunderActions.3. Selectthebranch.4. Optionally set the State of the relationship. This is Fix In

    Progressbydefaultbutyoumaywishtoset it toanotherstatesuchasFixAvailableifthebranchalreadyaddressestheissue.

    Ifyouwish,youcanalsoprovidesomearbitrarycommentsabouttherelationshipbetweenthebugandthebranch.

    ChangingthestateinLaunchpadwhilecommittinginBazaar

    Bazaar and Launchpad can work together to reduce some of thestatushousekeeping for you.Whenyoucommit usingBazaar, usethe–fixesoptionlikethis:

    bzrcommit--fixeslp:1234-m"..."

    where 1234 is the bug ID. Thiswill changes theState of the bug-branchrelationshiptoFixAvailable.Iftheonecommitfixesmultipleissues,the–fixesoptioncanbespecifiedmultipletimes.

  • OneofthecoolthingsaboutthisfeatureisthatLaunchpaddoesnotneedtobeaccessiblewhenmakingthecommit.The--fixesoptionworksbystoringmetadatawhichLaunchpadwilldetectnexttimethebranchispushedtoitorscannedonceonlineagain.

    Note:Launchpadwillnotimplicitlycloseabugjustbecauseabranchis available that fixes it. Thereare several reasons for this. Firstly,the branch usually needs to be merged into the trunk (maindevelopmentbranch)beforemostteamsconsideritfixed.Secondly,manyteamshaveaseparateprocessforconfirmingbugsarefixedoverandaboveadevelopersayingso.

    As explained later, merge control features are currently underdevelopmentinLaunchpadandautomaticallychangingthestatusofbugstoFixCommittedwillbemoreappropriateoncethosefeaturesareinplace.

    Associatingabranchwithablueprint

    Afterregisteringabranch,youcanassociateittoablueprintsothatpeopleinterestedinthatblueprintcantrackandtestthefeatureasitdevelops.

    Todothis,thestepsare:

    1. Navigatetotheblueprintinquestion.2. SelectLinkbranchunderActions.3. Selectthebranch.

    Ifyouwish,youcanalsoprovidesomearbitrarycommentsabouttherelationshipbetweentheblueprintandthebranch.

  • ManagingreleasesusingLaunchpad

    Integratingchanges

    Once a branch has been developed and published, communitiestypically go through a rigorous process before those changes areintegratedintothecoreproductandrolledouttoendusers.Someofthestepsinvolvedmayinclude:

    peerreviewofthechangesdecidingwhichreleasestoincludethechangesin,e.g.thenextmaintenancerelease,thenextmajorrelease,orbothrunningfunctionalregressiontestsbenchmarkingtoensureperformanceremainsacceptablepackagingintoearlyaccessreleasesforendusertestingdocumentation updates, e.g. Release Notes for the targetedreleasestranslationoftheuserinterfaceanddocumentationintomultiplelanguages.

    ThissectionbrieflylooksatsomeofthefeaturesinLaunchpadthathelp get good quality code into production. Strong integration withBazaariscoretomakingthishappensmoothly.

    Note:Where indicated, some of the features below are still underdevelopment. If oneormoreof these features interest you,pleaseconsider joining the Launchpad beta test team at this link:https://help.launchpad.net/JoiningLaunchpadBetaTesters. You canthen get early access to features and provide feedback to thedevelopersbeforewiderroll-out.

    Branchmergeproposals

    https://help.launchpad.net/JoiningLaunchpadBetaTesters

  • After navigating to a branch in Launchpad, one of the availableactionsisProposeformerging.Thisletsyounominatewhichbranchthiscodeoughttobemergedinto.

    Tracking the knowledgeaboutwhich branches are proposed to bemergedintoacodelinehelpsReleaseManagerskeepontopofwhatstillneedstobecompleted,orcanbecompleted,beforeashipdate.Using this information, theycanensurebranchesaremergedaftercompletinganynecessaryreviews.Inthesimplecase,theReleaseManagermaymanuallymergebranches. Inmoreadvancedcases,themergingcouldbeautomaticallydonebyarobot(likePQM)whenthebranchreachestherightstate(e.g.Reviewcompleted).

    Codereviewtracking

    AnumberoffeaturesareunderdevelopmentinLaunchpadtotrackthe states, conversations and outcomes of code reviews. Thesefeaturesareexpectedtobeintegratedwithbranchmergeproposalsandbranchbrowsingfeatures.

    PersonalPackageArchives(PPAs)

    PPAs help developers and development teams get custom buildsinto the hands of users for early testing and feedback. In otherwords,aPPAallowsadevelopertoformacommunityoftesterswhoareinterestedintheirchanges.Thetestingcommunitycaninstallthepackages,runthemforthetestperiodandthenremovethemcleanlyfromtheirsystem.

    Seehttps://help.launchpad.net/PPAQuickStartforfurtherdetails.

    Translations

    TheTranslationsmoduleinLaunchpadisdesignedtomakeiteasy

    https://launchpad.net/pqmhttps://help.launchpad.net/PPAQuickStart

  • foranyonetogetinvolvedtranslatingapplicationstolanguagestheyknow.Translatorsareshieldedfromthelowleveldetails.

    Launchpadkeepstrackofthetranslationsforeachmajorversionofaprojectseparately,allowing translators tocontinue to improve thetranslationsofyourstablereleaseswhileothersstartworkonnewerversionsthatarestill indevelopment.Translationspeed inreducedbysharingresourcesacrossprojects.Automaticsuggestions,fromalibrary of 750,000 translated strings, and a community of 19,000registered translatorscan radically cut the time required to localiseyourprojectintomanylanguages.

  • SummaryThecommunitieswejoin,whetheroff-lineoron-line,sayalotaboutthesortofpeopleweare.The flip-side to this is that the toolsyouchooseforyourcommunity-particularlytheCDEandversioncontroltool-canhavealargeimpactonwhojoinsandhoweasilytheycancontribute.

    In their own right, Launchpad and Bazaar are highly useful tools.Together,theycan:

    help your community trackmajor assets such as source codeandknowledgehelpitgrowbyreducingbarrierstoentryhelpitinteractwithrelatedcommunities.

    In particular, Launchpad is a free code hosting service for yourBazaarbranches,branchescanbebrowsedonline,branchescanbelinked to bugs and blueprints, and the status of bug-branchrelationshipscanbeautomaticallymanagedbymentioning thebugwhilecommittinginBazaar.Furtherintegrationisunderdevelopmentwith theaimofstreamlining theprocess fromgreat idea torunningcodeinthehandsofendusers.

    If you have any feedback on how you’d like to see Bazaar andLaunchpad further integrated, please contact us on the Bazaarmailinglist,[email protected].

    While designed as a free service to support open source projects,Canonicalmaymake Launchpad available to commercial softwaredevelopersdependingontheirrequirements.WewouldbehappytohearfromyouifyouthinkLaunchpadwouldbeusefulformanagingyourcommunity,opensourceorotherwise.

    mailto:bazaar%40lists.canonical.com

  • |(2.2b1) » »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) » »

  • Bazaar BazaarBazaar Bazaar

    CVSSubvresion

    http://bazaar-vcs.orghttp://bazaar-vcs.orghttp://bazaar-vcs.orghttp://bazaar-vcs.org

  • Bazaar

    E

    ID

    %bzrwhoami"JohnDoe"

    Bazaar

    %bzrinit-repo--trees~

    (CVS/SVN)()

    centralhost

    %bzrinit-repo--no-treessftp://centralhost/srv/bzr/

    cvsrootSubversion --no-tree

    http://bazaar-vcs.orghttp://bazaar-vcs.org

  • BazaarBazaar Tracking Upstream ”Converting andkeepinghistory”

    Developer1:

    ”sigil”

    %bzrinitsftp://centralhost/srv/bzr/sigil

    CVS”HEAD”Subversion”trunk” dev

    %cd~%mkdirwork%cdwork%mkdirsigil%cdsigil%bzrcheckoutsftp://centralhost/srv/bzr/sigildev%cddev%cp-ar~/sigil/*.%bzradd%bzrcommit-m"InitialimportofSigil"

    ( sigil) centralhost/

    ~/work/sigil/dev/ centralhost

    DeveloperN:

    1 E

    http://bazaar-vcs.orghttp://bazaar-vcs.orghttp://bazaar-vcs.org/TrackingUpstream

  • :

    %cd~/work/sigil%bzrcheckoutsftp://centralhost/srv/bzr/sigildev

    sftp://centralhost/srv/bzr/sigil Bazaar

    http://bazaar-vcs.orghttp://bazaar-vcs.org

  • CVSSVNCVSSVN Bazaar

    centralhost

    %cd~/work/sigil%bzrbranchsftp://centralhost/srv/bzr/sigil\sftp://centralhost/srv/bzr/sigil/doodle-fixes%bzrcheckoutsftp://centralhost/srv/bzr/sigil/doodle-fixesdoodle-fixes%cddoodle-fixes

    doodle ~/work/sigil/doodle-fixes/centralhost [1]dev [2]

    [1]

    [2] (1,2)URLURL bzrtools bzrcbranch cbranch:

    %bzrcbranchdevmy-feature-branch

    doodle-fixes:

    %cd~/work/sigil/dev%bzrmerge../doodle-fixes

    dev bzr status bzr

    http://bazaar-vcs.orghttp://bazaar-vcs.org/BzrTools

  • diffBazaar_bzrstatus bzrconflicts``bzrresolvefile/name`` bzrresolve--all [3] bzrremerge(

    [3]

    :

    %bzrbranchsftp://centralhost/srv/bzr/sigil\sftp://centralhost/srv/bzr/sigil/user-a%bzrbranchsftp://centralhost/srv/bzr/sigil\sftp://centralhost/srv/bzr/sigil/user-b

    [2]

    %bzrbranchsftp://centralhost/srv/bzr/sigil/user-a\sftp://centralhost/srv/bzr/sigil/user-a/feature%cd~/work/sigil%bzrcheckoutsftp://centralhost/srv/bzr/sigil/user-a/featuremyfeature

  • Bazaar””CVSSubversionRCSSubversion””

    Bazaar””

    |(2.2b1) » »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://bazaar-vcs.orghttp://bazaar-vcs.orghttp://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar

  • BazaarBazaar()Bazaar

    Bazaar(versioncontrolsystems:VCS)Bazaar

    Bazaar

  • 4:

    1. SCCSRCS2. -CVS3. -Subversion4. -Bazaar

    BazaarBazaar

  • vsVCS( , repository)

    (checkout) ( , working tree) (,commit)

    VCS

    VCSBazaar

    VCS

    -“feature-wide”

    :

    VCS http://bazaar-vcs.org/BzrWhy

    http://bazaar-vcs.org/BzrWhy

  • BazaarBazaarVCSVCSBazaarWikihttp://bazaar-vcs.org/

    : BazaarPython http://bazaar-vcs.org/BzrSupport

    http://bazaar-vcs.org/http://bazaar-vcs.org/BzrSupport

  • Bazaar:

    Bazaar

    2-6BazaarBazaar7Bazaar

    :

    5Bazaar-Bazaar -1

    Bazaar

    Bazaar( [email protected])

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    mailto:bazaar%40lists.canonical.comhttp://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar4:

    (Revision) -(Workingtree) -(Branch)-(Repository)-

  • :

    id(revision-id) id:

    [email protected]

    idid (revisionnumbers)

    1422977.1.5910id109()()

    Bazaar

  • (workingtree)

    commit

  • (tip)

    (marged back) () directed acyclic graph(DAG)

    :

    DAG (mineline),(trunk), (lefthandside:LHS)

  • BazaarBazaar (standalonetree) 1:

    (sharedbranch)-(stackedbranch) -(lightweightcheckout) -

    Bazaar

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BazaarBazaar“”Bazaar

    Bazaar

  • VCS1

    :

    Bazaar()

  • 2 ()()2()

    :

    BazaarCVSSubversion:

  • lock-step CVSSubversion/ bzrupdate bzrcommit

    SubversionCVSBazaarCVSSubversion:

  • commit--localunbind

    :

    SubversionCVSVCSBazaar

  • :

    -

    SubversionCVSVCSBazaar()

  • 1()1

    :

    BundleBuggyBazaar

  • :()

    :

    ()

    BazaarPatchQueueManager(PQM)

  • 362

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar

  • LinuxBazaarUbuntu/DebianRedHatGentooLinux http://bazaar-vcs.org/Download

    http://bazaar-vcs.org/Download

  • WindowsWindowsBazaar http://bazaar-vcs.org/Download

    :WindowsCygwinCygwinBazaarWindows

    http://bazaar-vcs.org/Download

  • BazaarLinuxWindowsMacOSX,FreeBSD,Solaris http://bazaar-vcs.org/Download

    http://bazaar-vcs.org/Download

  • Bazaar:

    1. 2.4Python2. http://bazaar-vcs.org/Download Launchpad

    (https://launchpad.net/~bzr/)bazaar-xxx.tar.gz(xxx)

    3. tarWinZip4. PATH

    bzr:

    bzrversion

    BazaarEIRC

    site-wide

    PATHbzr:

    pythonsetup.pyinstall

    Pythonbzr()pure-python:

    pythonsetup.pyinstallbuild_ext--allow-python-fallback

    http://bazaar-vcs.org/Downloadhttps://launchpad.net/~bzr/

  • Bazaar()

    :

    1. 1Bazaar

    2. :

    bzrbranchhttp://bazaar-vcs.org/bzr/bzr.dev

    3. (bzr.dev)PATH

    C make pyrexCEIRC

  • Bazaar bzr bzr

    ()

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar bzr(GUI)

  • bzr:

    bzr[]command[]

    Bazaar command

  • -h –help gethelp-v –verbose bemoreverbose-q –quiet bemorequiet

    Quiet

    :1-v

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • helpBazaar:

    bzrhelptopics

    :

    bzrhelpcommands

    xxxxxx:

    bzrhelpxxx

    Bazaar

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar

  • Bazaar11:EBazaarEBazaar whoami:

    %bzrwhoami"YourName"

    whoami

  • Linux/Unix $HOME/.bazaar Windows C:\Documents andSettings\\ApplicationData\Bazaar\2.03:

    bazaar.conflocations.confdauthentication.conf

    .bzr/branch/branch.conf 1 locations.conf

    whoamiE bazaar.conf:

    [DEFAULT]email=YourName

    Bazaar

  • BZR_HOME/rulesBazaar

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • bazaar.conf [ALIASES](=)ALIASES:

    [ALIASES]recentlog=log-r-3..-1ll=log--line-r-10..-1commit=commit--strictdiff=diff--diff-options-p

    :

    3 recentlogll10commitcommitdiff-pdiff

  • :

    %bzrrecentlog%bzrll%bzrcommit%bzrdiff

  • lastlog-r-5..105 commit--no-strictcommit commit=commit--strict lastlog ll --no-aliases bzr bzr --no-aliases commit commit--strictcomit

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BazaarBazaarBazaar:

    Bazaar

    Bazaar

  • http://bazaar-vcs.org/BzrPlugins

    http://bazaar-vcs.org/BzrPlugins

  • Bazaar plugins Linux ~/.bazaar/Windows C:\Documents and Settings\\ApplicationData\Bazaar\2.0\($BZR_HOME)

    BazaarLinuxbzrtools:

    bzrbranchhttp://panoramicfeedback.com/opensource/bzr/bzrtools~/.bazaar/plugins/bzrtools

    Python ( -) bzr-gtk$BZR_HOME/plugins/bzr-gtk $BZR_HOME/plugins/gtk

  • 2:

    1. -bzrlib/plugins2. -$BZR_HOME/plugins.

    Linux /usr/lib/python2.4/site-packages/bzrlib/plugins/$HOME/.bazaar/plugins/ Windows C:\\ProgramFiles\\Bazaar\\plugins C:\Documents and Settings\\ApplicationData\Bazaar\2.0\plugins

    BZR_PLUGIN_PATH

  • plugins:

    bzrplugins

    bzrhelpcommands

  • GUI QBzr QtGUIGUI bzr-gtk GTKGUIGUI bzr-eclipse EclipseGeneral bzrtools shelfGeneral difftoolsGeneral extmergeIntegration bzr-svn SubversionMigration cvsps CVS

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar

  • BazaarBazaarVCSBazaar”grok”

    :Bazaar

  • (11010)“10”“3050”

    (3112.1.5)3 [1].233112.1.531125

    [1] 1.2bzr3(1.1.1.1.1)

  • :

    100MaryX3BillY4

    VCSMaryBill:

    107:AdddocumentationforY106:FixbugfoundintestingY105:FixbugfoundintestingX104:AddcodeforY103:AdddocumentationforX102:AddcodeandtestsforX101:AddtestsforY100:...

    BazaarBazaar

    VCSMary:

    103:FixbugfoundintestingX102:AdddocumentationforX101:AddcodeandtestsforX100:...

    Bill:

    104:AdddocumentationforY103:FixbugfoundintestingY102:AddcodeforY101:AddtestsforY100:...

    push():

  • 107:FixbugfoundintestingX106:AdddocumentationforX105:AddcodeandtestsforX104:AdddocumentationforY103:FixbugfoundintestingY102:AddcodeforY101:AddtestsforY100:...

    non-linear:

    102:MergefeatureX100.2.3:FixbugfoundintestingX100.2.2:AdddocumentationforX100.2.1:AddcodeandtestsforX101:MergefeatureY100.1.4:AdddocumentationforY100.1.3:FixbugfoundintestingY100.1.2:AddcodeforY100.1.1:AddtestsforY100:...

    :

    102:MergefeatureX100.2.3:Fixbug100.2.2:Adddocumentation100.2.1:Addcodeandtests101:MergefeatureY100.1.4:Adddocumentation100.1.3:Fixbugfoundintesting100.1.2:Addcode100.1.1:Addtests100:...

    :

    ()

    (Continuousintegration:CI)(CI-(TDD)-)

  • :

  • Bazaar:

    ””

    MaryMary:

    104:Mergemainline100.2.1:MergefeatureY100.1.4:Adddocumentation100.1.3:Fixbugfoundintesting100.1.2:Addcode100.1.1:Addtests103:FixbugfoundintestingX102:AdddocumentationforX101:AddcodeandtestsforX100:...

    Mary()1

    BazaarURL (BazaarURL)

    Bazaar

    ::2AliceBob10

  • --Bazaar

    Bazaar:

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • ()()

    Bazaar1

  • :

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • ():

    cdmy-stuffbzrinitbzraddbzrcommit-m"Initialimport"

    bzrinit .bzr( my-stuff):

    Bazaar-Bazaar .bzr1

    bzradd bzrcommit

    init add commit

  • :

    bzrinit-repomy.repocdmy.repobzrinitmy.maincdmy.mainhack,hack,hackbzraddbzrcommit-m"Initialimport"

    main trunk dev

    init-repo init

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar bzraddBazaar:

    Bazaar

    VCSBazaar-

    :(“”)Bazaar

  • Bazaar add:

    bzraddfileXdirY/

  • .bzrignoreBazaar

    (“globs”):

    *.o*~*.tmp*.py[co]

    glob; .config.h doc/HTML:

    ./config.hdoc/*.html

    bzrignored:

    %bzrignoredconfig.h./config.hconfigure.in~*~

    ”unknown””ignored”

    .bzrignore:

    %bzradd.bzrignore%bzrcommit-m"Addignorepatterns"

    bzrignorePATTERNPATTERN .bzrignore(Bazaar) .bzrignore

  • bzr ~/.bazaar/ignore [1]

    [1]

    Windows ~/.bazaar/branch.conf: C:\DocumentsandSettings\\ApplicationData\Bazaar\2.0\branch.conf locations.conf ignoreplugins

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • 2bzr: status diff

  • bzrstatusstatus:

    %bzrstatusmodified:foo

    bzrstatus“”status

  • bzrdiffThediffunifieddiff‘’patch’‘‘’diffstat’‘‘’filterdiff’’‘’colordiff’‘:

    %bzrdiff===addedfile'hello.txt'---hello.txt1970-01-0100:00:00+0000+++hello.txt2005-10-1814:23:29+0000@@-0,0+1,1@@+helloworld

    -r2:

    %bzrdiff-r1000..#everythingsincer1000%bzrdiff-r1000..1100#changesfrom1000to1100

    --diff-optionsbzrdiff:

    %bzrdiff--diff-options--side-by-sidefoo

    --prefix bzr diff -p1 patch-p1

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • bzrcommit

    commitID-m --message;

    %bzrcommit-m"addedmyfirstfile"

    -F()

  • -m -F bzr $VISUAL $EDITOR ~/.bazaar/bazaar.conf editor; $BZR_EDITOR

    --show-diff

  • :

    %bzrcommit-m"documentationfix"commit.py

    bzr:

    %bzrcommit.

  • --authorcommit

    %bzrcommit--author"JaneRey"

    “author”“committer”

    --author

    %bzrcommit--author"JaneRey"\--author"JohnDoe"

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • bzrlogbzrlog

    bzrdiff, bzrlog -r:

    %bzrlog-r1000..#1000%bzrlog-r..1000#r1000%bzrlog-r1000..1100#10001100%bzrlog-r1000#1000

  • BazaarVCSVCS(DirectedAcyclicGraph:DAG)

    log:

    bzrlog-n0-rX

    :

    bzrlog-n0

    -n0gatekeepergatekeeperbzrloggatekeeper bzrlog-n2gatekeeper

    -n0

  • log:

    --forward

    --limit

    log

  • log:

    bzrlogfoo.py

  • cat:

    bzrcat-rXfile

    X file( less more):

    bzrcat-r-2foo.py|lessbzrcat-r1foo.py>/tmp/foo-1st-version.py

  • GUIQBzrbzr-gtkBazaar

    QBzr:

    bzrqlog

    bzr-gtk:

    bzrviz

    viz visualize

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • export tar.gz:

    bzrexport../releases/my-stuff-1.5.tar.gz

    export

    dir (none)tar .tar

    tbz2 .tar.bz2,.tbz2tgz .tar.gz,.tgzzip .zip

    -r root --root export

  • tag:

    bzrtagversion-1-5

    :

    bzrdiff-rtag:version-1-5

    tags

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar

  • .bzr

  • addBazaar remove

    remove :

    bzraddfoo.html(oops-didn'tmeanthat)bzrremovefoo.html

    --keep --force:

    bzraddfoo.html(oops-didn'tmeanthat)bzrremove--keepfoo.html(foo.htmlbzr)

    TODO:

    bzraddTODObzrcommit-m"addedTODO"(hack,hack,hack-butdon'tchangeTODO)bzrremoveTODO(TODO)

    :IDE commit

  • 1 commit revert:

    bzrrevert

    bzrstatus bzrdiff

  • revert:

    bzrrevertfoo.py

  • uncommit:

    bzruncommit

    revert uncommit:

    bzrcommit-m"Fixbug#11"(damn-wrongbugnumber)bzruncommitbzrcommit-m"Fixbug#1"

    1 commit commit--strict

    : merge uncommit( uncommit bzrstatus)merge merge Bazaar

  • -r:

    bzruncommit-r-3

    uncommit: revert

  • revert:

    %bzrcommit"Fixbug#5"Committedrevision20.(releasethecode)(hmm-badfix)bzrrevert-r19bzrcommit-m"Backoutfixforbug#5"

    19 revert

    :19(-1):

    bzrrevert-r-2

  • tag --force:

    bzrtag2.0-beta-1(oops,we'renotyetreadyforthat)(makemorecommitstoincludemorefixes)bzrtag2.0-beta-1--force

  • tag --delete:

    bzrtag2.0-beta-4(oops,we'renotreleasinga4thbeta)bzrtag2.0-beta-4--delete

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Peer-to-peer1212

    VCSpeer-to-peerBazaar

  • Bazaar

    2:

    “”

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • URLWindowsLinuxOSXSSHSFTPBazaar

    file:// ()sftp:// SFTP(SSHSFTP)bzr:// Bazaarftp:// FTPhttp://

    URL urlspecBazaar URL

    ftp://http://

  • ( ):

    bzrinit-repomy-repocdmy-repo

  • branch:

    bzrbranchURL[directory]

    URL(M:/)SFTPURL:

    bzrbranchM:/cool-trunkbzrbranchsftp://bill@mary-laptop/cool-repo/cool-trunk

    :

    bzrbranch/home/mary/cool-repo/cool-trunkcool

  • Bazaar branch log diff

    Bazaar

    Bazaar- (historyhorizon)-

  • info:

    bzrinfocool

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • (merging)

  • merge merge:

    bzrmerge[URL]

    URLBillMary:

    bzrmerge

    MaryBillURL:

    bzrmergesftp://mary@bill-laptop/cool-repo/cool-trunk

    --remember

  • Bazaar 3(3-waymerging) ABC2

    A B Cx x x x unchangedx x y y linefromCx y x y linefromBx y z ? conflict

  • :

    bzrcommit-m"MergedMary'schanges"

    Bazaar

    revert

  • Bazaar1 Bazaar

    VCS Bazaarpeer-to-peer“”

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar

  • merge conflicts status

  • merge13:

    foo.BASEfoo.THISfoo.OTHER

    foo

    resolveBazaar:

    bzrresolve

    :

    bzrresolvefoo

    resolveBASE,THIS,OTHER

  • remerge remerge:

    bzrremerge--weavefoo

    foo weave criss-cross()2

  • GUI extmerge:

    bzrextmergefoo

    foo --all

    extmerge bazaar.conf external_mergekdiff3 opendiffOSXFileMerge

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • annotate:

    bzrannotatereadme.txt

    annotate blame praise:

  • GUIBazaarGUIbzr-gtk gannotateGUI:

    bzrgannotatereadme.txt

    GUI()

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • SubversionCVSVCS()

    Bazaar

  • |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • no-trees:

    bzrinit-repo--no-treessftp://centralhost/srv/bzr/PROJECT

    cvsrootSubversionBazaar

  • 2:

    1.2.

    :

    bzrinit-repoPROJECT()bzrinitPROJECT/trunkcdPROJECT/trunk()cp-ar~/PROJECT.(OS)bzradd(;)bzrcommit-m"Initialimport"()bzrpushsftp://centralhost/srv/bzr/PROJECT/trunk

    2:

    bzrinit-repoPROJECT()cdPROJECTbzrinitsftp://centralhost/srv/bzr/PROJECT/trunkbzrcheckoutsftp://centralhost/srv/bzr/PROJECT/trunkcdtrunkcp-ar~/PROJECT.(OS)bzradd(;)bzrcommit-m"Initialimport"()bzrpushsftp://centralhost/srv/bzr/project/trunk

    checkout checkout branch

    (checkouts)

  • |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • bind:

    bzrbindsftp://centralhost/srv/bzr/PROJECT/trunk

    push

  • unbind:

    bzrunbind

  • 1 checkout

    SubversionCVSBazaar checkout diff log

  • BazaarBazaar:

    Bazaar

    Bazaar --lightweight:

    bzrcheckout--lightweightsftp://centralhost/srv/bzr/PROJECT/trunk

    --lightweight

    : , ,

  • 1SubversionCVSBazaar update:

    bzrupdate

  • commitBazaarSubversionCVS-Bazaarupdate

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • / --local commit:

    bzrcommit--local

  • --local commit unbindbind

    bind unbind bindURL

  • updateBazaar2 update:

    status

    commit

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • :

    .bzr

  • :

    1. 2. URL bind3. revert update

    bindupdate revert commit

    bind+update switch checkout

    : switch --force

  • switch1:

    bzrinit-repo--no-treesPROJECTcdPROJECTbzrbranchsftp://centralhost/srv/bzr/PROJECT/trunkbzrcheckout--lightweighttrunkmy-sandboxcdmy-sandbox(hackaway)

    trunk.bzr:

    (my-sandbox)bzrbranchsftp://centralhost/srv/bzr/PROJECT/PROJECT-1.0../PROJECT-1.0bzrswitch../PROJECT-1.0(fixbugin1.0)bzrcommit-m"blah,blahblah"bzrswitch../trunk(gobacktoworkingonthetrunk)

    :( checkout branch bind)

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • VCS

  • 1

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • () branch( checkout):

    bzrinit-repoPROJECTcdPROJECTbzrbranchsftp://centralhost/srv/bzr/PROJECT/trunk

  • -

    branch:

    bzrbranchtrunkfix-123cdfix-123(hack,hack,hack)

    :

    1.2.3. peer-to-peer

  • pull:

    cdtrunkbzrpull

  • merge:

    cdfix-123bzrmerge(resolveanyconflicts)bzrcommit-m"mergedtrunk"

  • :

    cdtrunkbzrupdatebzrmerge../fix-123(resolveanyconflicts)bzrcommit-m"Fixedbug#123"

    :

    cdtrunkbzrpullbzrmerge../fix-123(resolveanyconflicts)bzrcommit-m"Fixedbug#123"bzrpush

  • 1IT()

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • 1()

    :”/”:“/”1

  • 1PQM

    PQM https://launchpad.net/pqm

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    https://launchpad.net/pqmhttp://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • URL

    Bazaar:

  • ””--

    : merge

  • send

    send “” E sendE(

    --output(or-o) send -stdout:

    cdX-fix-123bzrsend-o../fix-123.patch

  • merge pull

    Bazaar patch -p0

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BazaarBazaar

    Bazaar

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • (cherrypicking)

    :

    fooX:

    bzrmerge-cXfoo

    fooX:

    bzrmerge-rXfoo

    fooX:

    bzrmerge-rX..foo

    fooXY:

    bzrmerge-rX..Yfoo

    bzrdiff

    Bazaar()

  • (upperbound)(lowerbound) 10:

    bzrmerge-r10..9

  • bar foo:

    1. bar2. bzrmerge--uncommittedfoo3. ( bzrdiff)4. foo5. bzrrevert

  • (rebase) rebase rebase

    rebase

    merge bzrresolve bzrrebase-continue bzrrebase-abort rebase-todo

    :VCS””Bazaar

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • ShelvingChangesBazaar shelf()unshelve

    ...:

    $bzrdiff===modifiedfile'description.txt'---description.txt+++description.txt@@-2,7+2,7@@===============

    Theseplugins-byMichaelEllerman+writtenbyMichaelEllermanprovideaveryfine-grained'undo'facility@@-11,6+11,6@@Thisallowsyoutoundosomeofyourchanges,-commit,andget+performacommit,andgetbacktowhereyouwerebefore.

    shelve:

    $bzrshelve---description.txt+++description.txt@@-2,7+2,7@@===============

    Theseplugins-byMichaelEllerman+writtenbyMichaelEllermanprovideaveryfine-grained'undo'

  • facility

    Shelve?[yNfrq?]:y---description.txt+++description.txt@@-11,6+11,6@@Thisallowsyoutoundosomeofyourchanges,-commit,andget+performacommit,andgetbacktowhereyouwerebefore.

    Shelve?[yNfrq?]:nShelve2change(s)?[yNfrq?]','y'Selectedchanges:Mdescription.txtChangesshelvedwithid"1".

    shelveshelve diff:

    $bzrdiff===modifiedfile'description.txt'---description.txt+++description.txt@@-2,7+2,7@@===============

    Theseplugins-byMichaelEllerman+writtenbyMichaelEllermanprovideaveryfine-grained'undo'facility

    !-:

    $bzrcommit-m"improvefirstsentence"

    shelve unshelve:

    $bzrunshelve

  • Unshelvingchangeswithid"1".Mdescription.txtAllchangesappliedsuccessfully.

    shelf unshelveshelveunshelve

    Bazaarshelveshelf

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Filteredviews

  • FilteredviewViewtreetree

    view shelveunshelveview()

    view-status,diff,commit,etc-view-pull,merge,update,etc-viewviewBazaarview

  • view, viewview:

    bzrviewfile1file2dir1...

    :

    Using'my'view:file1,file2,dir1

  • viewview view:

    bzrview

    view Nocurrentview.view:

    'my'viewis:a,b,c

  • viewviewview

    view:

    bzrview--nameview-namefile1dir1...

    :

    bzrview--namedocNEWSdoc/Usingdocview:NEWS,doc/

    view:

    bzrview--nameview-name

    view:

    bzrview--switchview-name

    view:

    bzrview--all

  • viewview offview(:merge)view

    view:

    bzrview--switchoff

    view:

    bzrview--switchmy

  • viewview:

    bzrview--delete

    view:

    bzrview--nameview-name--delete

    view:

    bzrview--delete--all

  • view“”

    viewpull,push,update

    viewviewviewviewview doc/doc/NEWS NEWSview doc/ doc/ NEWSviewview

    view:

    statusdiffcommitaddremoverevertmvls

    view:

    pullupdatemerge.

    viewview:

    loginfo

    |(2.2b1) »Bazaar »

  • ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • (stackedbranch):

    ()

  • branch stacked:

    bzrbranch--stackedsource-urlmy-dir

    my-dir source-url(stackedon) source-url

  • 2:

    1.2. reconfigure bind

  • or1 push:

    bzrpush--stacked-onreference-urlmy-url

    reference-url my-urlreference-url

    push --stacked stacked-on:

    bzrbranch--stackedsource-urlmy-dircdmy-dir(hack,hack,hack)bzrcommit-m"fixbug"bzrpush--stacked

  • bzrreconfigure bzrreconfigure--unstackedbzr

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BazaarHTTPFTPSFTPSSHinetd(smartserver)

  • HTTPFTPSFTPHTTP-WebDAV”(dumb)”BazaarBazaarBazaarBazaarURL:

    bzrloghttp://bazaar-vcs.org/bzr/bzr.dev

    BazaarFTPSFTP()HTTP-WebDAV

  • (hpss-high-performancesmartserver)

    --allow-writesSSHbzr --allow-writes

    SSH

    SSHBazaar:

    BZR_REMOTE_PATH=~/bin/bzrbzrlogbzr+ssh://host/path/to/branch

    BZR_REMOTE_PATH bzr bzr bzr

    bzr+ssh:// URLroot sftp:// URL(https://bugs.launchpad.net/bzr/+bug/109143)~

    inetd

    /srv/bzr/repo/branchname /srv/bzr/repo bzruser bzr

    inetdBazaarinetd.conf:

    4155streamtcpnowaitbzruser/usr/bin/bzr/usr/bin/bzrserve--inet--directory=/srv/bzr/repo

    URLinetd.conf --directory bzr://:

    https://bugs.launchpad.net/bzr/+bug/109143

  • bzrlogbzr://host/branchname

    inetdURL su

    4155bzr 4155

    :

    bzrserve--directory=/srv/bzr/repo

    :

    bzrlogbzr://host/branchname

    localhost 1234 bzrserve

    :

    bzrserve--port=localhost:1234--directory=/srv/bzr/repo

    :

    bzrlogbzr://localhost:1234/branchname

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar1 (hook) Bazaarcommit push pull uncommit

    ( bzr-push-and-update)

    https://launchpad.net/bzr-push-and-update/

  • :

    frombzrlibimportbranch

    defpost_push_hook(push_result):print"Thenewrevnois%d"%push_result.new_revno

    branch.Branch.hooks.install_named_hook('post_push',post_push_hook'Mypost_pushhook')

    push_hook.py plugins( plugins)

    push”Thenewrevnois...”Python

    2 push()push push_result

    2 'post_push' 23 'Mypost_pushhook'

  • hooks:

    bzrhooks

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • revno:

    $bzrrevno3104

  • version-info:

    $bzrversion-inforevision-id:[email protected]:2007-12-1117:51:18+0000build-date:2007-12-1313:14:51+1000revno:3104branch-nick:bzr.dev

    (Linux/Unix):

    $bzrversion-info|grep^datedate:2007-12-1117:51:18+0000

    --all

  • PythonMakefile:

    library/_version.py:bzrversion-info--formatpython>library/_version.py

    3:

    version_info:revisions: --all--include-historyfile_revisions: $Id$CVS revisionsfile-revisions

  • Bazaar version-info --custom --template

    C:

    bzrversion-info--custom\--template="#defineVERSION_INFO\"Project1.2.3(r{revno})\"\n"\>version_info.h

    {revno}(OS)BazaarVersionInfo

  • --all --check-clean bzr version_infoclean modifiedfile_revisions

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BzrTools

  • BzrToolsBazaar BzrTools: http://bazaar-vcs.org/BzrTools.

    http://bazaar-vcs.org/BzrTools

  • shellbzrshellBazaar:

    bzr

    Bazaar

  • cdiffbzrcdiffGNU/LinuxUNIXOSX bzrdiff:

    bzrcdiff|less-R

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • bzr-svn

  • bzr-svnSubversionBazaarVCSSubversionBazaarbzrSubversion bzr

    bzr-svnSubversionSubversionSubversionVCSBazaar

    bzr-svn: http://bazaar-vcs.org/BzrForeignBranches/Subversion.

    http://bazaar-vcs.org/BzrForeignBranches/Subversion

  • GNOME beagle:

    bzrinit-repo--rich-root-packbeagle-repocdbeagle-repobzrcheckoutsvn+ssh://svn.gnome.org/svn/beagle/trunkbeagle-trunk

    init-repo rich-root-packbzr-svnBazaar(:Bazaar2.0–rich-root-pack):

    bzrbranchbeagle-trunkbeagle-feature1cdbeagle-feature1(hack,hack,hack)bzrcommit-m"blahblahblah"(hack,hack,hack)bzrcommit-m"blahblahblah"

    :

    cd../beagle-trunkbzrupdatebzrmerge../beagle-feature1bzrcommit-m"CompletecommentforSVNcommit"

    Subversion

  • SubversionBazaarBazaarbzr-svn svn-import:

    bzrsvn-importsvn+ssh://svn.gnome.org/svn/beagle

    Bazaar:

    bzrinit-repo--rich-root-packbeagle-repocdbeagle-repobzrbranchbzr+ssh://bzr.gnome.org/beagle.bzr/trunkbeagle-trunkbzrbranchbeagle-trunkbeagle-feature1cdbeagle-feature1(hack,hack,hack)bzrcommit-m"blahblahblah"(hack,hack,hack)bzrcommit-m"blahblahblah"cd../beagle-trunkbzrpullbzrmerge../beagle-feature1bzrcommit-m"CompletecommentforSVNcommit"bzrpush

    Subversion( bzrpush)

    : pull pushURLbzr

    SubversionBazaarSubversioncronSubversion

  • bzr-svnBazaarSubversionbzr-svn0.5.4:

    BazaarversionedpropertiesBazaar

    bzr-svn http://bazaar-vcs.org/BzrForeignBranches/Subversion

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://bazaar-vcs.org/BzrForeignBranches/Subversionhttp://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BazaarWebLoggerheadLoggerheadhttps://launchpad.net/loggerhead

    http://bazaar-vcs.org/WebInterface

    :LaunchpadLoggerhead

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    https://launchpad.net/loggerheadhttp://bazaar-vcs.org/WebInterfacehttp://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar()

  • commit --fixes:

    $bzrcommit--fixeslp:12345-m"Properlyclosetheconnection"

    Launchpd12345Bazaar( lp)BugzillaTracRoundup/Bazaar

  • vsBazaarVCSpush

    :2LaunchpadLaunchpad

  • bzruncommit( --fixes)

    : uncommit

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar1 ..:

    $bzrlog-r1..4

    :

    $bzrlog-r1..$bzrlog-r..4

    1:

    $bzrcat-r42foo.c

    1 -c:

    $bzrdiff-c42

  • numberrevno:numberlast:numberrevid:guid IDbefore:rev ‘’rev’‘date:valuetag:valueancestor:pathbranch:pathsubmit:path

    Bazaar

    bzrlog“revno”10:

    $bzrlog-r..10

    -1

    10:

    $bzrlog-r-10..

    revid

    revid bzrlogID

  • :

    $bzrlog-rrevid:[email protected]

    before

    before‘’rev’‘’‘rev’’‘’rev’’‘’rev’’

    ‘’rev’’

    :

    $bzrlog-rbefore:before:4...revno:2...

    date

    date‘’value’’12

    :

    yesterdaytodaytomorrowYYYY-MM-DDYYYY-MM-DD,HH:MM:SS/2()

    “”:

    $bzrlog-rdate:yesterday..date:today

  • Ancestor

    ancestor:path

    pathURL

    ../parent:

    $bzrdiff-rancestor:../parent

    Branch

    branchpath

    pathURL

    :

    $bzrdiff-rbranch:http://example.com/bzr/foo.dev

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • Bazaar:

    :vsvs:/:

    4

    lightweightcheckoutstandalonetreefeaturebranchesswitchablesandbox.

  • CVSSVN

    :

    bzrcheckout--lightweightURLprojectcdproject

    :

    (makechanges)bzrcommit(makechanges)bzrcommit

    :

    bzrupdate

  • Bazaar

    :

    bzrbranchURLprojectcdproject

    :

    (makechanges)bzrcommit(makechanges)bzrcommit

    :

    bzrpush[URL]

    pushURL

    pushpushmerge:

    bzrmerge(resolveconflicts)bzrcommit

    :+push

  • “trunk”(:)“”

    :

    bzrinit-repoprojectcdprojectbzrbranchURLtrunk

    :

    bzrbranchtrunkfeatureXcdfeatureX

    :

    (makechanges)bzrcommit(makechanges)bzrcommit

    &:

    bzrsend

    (Launchpadmerge):

    bzrpush[URL]

    trunktrunktrunktrunkURL(:http)trunkPQM

  • sandboxgit(10000)(.o.class)

    :

    bzrinit-repo--no-treesprojectcdprojectbzrbranchURLtrunkbzrcheckout--lightweighttrunksandboxcdsandbox

    sandboxsandboxtrunk(trunkcheckout)trunktrunkbranchsandbox:

    bzrbranch../trunk../featureXbzrswitch../featureX

  • |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • BazaarBazaar””

    ”” SVN “ trunk/” “ mainline”“ dev”CVS“ HEAD”

  • “SVN”( trunk/,branches/)SVN””:

    repository/#+-trunk/#+-branches/#|+-foo/#foo|...+-tags/#+-release-X#...

    BazaarSVN

    SVN

    project/trunk

    SVN:

    repository/#+-project1/#|+-trunk/#project1|+-branches/#|+-foo/#project1foo|...|+-project2/#project2+-trunk/#project2+-branches/#project2

    BazaarBazaar( bzrinit-repo)

    Bazaar:

    project1/#project1+-trunk/#project1+-branches/#

  • +-foo/#project1foo...

    project2/#project2+-trunk/#project2+-branches/#project2

    trunk/project

    SVN:

    repository/#+-trunk/#|+-project1#project1|+-project2#project2|...|+-branches/#+-project1/#(?)|+-foo#project1'foo'+-project2/+-bar#project2'bar'

    :

    repository/#+-trunk/#|+-project1#project1|+-project2#project2|...|+-branches/#+-project1-foo/#project1'foo'+-project2-bar/#project2'bar'

    “trunk/”

    Bazaar

    1. bzrbranch/checkout/get [1]2. repository/trunk/foo foo trunk trunk foo

  • SVNSVN1””Bazaar(

    [1] : NestedTreeSupport””1 bzrcheckout

    http://bazaar-vcs.org/NestedTrees

  • ( project/branch/sub-branch/)SVNBazaarBazaar( --no-trees)()

    1:

    project/#**+joe/#Joe|+-feature1/#Joefeature1||+-broken/#feature1|+-feature2/#Joefeature2|...+barry/#Barry|...+releases/+-1.0/+-1.1.1/

    1 branches””

    :

    bzrbranchhttp://host/repository/project/branches/joe-feature-foo-bugfix-10/

    :

    bzrbranchhttp://host/project/joe/foo/bugfix-10

    repository/project/branches/:

    barry-feature-bar/barry-bugfix-10/barry-bugfix-12/joe-bugfix-10/

  • joe-bugfix-13/joe-frizban/

    Versus branches/ branches/(100)

    (”Joefoo10bar”)

    :

    bzrbranchhttp://host/project/release/1/1/1

    bzrbranchhttp://host/project/release/1/1/2

    1.1.11.1.2

  • ( dev/,merged/,experimental/)breakup:

    project/#+-trunk/#+-dev/#|+-joe-feature1#Joefeature-1|+-barry-bugfix10#bugfix10Barry|...+-merged/#|+-bugfix-12#+-abandonded/#'dead-end'

    ()

    project/dev/new-featureproject/merged/new-feature bzr pull 1HTTP bzr>=0.15 http://old/pathhttp://new/pathHTTP(SFTP)

    () BranchReference bzr BranchReferenceURLhttpsftp

    https://launchpad.net

  • //( 2006-06/,2006-07/,0.8/,0.9)””

    :

    project/#project+-trunk/#+-2006-06/#|+-feature1/#"project""feature1"|+-feature2/#"project""feature2"+-2005-05/#+-feature3/...

    “”()

    :

    project/#+-trunk/#+-releases/#|+-0.8/#0.8|+-0.9/#0.9+-0.8/#0.8|+-feature1/#0.8"feature1"|+-feature2/#"0.8feature2"+-0.9/+-feature3/#0.9"feature3"

    0.90.9 0.9 0.8/release0.8

    ()

  • ( project/joe/foo,project/barry/bar):

    project/#+-trunk/#+-joe/#Joe|+-foo/#Joe"project""foo"+-barry/+-bar/#Barry"project""bar"

    branchbranch

    Launchpad:

    repository/+-joe/#Joe|+-project1/#Joe"project1"||+-foo/#Joe"project1""foo"|+-project2/#Joe"project2"|+-bar/#Joe"project2""bar"|...|+-barry/|+-project1/#Barry"project1"|+-bug-10/#Barry"project1""bug-10"|...+-group/+-project1/+-trunk/#"project1"

    ”group”””

    ”X” Launchpad”view”“

    https://launchpad.nethttps://launchpad.net

  • :

    1. ””(:2. 13. ””

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • E

  • BazaarEBazaarEE

    E/

  • EEBazaarBazaar3:

    1E bazaar.conf locations.conf.bzr/branch/branch.confE

    1. BZR_EMAIL2. E locations.conf3. E .bzr/branch/branch.conf4. E bazaar.conf5. EMAIL6. Bazaar

    BazaarE whoami(“whoami?”):

    %bzrwhoamiJoeCool

  • ‘whoami’EEwhoami:

    %bzrwhoami"JoeCool"

    :

    %bzrwhoami--branch"JoeCool"

    bazaar.conf branch.conf

  • Eini bazaar.conf (Linux ~/.bazaar/ Windows%APPDATA%\bazaar\2.0\)EDEFAULT

    [DEFAULT]email=YourName

    iniBazaar

  • E2 locations.confE:

    [/some/branch/location]email=YourName

    E /some/branch/location bazaar.conf

  • EBazaar BZR_EMAIL EMAILEini

  • EBazaarE spamgourmet.cm

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »Bazaar »

  • FastCGIBazaarApache2.0FastCGImod_pythonBazaarHTTP1

  • HTTP /srv/example.com/www/codehttp://example.com/code/...bzr/srv/example.com/www/code/branch-one/srv/example.com/www/code/my-repo/branch-twoHTTP

  • Apache2.0

    FastCGI

    mod_fastcgihttpd.conf:

    LoadModulefastcgi_module/usr/lib/apache2/modules/mod_fastcgi.soFastCgiIpcDir/var/lib/apache2/fastcgi

    `http://example.com/code` /srv/example.com/www/codeApache:

    Alias/code/srv/example.com/www/code

    OptionsIndexes#...

    .bzr/smartURL:

    Alias/code/srv/example.com/www/code

    OptionsIndexesFollowSymLinksRewriteEngineOnRewriteBase/codeRewriteRule^(.*/|)\.bzr/smart$/srv/example.com/scripts/bzr-smart.fcgi

    #bzr-smart.fcgiDocumentRoot#AliasURLAlias/srv/example.com/scripts/bzr-smart.fcgi/srv/example.com/scripts/bzr-smart.fcgi

    OptionsExecCGISetHandlerfastcgi-script

  • FastCGI /code /.bzr/smartURLBazaarApache

    mod_rewrite mod_fastcgi

    mod_python

    httpd.confmod_python:

    LoadModulepython_module/usr/lib/apache2/modules/mod_python.so

    FastCGImod_rewrite:

    RewriteRule^(.*/|)\.bzr/smart$/srv/example.com/scripts/bzr-smart.fcgi

    :

    RewriteRule^(.*/|)\.bzr/smart$/srv/example.com/scripts/bzr-smart.py

    mod_fastcgi:

    Alias/srv/example.com/scripts/bzr-smart.py/srv/example.com/scripts/bzr-smart.py

    PythonPath"sys.path+['/srv/example.com/scripts']"AddHandlerpython-program.pyPythonHandlerbzr-smart::handler

    mod_python /code /.bzr/smartURLBazaar

    :bzrlibPATH:

    PythonPath"sys.path+['/srv/example.com/scripts']"

    http://httpd.apache.org/docs/2.0/mod/mod_rewrite.htmlhttp://www.fastcgi.com/mod_fastcgi/docs/mod_fastcgi.html

  • :

    PythonPath"['/path/to/bzr']+sys.path+['/srv/example.com/scripts']"

    mod_python

    http://www.modpython.org/

  • Bazaar

    FastCGI

    /srv/example.com/scripts/bzr-smart.fcgiApacheFastCGI:

    importfcgifrombzrlib.transport.httpimportwsgi

    smart_server_app=wsgi.make_app(root='/srv/example.com/www/code',prefix='/code/',path_var='REQUEST_URI',readonly=True,load_plugins=True,enable_logging=True)

    fcgi.WSGIServer(smart_server_app).run()

    `fcgi`http://svn.saddi.com/py-lib/trunk/fcgi.py flup

    mod_python

    /srv/example.com/scripts/bzr-smart.pyApachemod_python:

    importmodpywsgifrombzrlib.transport.httpimportwsgi

    smart_server_app=wsgi.make_app(root='/srv/example.com/www/code',prefix='/code/',path_var='REQUEST_URI',readonly=True,load_plugins=True,enable_logging=True)

    defhandler(request):

    http://www.saddi.com/software/flup/

  • """Handleasinglerequest."""wsgi_server=modpywsgi.WSGIServer(smart_server_app)returnwsgi_server.run(request)

    modpywsgihttp://dev.pocoo.org/projects/pocoo/browser/pocoo/wrappers/modpy.py pocoomodpywsgi.pybzr-smart.py(/srv/example.com/scripts/)

    http://dev.pocoo.org/projects/pocoo/

  • bzr+http://URL:

    bzrlogbzr+http://example.com/code/my-branch

    HTTP:

    bzrloghttp://example.com/code/my-branch

  • BazaarHTTPWSGIWSGIWSGI:

    `SmartWSGIApp` roottransport environdict ‘bzrlib.relpath’

    make_app root SmartWSGIApp prefix`path_var``bzrlib.relpath`(Apache)’REQUEST_URI’‘/code/’‘/.bzr/smart’‘bzrlib.relpath’‘/code/foo/bar/.bzr/smart’‘foo/bzr’‘bzrlib.relpath’

    SmartWSGIAppbzrlib.transport.http.wsgidocstrings WSGI

    bzr+http://push

    http wsgi.make_app()readonly=False .bzr/smartURL

    URL()HTTPPOSTHTTPSHTTP

    |(2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://www.python.org/dev/peps/pep-0333/http://sphinx.pocoo.org/

  • (2.2b1) »Bazaar »

  • bzrbzrlib

  • bzrlib.commands.Command cmd_foofooUI cmd_baz_import baz-importbuiltins.py

    bzrlib.commands.register_command(cmd_foo)bzr

  • version_info version_info = (0, 9, 0)version_info=(0,9,0,'dev',0)

  • bzr bzrlib/plugins ~/.bazaar/pluginsBZR_PLUGIN_PATHbzr __init__.py

  • BzrTools

    Bazaar Bazaar

    (2.2b1) »Bazaar »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »

  • 5BazaarBazaarLaunchpadBazaar

    |(2.2b1) »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) »

  • Bazaar

  • Bazaar

  • Bazaar

    helpBazaar

    Bazaar

  • ShelvingChangesFilteredviews

  • BzrToolsbzr-svn

  • Bazaar

  • EFastCGIBazaar

    |(2.2b1) »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

  • |(2.2b1) » »

  • 5Bazaar

  • Bazaar

    5trunk

  • Bazaar:

    GNU/Linux:BazaarGNU/LinuxWindows:Windows .MacOSX:MacOSX .

    http://bazaar-vcs.org/WindowsDownloadshttp://bazaar-vcs.org/MacOSXBundlehttp://bazaar-vcs.org/Downloadhttp://bazaar-vcs.org/InstallationFaq

  • Bazaar

    (E):

    $bzrwhoami"JohnDoe"

    BazaarE

    E

    $bzrwhoamiJohnDoe

  • Bazaar:

    $mkdirmyproject$cdmyproject$mkdirsubdirectory$touchtest1.txttest2.txttest3.txtsubdirectory/test4.txt

    Windows: WindowsExplorer

    Bazaar:

    $bzrinit

    Bazaar branch

    Bazaar bzradd:

    $bzraddaddedsubdirectoryaddedtest1.txtaddedtest2.txtaddedtest3.txtaddedsubdirectory/test4.txt

    :

    $bzrcommit-m"Initialimport"

    BazaarBazaar; .bzr

    http://bazaar-vcs.org/Branch

  • test1.txt:

    $bzrdiff===modifiedfile'test1.txt'---test1.txt2007-10-0817:56:14+0000+++test1.txt2007-10-0817:46:22+0000@@-0,0+1,1@@+testtesttest

    Bazaar:

    $bzrcommit-m"Addedfirstlineoftext"Committedrevision2.

  • :

    $bzrlog------------------------------------------------------------revno:2committer:JohnDoebranchnick:myprojecttimestamp:Mon2007-10-0817:56:14+0000message:Addedfirstlineoftext------------------------------------------------------------revno:1committer:JohnDoebranchnick:myprojecttimestamp:Mon2006-10-0817:46:22+0000message:Initialimport

  • sftpSFTP

    Bazaar Launchpad

    www.example.com/myproject:

    $bzrpush--create-prefixsftp://[email protected]/~/public_html/myproject2revision(s)pushed.

    Bazaar myprojectpush

    :

    $bzrbranchhttp://www.example.com/myproject

    : sftp paramiko pyCrypto http://bazaar-vcs.org/InstallationFaq

    https://launchpad.net/http://bazaar-vcs.org/InstallationFaq

  • LaunchpadLaunchpad

    Launchpad SSH

    (john.doeLaunchpad):

    $bzrpushbzr+ssh://[email protected]/~john.doe/+junk/myproject

    : +junkLaunchpad

    :

    $bzrbranchhttp://bazaar.launchpad.net/~john.doe/+junk/myproject

    https://code.launchpad.net/people/+me/+junk/myproject

    https://help.launchpad.net/CreatingYourLaunchpadAccounthttps://launchpad.net/people/+me/+editsshkeyshttps://code.launchpad.net/people/+me/+junk/myproject

  • BazaarGTK:

    $bzrbranchhttp://bazaar.launchpad.net/~bzr/bzr-gtk/trunkbzr-gtk.johnBranched292revision(s).

    Bazaarbzr-gtktrunkbzr-gtk.john

    bzr-gtkBazaar

  • :

    $bzrmergeMergingfromsavedparentlocation:http://bazaar.launchpad.net/~bzr/bzr-gtk/trunkAllchangesappliedsuccessfully.

    :

    $bzrdiff

    :

    $bzrcommit-m"Mergefrommainbranch"Committedrevision295.

  • bzr-gtk

    (mergedirective)

    mycode.patch:

    $bzrsend-omycode.patchUsingsavedparentlocation:http://bazaar.launchpad.net/~bzr/bzr-gtk/trunk

    bzr-gtkE

  • Bazaar Bazaar

    Bazaar:

    $bzrhelp

    Bazaar:

    $bzrhelpcommands

    ‘’foo’’:

    $bzrhelpfoo

    |(2.2b1) » »

    ©Copyright2009,CanonicalLtd. Sphinx0.6.5

    http://sphinx.pocoo.org/

    目次 (2.2b1)チュートリアル5分でわかるBazaarBazaar チュートリアルLaunchpadでBazaarを使う集中型ワークフローのチュートリアル

    Bazaarユーザーガイド