Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > 2b014e9d37fa1e2fe0e603da999cf179 > files > 11

bazaar-1.4.2-4mdv2009.1.i586.rpm

<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" />
<title>Mirroring Archives with Bazaar</title>
<style type="text/css">

/*
:Author: David Goodger (goodger@python.org)
:Id: $Id: html4css1.css 5196 2007-06-03 20:25:28Z wiemann $
:Copyright: This stylesheet has been placed in the public domain.

Default cascading style sheet for the HTML output of Docutils.

See http://docutils.sf.net/docs/howto/html-stylesheets.html for how to
customize this style sheet.
*/

/* used to remove borders from tables and images */
.borderless, table.borderless td, table.borderless th {
  border: 0 }

table.borderless td, table.borderless th {
  /* Override padding for "table.docutils td" with "! important".
     The right padding separates the table cells. */
  padding: 0 0.5em 0 0 ! important }

.first {
  /* Override more specific margin styles with "! important". */
  margin-top: 0 ! important }

.last, .with-subtitle {
  margin-bottom: 0 ! important }

.hidden {
  display: none }

a.toc-backref {
  text-decoration: none ;
  color: black }

blockquote.epigraph {
  margin: 2em 5em ; }

dl.docutils dd {
  margin-bottom: 0.5em }

/* Uncomment (and remove this text!) to get bold-faced definition list terms
dl.docutils dt {
  font-weight: bold }
*/

div.abstract {
  margin: 2em 5em }

div.abstract p.topic-title {
  font-weight: bold ;
  text-align: center }

div.admonition, div.attention, div.caution, div.danger, div.error,
div.hint, div.important, div.note, div.tip, div.warning {
  margin: 2em ;
  border: medium outset ;
  padding: 1em }

div.admonition p.admonition-title, div.hint p.admonition-title,
div.important p.admonition-title, div.note p.admonition-title,
div.tip p.admonition-title {
  font-weight: bold ;
  font-family: sans-serif }

div.attention p.admonition-title, div.caution p.admonition-title,
div.danger p.admonition-title, div.error p.admonition-title,
div.warning p.admonition-title {
  color: red ;
  font-weight: bold ;
  font-family: sans-serif }

/* Uncomment (and remove this text!) to get reduced vertical space in
   compound paragraphs.
div.compound .compound-first, div.compound .compound-middle {
  margin-bottom: 0.5em }

div.compound .compound-last, div.compound .compound-middle {
  margin-top: 0.5em }
*/

div.dedication {
  margin: 2em 5em ;
  text-align: center ;
  font-style: italic }

div.dedication p.topic-title {
  font-weight: bold ;
  font-style: normal }

div.figure {
  margin-left: 2em ;
  margin-right: 2em }

div.footer, div.header {
  clear: both;
  font-size: smaller }

div.line-block {
  display: block ;
  margin-top: 1em ;
  margin-bottom: 1em }

div.line-block div.line-block {
  margin-top: 0 ;
  margin-bottom: 0 ;
  margin-left: 1.5em }

div.sidebar {
  margin: 0 0 0.5em 1em ;
  border: medium outset ;
  padding: 1em ;
  background-color: #ffffee ;
  width: 40% ;
  float: right ;
  clear: right }

div.sidebar p.rubric {
  font-family: sans-serif ;
  font-size: medium }

div.system-messages {
  margin: 5em }

div.system-messages h1 {
  color: red }

div.system-message {
  border: medium outset ;
  padding: 1em }

div.system-message p.system-message-title {
  color: red ;
  font-weight: bold }

div.topic {
  margin: 2em }

h1.section-subtitle, h2.section-subtitle, h3.section-subtitle,
h4.section-subtitle, h5.section-subtitle, h6.section-subtitle {
  margin-top: 0.4em }

h1.title {
  text-align: center }

h2.subtitle {
  text-align: center }

hr.docutils {
  width: 75% }

img.align-left {
  clear: left }

img.align-right {
  clear: right }

ol.simple, ul.simple {
  margin-bottom: 1em }

ol.arabic {
  list-style: decimal }

ol.loweralpha {
  list-style: lower-alpha }

ol.upperalpha {
  list-style: upper-alpha }

ol.lowerroman {
  list-style: lower-roman }

ol.upperroman {
  list-style: upper-roman }

p.attribution {
  text-align: right ;
  margin-left: 50% }

p.caption {
  font-style: italic }

p.credits {
  font-style: italic ;
  font-size: smaller }

p.label {
  white-space: nowrap }

p.rubric {
  font-weight: bold ;
  font-size: larger ;
  color: maroon ;
  text-align: center }

p.sidebar-title {
  font-family: sans-serif ;
  font-weight: bold ;
  font-size: larger }

p.sidebar-subtitle {
  font-family: sans-serif ;
  font-weight: bold }

p.topic-title {
  font-weight: bold }

pre.address {
  margin-bottom: 0 ;
  margin-top: 0 ;
  font-family: serif ;
  font-size: 100% }

pre.literal-block, pre.doctest-block {
  margin-left: 2em ;
  margin-right: 2em }

span.classifier {
  font-family: sans-serif ;
  font-style: oblique }

span.classifier-delimiter {
  font-family: sans-serif ;
  font-weight: bold }

span.interpreted {
  font-family: sans-serif }

span.option {
  white-space: nowrap }

span.pre {
  white-space: pre }

span.problematic {
  color: red }

span.section-subtitle {
  /* font-size relative to parent (h1..h6 element) */
  font-size: 80% }

table.citation {
  border-left: solid 1px gray;
  margin-left: 1px }

table.docinfo {
  margin: 2em 4em }

table.docutils {
  margin-top: 0.5em ;
  margin-bottom: 0.5em }

table.footnote {
  border-left: solid 1px black;
  margin-left: 1px }

table.docutils td, table.docutils th,
table.docinfo td, table.docinfo th {
  padding-left: 0.5em ;
  padding-right: 0.5em ;
  vertical-align: top }

table.docutils th.field-name, table.docinfo th.docinfo-name {
  font-weight: bold ;
  text-align: left ;
  white-space: nowrap ;
  padding-left: 0 }

h1 tt.docutils, h2 tt.docutils, h3 tt.docutils,
h4 tt.docutils, h5 tt.docutils, h6 tt.docutils {
  font-size: 100% }

ul.auto-toc {
  list-style-type: none }

</style>
</head>
<body>
<div class="document" id="mirroring-archives-with-bazaar">
<h1 class="title">Mirroring Archives with Bazaar</h1>

<p>This howto covers the mirroring of archives.</p>
<p>There are three primary reasons one may want to mirror an archive. Firstly, performance
of remote archives is noticably slower than that of local archives. A local mirror
allows one to get the same performance for that archive by having a local copy.
archive which is very fast to use. Secondly a local mirror allows one to access
the data in that mirror without being connected to the net. Lastly, you need to
mirror your local archives publically to make them visible to other people.</p>
<p>In this case, I'll use myself as an example. I tend to get bogged down when I
sit at home, so often I'll drag my laptop off to the donut shop or the park.
Before I do that, I update my mirror of the archives that I care about. When I
get back home, I update the mirror of my laptop archive so that other people
can use the work that I performed.</p>
<div class="section" id="making-local-mirrors">
<h1>Making local mirrors</h1>
<p>First, lets locally mirror a remote archive. As usual, I'll rely on our friend
Tux as our target and assume his archive name is tux&#64;penguin.org--tuxpucks,
and that his archive is at <a class="reference external" href="http://tux.org/tuxpucks">http://tux.org/tuxpucks</a>. Creating the mirror is a
one step process:</p>
<pre class="literal-block">
$ baz make-archive -m http://tux.org/tuxpucks \
   /home/jdoe/archives/tuxpucks
</pre>
<p>To make this usable you need to populate it with data:</p>
<pre class="literal-block">
$ baz archive-mirror tux&#64;penguin.org--tuxpucks
</pre>
<p>At this point baz is able to use either the official archive at <a class="reference external" href="http://tux.org/tuxpucks">http://tux.org/tuxpucks</a>,
or your local copy. Baz will automatically use the most up to date copy that is available,
so if you go offline, it will use your local copy, but if you are online it will use the
copy at <a class="reference external" href="http://tux.org/tuxpucks">http://tux.org/tuxpucks</a>.</p>
<p>If you want to tell baz to use the local copy all the time, you need to edit <cite>~/.arch-params/archives/tux&#64;penguin.org--tuxpucks</cite>
and add ` priority=50` to the end of the URL line for <a class="reference external" href="http://tux.org/tuxpucks">http://tux.org/tuxpucks</a>. After doing this,
you will need to run the archive-mirror command listed above to update the mirror and make new
commits by <a class="reference external" href="mailto:tux&#64;penguin.org">tux&#64;penguin.org</a> available.</p>
<p>We've now addressed the first two reasons for making mirrors. What about the third ?</p>
</div>
<div class="section" id="publishing-your-archive">
<h1>Publishing your archive</h1>
<p>First, why would we bother? Well, if you're like a lot of other free software
developers, you probably don't have a web server running on your local machine
that the general public that has access to. That's ok, because in the arch
world, we have an answer for you: pushing your local archive remotely.</p>
<p>Lets to assume that your archive name is jdoe&#64;isp.com--tuxpucks, and that
you can sftp to a directory that is served by a webserver (say, apache). In the
case of apache, user accounts are generally able to serve documents in a
/home/$USERNAME/public_html web pages of the form
<a class="reference external" href="http://webserver.com/~username/">http://webserver.com/~username/</a>. So we'll take advantage of that here.</p>
<p>Step 1: make a mirror of your archive with no data in it, and with 'listing' files
turned on. (listing files are needed for non-WebDAV HTTP servers only).</p>
<pre class="literal-block">
$ baz make-archive -l -m jdoe&#64;isp.com--tuxpucks \
  sftp://jdoe\&#64;webserver.com/home/~jdoe/public_html/jdoe&#64;isp.com--tuxpucks
</pre>
<p>Step 2: push your current commits to it.</p>
<pre class="literal-block">
$ baz archive-mirror jdoe&#64;isp.com--tuxpucks
</pre>
<p>When you are in a source tree, you can just run</p>
<pre class="literal-block">
$ baz archive-mirror
</pre>
<p>and baz will determine the archive from the current directory.</p>
<p>Now others can use your archive. Just tell them to <cite>baz register-archive
http://webserver.com/~jdoe/jdoe&#64;isp.com--tuxpucks</cite>. They can also checkout
directly from the url: <cite>baz get http://webserver.com/~jdoe/jdoe&#64;isp.com--tuxpucks/project--branch--0</cite></p>
<p>As with local mirrors, the one on your webserver won't automatically update. To update it
you need to repeat step 2.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field"><th class="field-name">title:</th><td class="field-body"><p class="first">Mirroring Archives with Bazaar</p>
</td>
</tr>
<tr class="field"><th class="field-name">license:</th><td class="field-body"><p class="first">General Public License, V2</p>
</td>
</tr>
<tr class="field"><th class="field-name">copyright:</th><td class="field-body"><ol class="first upperalpha simple" start="3">
<li>2004, 2005 Canonical Ltd.</li>
</ol>
</td>
</tr>
<tr class="field"><th class="field-name">authors:</th><td class="field-body"><p class="first last">James Blackwell &lt;<a class="reference external" href="mailto:jblack&#64;gnuarch.org">jblack&#64;gnuarch.org</a>&gt;, Robert Collins &lt;<a class="reference external" href="mailto:robert.collins&#64;canonical.com">robert.collins&#64;canonical.com</a>&gt;</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</body>
</html>