Added: dev/buildr/1.5.0/site/rdoc/Buildr/ArchiveTask/Merge.html
==============================================================================
--- dev/buildr/1.5.0/site/rdoc/Buildr/ArchiveTask/Merge.html (added)
+++ dev/buildr/1.5.0/site/rdoc/Buildr/ArchiveTask/Merge.html Sat Sep 17 
06:23:20 2016
@@ -0,0 +1,267 @@
+<!DOCTYPE html>
+
+<html>
+<head>
+<meta charset="UTF-8">
+
+<title>class Buildr::ArchiveTask::Merge - buildr</title>
+
+<script type="text/javascript">
+  var rdoc_rel_prefix = "../../";
+</script>
+
+<script src="../../js/jquery.js"></script>
+<script src="../../js/darkfish.js"></script>
+
+<link href="../../css/fonts.css" rel="stylesheet">
+<link href="../../css/rdoc.css" rel="stylesheet">
+
+
+
+<body id="top" role="document" class="class">
+<nav role="navigation">
+  <div id="project-navigation">
+    <div id="home-section" role="region" title="Quick navigation" 
class="nav-section">
+  <h2>
+    <a href="../../index.html" rel="home">Home</a>
+  </h2>
+
+  <div id="table-of-contents-navigation">
+    <a href="../../table_of_contents.html#pages">Pages</a>
+    <a href="../../table_of_contents.html#classes">Classes</a>
+    <a href="../../table_of_contents.html#methods">Methods</a>
+  </div>
+</div>
+
+    <div id="search-section" role="search" class="project-section 
initially-hidden">
+  <form action="#" method="get" accept-charset="utf-8">
+    <div id="search-field-wrapper">
+      <input id="search-field" role="combobox" aria-label="Search"
+             aria-autocomplete="list" aria-controls="search-results"
+             type="text" name="search" placeholder="Search" spellcheck="false"
+             title="Type to search, Up and Down to navigate, Enter to load">
+    </div>
+
+    <ul id="search-results" aria-label="Search Results"
+        aria-busy="false" aria-expanded="false"
+        aria-atomic="false" class="initially-hidden"></ul>
+  </form>
+</div>
+
+  </div>
+
+  
+
+  <div id="class-metadata">
+    
+    <div id="parent-class-section" class="nav-section">
+  <h3>Parent</h3>
+
+  
+  <p class="link"><a href="../../Object.html">Object</a>
+  
+</div>
+
+    
+    
+    <!-- Method Quickref -->
+<div id="method-list-section" class="nav-section">
+  <h3>Methods</h3>
+
+  <ul class="link-list" role="directory">
+    
+    <li ><a href="#method-c-new">::new</a>
+    
+    <li ><a href="#method-i-3C-3C">#&lt;&lt;</a>
+    
+    <li ><a href="#method-i-exclude">#exclude</a>
+    
+    <li ><a href="#method-i-include">#include</a>
+    
+  </ul>
+</div>
+
+  </div>
+</nav>
+
+<main role="main" aria-labelledby="class-Buildr::ArchiveTask::Merge">
+  <h1 id="class-Buildr::ArchiveTask::Merge" class="class">
+    class Buildr::ArchiveTask::Merge
+  </h1>
+
+  <section class="description">
+    
+  </section>
+
+  
+  
+  
+  <section id="5Buntitled-5D" class="documentation-section">
+    
+
+    
+
+    
+
+    
+
+    
+     <section id="public-class-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Public Class Methods</h3>
+       </header>
+
+    
+      <div id="method-c-new" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">new</span><span
+            class="method-args">(expanders)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="new-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/archive.rb, line 256</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">initialize</span>(<span 
class="ruby-identifier">expanders</span>)
+  <span class="ruby-ivar">@expanders</span> = <span 
class="ruby-identifier">expanders</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+     <section id="public-instance-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Public Instance Methods</h3>
+       </header>
+
+    
+      <div id="method-i-3C-3C" class="method-detail method-alias">
+        
+        <div class="method-heading">
+          <span class="method-name">&lt;&lt;</span><span
+            class="method-args">(*files)</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+        </div>
+
+        
+
+        
+        <div class="aliases">
+          Alias for: <a href="Merge.html#method-i-include">include</a>
+        </div>
+        
+      </div>
+
+    
+      <div id="method-i-exclude" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">exclude</span><span
+            class="method-args">(*files)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="exclude-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/archive.rb, line 266</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">exclude</span>(<span 
class="ruby-operator">*</span><span class="ruby-identifier">files</span>)
+  <span class="ruby-ivar">@expanders</span>.<span 
class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span 
class="ruby-identifier">expander</span><span class="ruby-operator">|</span> 
<span class="ruby-identifier">expander</span>.<span 
class="ruby-identifier">exclude</span>(<span 
class="ruby-operator">*</span><span class="ruby-identifier">files</span>) }
+  <span class="ruby-keyword">self</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-include" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">include</span><span
+            class="method-args">(*files)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="include-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/archive.rb, line 260</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">include</span>(<span 
class="ruby-operator">*</span><span class="ruby-identifier">files</span>)
+  <span class="ruby-ivar">@expanders</span>.<span 
class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span 
class="ruby-identifier">expander</span><span class="ruby-operator">|</span> 
<span class="ruby-identifier">expander</span>.<span 
class="ruby-identifier">include</span>(<span 
class="ruby-operator">*</span><span class="ruby-identifier">files</span>) }
+  <span class="ruby-keyword">self</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+        <div class="aliases">
+          Also aliased as: <a href="Merge.html#method-i-3C-3C">&lt;&lt;</a>
+        </div>
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+  </section>
+</main>
+
+
+<footer id="validator-badges" role="contentinfo">
+  <p><a href="http://validator.w3.org/check/referer";>Validate</a>
+  <p>Generated by <a href="http://docs.seattlerb.org/rdoc/";>RDoc</a> 4.2.2.
+  <p>Based on <a 
href="http://deveiate.org/projects/Darkfish-RDoc/";>Darkfish</a> by <a 
href="http://deveiate.org";>Michael Granger</a>.
+</footer>
+

Added: dev/buildr/1.5.0/site/rdoc/Buildr/ArchiveTask/ZipEntryData.html
==============================================================================
--- dev/buildr/1.5.0/site/rdoc/Buildr/ArchiveTask/ZipEntryData.html (added)
+++ dev/buildr/1.5.0/site/rdoc/Buildr/ArchiveTask/ZipEntryData.html Sat Sep 17 
06:23:20 2016
@@ -0,0 +1,232 @@
+<!DOCTYPE html>
+
+<html>
+<head>
+<meta charset="UTF-8">
+
+<title>class Buildr::ArchiveTask::ZipEntryData - buildr</title>
+
+<script type="text/javascript">
+  var rdoc_rel_prefix = "../../";
+</script>
+
+<script src="../../js/jquery.js"></script>
+<script src="../../js/darkfish.js"></script>
+
+<link href="../../css/fonts.css" rel="stylesheet">
+<link href="../../css/rdoc.css" rel="stylesheet">
+
+
+
+<body id="top" role="document" class="class">
+<nav role="navigation">
+  <div id="project-navigation">
+    <div id="home-section" role="region" title="Quick navigation" 
class="nav-section">
+  <h2>
+    <a href="../../index.html" rel="home">Home</a>
+  </h2>
+
+  <div id="table-of-contents-navigation">
+    <a href="../../table_of_contents.html#pages">Pages</a>
+    <a href="../../table_of_contents.html#classes">Classes</a>
+    <a href="../../table_of_contents.html#methods">Methods</a>
+  </div>
+</div>
+
+    <div id="search-section" role="search" class="project-section 
initially-hidden">
+  <form action="#" method="get" accept-charset="utf-8">
+    <div id="search-field-wrapper">
+      <input id="search-field" role="combobox" aria-label="Search"
+             aria-autocomplete="list" aria-controls="search-results"
+             type="text" name="search" placeholder="Search" spellcheck="false"
+             title="Type to search, Up and Down to navigate, Enter to load">
+    </div>
+
+    <ul id="search-results" aria-label="Search Results"
+        aria-busy="false" aria-expanded="false"
+        aria-atomic="false" class="initially-hidden"></ul>
+  </form>
+</div>
+
+  </div>
+
+  
+
+  <div id="class-metadata">
+    
+    <div id="parent-class-section" class="nav-section">
+  <h3>Parent</h3>
+
+  
+  <p class="link"><a href="../../Object.html">Object</a>
+  
+</div>
+
+    
+    
+    <!-- Method Quickref -->
+<div id="method-list-section" class="nav-section">
+  <h3>Methods</h3>
+
+  <ul class="link-list" role="directory">
+    
+    <li ><a href="#method-c-new">::new</a>
+    
+    <li ><a href="#method-i-call">#call</a>
+    
+    <li ><a href="#method-i-mode">#mode</a>
+    
+  </ul>
+</div>
+
+  </div>
+</nav>
+
+<main role="main" aria-labelledby="class-Buildr::ArchiveTask::ZipEntryData">
+  <h1 id="class-Buildr::ArchiveTask::ZipEntryData" class="class">
+    class Buildr::ArchiveTask::ZipEntryData
+  </h1>
+
+  <section class="description">
+    
+  </section>
+
+  
+  
+  
+  <section id="5Buntitled-5D" class="documentation-section">
+    
+
+    
+
+    
+
+    
+
+    
+     <section id="public-class-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Public Class Methods</h3>
+       </header>
+
+    
+      <div id="method-c-new" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">new</span><span
+            class="method-args">(zipfile, entry)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="new-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/archive.rb, line 310</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">initialize</span>(<span 
class="ruby-identifier">zipfile</span>, <span 
class="ruby-identifier">entry</span>)
+  <span class="ruby-ivar">@zipfile</span> = <span 
class="ruby-identifier">zipfile</span>
+  <span class="ruby-ivar">@entry</span> = <span 
class="ruby-identifier">entry</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+     <section id="public-instance-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Public Instance Methods</h3>
+       </header>
+
+    
+      <div id="method-i-call" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">call</span><span
+            class="method-args">(output)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="call-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/archive.rb, line 315</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">call</span>(<span class="ruby-identifier">output</span>)
+  <span class="ruby-identifier">output</span>.<span 
class="ruby-identifier">write</span> <span 
class="ruby-ivar">@zipfile</span>.<span 
class="ruby-identifier">read</span>(<span class="ruby-ivar">@entry</span>)
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-mode" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">mode</span><span
+            class="method-args">()</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="mode-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/archive.rb, line 319</span>
+<span class="ruby-keyword">def</span> <span class="ruby-identifier">mode</span>
+  <span class="ruby-ivar">@entry</span>.<span 
class="ruby-identifier">unix_perms</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+  </section>
+</main>
+
+
+<footer id="validator-badges" role="contentinfo">
+  <p><a href="http://validator.w3.org/check/referer";>Validate</a>
+  <p>Generated by <a href="http://docs.seattlerb.org/rdoc/";>RDoc</a> 4.2.2.
+  <p>Based on <a 
href="http://deveiate.org/projects/Darkfish-RDoc/";>Darkfish</a> by <a 
href="http://deveiate.org";>Michael Granger</a>.
+</footer>
+

Added: dev/buildr/1.5.0/site/rdoc/Buildr/Artifact.html
==============================================================================
--- dev/buildr/1.5.0/site/rdoc/Buildr/Artifact.html (added)
+++ dev/buildr/1.5.0/site/rdoc/Buildr/Artifact.html Sat Sep 17 06:23:20 2016
@@ -0,0 +1,900 @@
+<!DOCTYPE html>
+
+<html>
+<head>
+<meta charset="UTF-8">
+
+<title>class Buildr::Artifact - buildr</title>
+
+<script type="text/javascript">
+  var rdoc_rel_prefix = "../";
+</script>
+
+<script src="../js/jquery.js"></script>
+<script src="../js/darkfish.js"></script>
+
+<link href="../css/fonts.css" rel="stylesheet">
+<link href="../css/rdoc.css" rel="stylesheet">
+
+
+
+<body id="top" role="document" class="class">
+<nav role="navigation">
+  <div id="project-navigation">
+    <div id="home-section" role="region" title="Quick navigation" 
class="nav-section">
+  <h2>
+    <a href="../index.html" rel="home">Home</a>
+  </h2>
+
+  <div id="table-of-contents-navigation">
+    <a href="../table_of_contents.html#pages">Pages</a>
+    <a href="../table_of_contents.html#classes">Classes</a>
+    <a href="../table_of_contents.html#methods">Methods</a>
+  </div>
+</div>
+
+    <div id="search-section" role="search" class="project-section 
initially-hidden">
+  <form action="#" method="get" accept-charset="utf-8">
+    <div id="search-field-wrapper">
+      <input id="search-field" role="combobox" aria-label="Search"
+             aria-autocomplete="list" aria-controls="search-results"
+             type="text" name="search" placeholder="Search" spellcheck="false"
+             title="Type to search, Up and Down to navigate, Enter to load">
+    </div>
+
+    <ul id="search-results" aria-label="Search Results"
+        aria-busy="false" aria-expanded="false"
+        aria-atomic="false" class="initially-hidden"></ul>
+  </form>
+</div>
+
+  </div>
+
+  
+
+  <div id="class-metadata">
+    
+    <div id="parent-class-section" class="nav-section">
+  <h3>Parent</h3>
+
+  
+  <p class="link"><a href="../Rake/FileTask.html">Rake::FileTask</a>
+  
+</div>
+
+    <div id="includes-section" class="nav-section">
+  <h3>Included Modules</h3>
+
+  <ul class="link-list">
+  
+  
+    <li><a class="include" 
href="ActsAsArtifact.html">Buildr::ActsAsArtifact</a>
+  
+  
+  
+    <li><a class="include" href="../Buildr.html">Buildr</a>
+  
+  
+  </ul>
+</div>
+
+    
+    <!-- Method Quickref -->
+<div id="method-list-section" class="nav-section">
+  <h3>Methods</h3>
+
+  <ul class="link-list" role="directory">
+    
+    <li ><a href="#method-c-hash_to_file_name">::hash_to_file_name</a>
+    
+    <li ><a href="#method-c-list">::list</a>
+    
+    <li ><a href="#method-c-lookup">::lookup</a>
+    
+    <li ><a href="#method-c-needed-3F">::needed?</a>
+    
+    <li ><a href="#method-c-register">::register</a>
+    
+    <li ><a href="#method-c-to_hash">::to_hash</a>
+    
+    <li ><a href="#method-c-to_spec">::to_spec</a>
+    
+    <li ><a href="#method-i-content">#content</a>
+    
+    <li ><a 
href="#method-i-current_snapshot_repo_url">#current_snapshot_repo_url</a>
+    
+    <li ><a href="#method-i-download">#download</a>
+    
+    <li ><a href="#method-i-download_m2_snapshot">#download_m2_snapshot</a>
+    
+    <li ><a href="#method-i-fail_download">#fail_download</a>
+    
+    <li ><a href="#method-i-from">#from</a>
+    
+    <li ><a href="#method-i-has_content-3F">#has_content?</a>
+    
+    <li class="calls-super" ><a href="#method-i-needed-3F">#needed?</a>
+    
+  </ul>
+</div>
+
+  </div>
+</nav>
+
+<main role="main" aria-labelledby="class-Buildr::Artifact">
+  <h1 id="class-Buildr::Artifact" class="class">
+    class Buildr::Artifact
+  </h1>
+
+  <section class="description">
+    
+<p>A file task referencing an artifact in the local repository.</p>
+
+<p>This task includes all the artifact attributes (group, id, version, etc).
+It points to the artifact&#39;s path in the local repository. When invoked,
+it will download the artifact into the local repository if the artifact
+does not already exist.</p>
+
+<p>Note: You can enhance this task to create the artifact yourself, e.g.
+download it from a site that doesn&#39;t have a remote repository
+structure, copy it from a different disk, etc.</p>
+
+  </section>
+
+  
+  
+  
+  <section id="5Buntitled-5D" class="documentation-section">
+    
+
+    
+
+    
+    <section class="constants-list">
+      <header>
+        <h3>Constants</h3>
+      </header>
+      <dl>
+      
+        <dt id="DEFAULT_TYPE">DEFAULT_TYPE
+        
+        <dd><p>The default artifact type.</p>
+        
+      
+      </dl>
+    </section>
+    
+
+    
+
+    
+     <section id="public-class-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Public Class Methods</h3>
+       </header>
+
+    
+      <div id="method-c-hash_to_file_name" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            hash_to_file_name(spec_hash) &rarr; file_name
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Convert a hash spec to a file name.</p>
+          
+          
+
+          
+          <div class="method-source-code" id="hash_to_file_name-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 376</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">hash_to_file_name</span>(<span 
class="ruby-identifier">hash</span>)
+  <span class="ruby-identifier">version</span> = <span 
class="ruby-node">&quot;-#{hash[:version]}&quot;</span> <span 
class="ruby-keyword">if</span> <span class="ruby-identifier">hash</span>[<span 
class="ruby-value">:version</span>]
+  <span class="ruby-identifier">classifier</span> = <span 
class="ruby-node">&quot;-#{hash[:classifier]}&quot;</span> <span 
class="ruby-keyword">if</span> <span class="ruby-identifier">hash</span>[<span 
class="ruby-value">:classifier</span>]
+  <span 
class="ruby-node">&quot;#{hash[:id]}#{version}#{classifier}.#{extract_type(hash[:type])
 || DEFAULT_TYPE}&quot;</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-c-list" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            list &rarr; specs
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Returns an array of specs for all the registered artifacts. 
(Anything
+created from artifact, or package).</p>
+          
+          
+
+          
+          <div class="method-source-code" id="list-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 307</span>
+<span class="ruby-keyword">def</span> <span class="ruby-identifier">list</span>
+  <span class="ruby-ivar">@artifacts</span> <span 
class="ruby-operator">||=</span> {}
+  <span class="ruby-ivar">@artifacts</span>.<span 
class="ruby-identifier">keys</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-c-lookup" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            lookup(spec) &rarr; Artifact
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Lookup a previously registered artifact task based on its 
specification
+(String or <a href="../Hash.html">Hash</a>).</p>
+          
+          
+
+          
+          <div class="method-source-code" id="lookup-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 298</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">lookup</span>(<span class="ruby-identifier">spec</span>)
+  <span class="ruby-ivar">@artifacts</span> <span 
class="ruby-operator">||=</span> {}
+  <span class="ruby-ivar">@artifacts</span>[<span 
class="ruby-identifier">to_spec</span>(<span 
class="ruby-identifier">spec</span>)]
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-c-needed-3F" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">needed?</span><span
+            class="method-args">()</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          <p>Force overwriting target since we don&#39;t have source file to 
check for
+timestamp modification</p>
+          
+          
+
+          
+          <div class="method-source-code" id="needed-3F-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 444</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">needed?</span>
+  <span class="ruby-keyword">true</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-c-register" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            register(artifacts) &rarr; artifacts
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Register an artifact task(s) for later lookup (see lookup).</p>
+          
+          
+
+          
+          <div class="method-source-code" id="register-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 316</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">register</span>(<span 
class="ruby-operator">*</span><span class="ruby-identifier">tasks</span>)
+  <span class="ruby-ivar">@artifacts</span> <span 
class="ruby-operator">||=</span> {}
+  <span class="ruby-identifier">fail</span> <span class="ruby-string">&#39;You 
can only register an artifact task, one of the arguments is not a Task that 
responds to to_spec&#39;</span> <span class="ruby-keyword">unless</span>
+    <span class="ruby-identifier">tasks</span>.<span 
class="ruby-identifier">all?</span> { <span class="ruby-operator">|</span><span 
class="ruby-identifier">task</span><span class="ruby-operator">|</span> <span 
class="ruby-identifier">task</span>.<span 
class="ruby-identifier">respond_to?</span>(<span 
class="ruby-value">:to_spec</span>) <span 
class="ruby-operator">&amp;&amp;</span> <span 
class="ruby-identifier">task</span>.<span 
class="ruby-identifier">respond_to?</span>(<span 
class="ruby-value">:invoke</span>) }
+  <span class="ruby-identifier">tasks</span>.<span 
class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span 
class="ruby-identifier">task</span><span class="ruby-operator">|</span> <span 
class="ruby-ivar">@artifacts</span>[<span 
class="ruby-identifier">task</span>.<span 
class="ruby-identifier">to_spec</span>] = <span 
class="ruby-identifier">task</span> }
+  <span class="ruby-identifier">tasks</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-c-to_hash" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            to_hash(spec_hash) &rarr; spec_hash
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            to_hash(spec_string) &rarr; spec_hash
+          </span>
+          
+        </div>
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            to_hash(artifact) &rarr; spec_hash
+          </span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Turn a spec into a hash. This method accepts a String, <a
+href="../Hash.html">Hash</a> or any object that responds to the method
+to_spec. There are several reasons to use this method:</p>
+<ul><li>
+<p>You can pass anything that could possibly be a spec, and get a hash.</p>
+</li><li>
+<p>It will check that the spec includes the group identifier, artifact
+identifier and version number and set the file type, if missing.</p>
+</li><li>
+<p>It will always return a new specs hash.</p>
+</li></ul>
+          
+          
+
+          
+          <div class="method-source-code" id="to_hash-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 335</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">to_hash</span>(<span 
class="ruby-identifier">spec</span>)
+  <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">spec</span>.<span 
class="ruby-identifier">respond_to?</span>(<span 
class="ruby-value">:to_spec</span>)
+    <span class="ruby-identifier">to_hash</span> <span 
class="ruby-identifier">spec</span>.<span class="ruby-identifier">to_spec</span>
+  <span class="ruby-keyword">elsif</span> <span 
class="ruby-constant">Hash</span> <span class="ruby-operator">===</span> <span 
class="ruby-identifier">spec</span>
+    <span class="ruby-identifier">rake_check_options</span> <span 
class="ruby-identifier">spec</span>, <span class="ruby-value">:id</span>, <span 
class="ruby-value">:group</span>, <span class="ruby-value">:type</span>, <span 
class="ruby-value">:classifier</span>, <span 
class="ruby-value">:version</span>, <span class="ruby-value">:scope</span>
+    <span class="ruby-comment"># Sanitize the hash and check it&#39;s 
valid.</span>
+    <span class="ruby-identifier">spec</span> = <span 
class="ruby-constant">ARTIFACT_ATTRIBUTES</span>.<span 
class="ruby-identifier">inject</span>({}) { <span 
class="ruby-operator">|</span><span class="ruby-identifier">h</span>, <span 
class="ruby-identifier">k</span><span class="ruby-operator">|</span> <span 
class="ruby-identifier">h</span>[<span class="ruby-identifier">k</span>] = 
<span class="ruby-identifier">spec</span>[<span 
class="ruby-identifier">k</span>].<span class="ruby-identifier">to_s</span> 
<span class="ruby-keyword">if</span> <span 
class="ruby-identifier">spec</span>[<span class="ruby-identifier">k</span>] ; 
<span class="ruby-identifier">h</span> }
+    <span class="ruby-identifier">fail</span> <span 
class="ruby-node">&quot;Missing group identifier for 
#{spec.inspect}&quot;</span> <span class="ruby-keyword">unless</span> <span 
class="ruby-identifier">spec</span>[<span class="ruby-value">:group</span>]
+    <span class="ruby-identifier">fail</span> <span 
class="ruby-node">&quot;Missing artifact identifier for 
#{spec.inspect}&quot;</span> <span class="ruby-keyword">unless</span> <span 
class="ruby-identifier">spec</span>[<span class="ruby-value">:id</span>]
+    <span class="ruby-identifier">fail</span> <span 
class="ruby-node">&quot;Missing version for #{spec.inspect}&quot;</span> <span 
class="ruby-keyword">unless</span> <span 
class="ruby-identifier">spec</span>[<span class="ruby-value">:version</span>]
+    <span class="ruby-identifier">spec</span>[<span 
class="ruby-value">:type</span>] = (<span 
class="ruby-identifier">spec</span>[<span class="ruby-value">:type</span>] 
<span class="ruby-operator">||</span> <span 
class="ruby-constant">DEFAULT_TYPE</span>).<span 
class="ruby-identifier">to_sym</span>
+    <span class="ruby-identifier">spec</span>
+  <span class="ruby-keyword">elsif</span> <span 
class="ruby-constant">String</span> <span class="ruby-operator">===</span> 
<span class="ruby-identifier">spec</span>
+    <span class="ruby-identifier">group</span>, <span 
class="ruby-identifier">id</span>, <span class="ruby-identifier">type</span>, 
<span class="ruby-identifier">version</span>, <span 
class="ruby-operator">*</span><span class="ruby-identifier">rest</span> = <span 
class="ruby-identifier">spec</span>.<span 
class="ruby-identifier">split</span>(<span 
class="ruby-string">&#39;:&#39;</span>).<span 
class="ruby-identifier">map</span> { <span class="ruby-operator">|</span><span 
class="ruby-identifier">part</span><span class="ruby-operator">|</span> <span 
class="ruby-identifier">part</span>.<span class="ruby-identifier">empty?</span> 
<span class="ruby-operator">?</span> <span class="ruby-keyword">nil</span> 
<span class="ruby-operator">:</span> <span class="ruby-identifier">part</span> }
+    <span class="ruby-keyword">unless</span> <span 
class="ruby-identifier">rest</span>.<span class="ruby-identifier">empty?</span>
+      <span class="ruby-comment"># Optional classifier comes before 
version.</span>
+      <span class="ruby-identifier">classifier</span>, <span 
class="ruby-identifier">version</span> = <span 
class="ruby-identifier">version</span>, <span 
class="ruby-identifier">rest</span>.<span class="ruby-identifier">shift</span>
+      <span class="ruby-identifier">fail</span> <span 
class="ruby-node">&quot;Expecting &lt;group:id:type:version&gt; or 
&lt;group:id:type:classifier:version&gt;, found &lt;#{spec}&gt;&quot;</span> 
<span class="ruby-keyword">unless</span> <span 
class="ruby-identifier">rest</span>.<span class="ruby-identifier">empty?</span>
+    <span class="ruby-keyword">end</span>
+    <span class="ruby-identifier">to_hash</span> <span 
class="ruby-value">:group=</span><span class="ruby-operator">&gt;</span><span 
class="ruby-identifier">group</span>, <span class="ruby-value">:id=</span><span 
class="ruby-operator">&gt;</span><span class="ruby-identifier">id</span>, <span 
class="ruby-value">:type=</span><span class="ruby-operator">&gt;</span><span 
class="ruby-identifier">type</span>, <span 
class="ruby-value">:version=</span><span class="ruby-operator">&gt;</span><span 
class="ruby-identifier">version</span>, <span 
class="ruby-value">:classifier=</span><span 
class="ruby-operator">&gt;</span><span class="ruby-identifier">classifier</span>
+  <span class="ruby-keyword">else</span>
+    <span class="ruby-identifier">fail</span> <span 
class="ruby-string">&#39;Expecting a String, Hash or object that responds to 
to_spec&#39;</span>
+  <span class="ruby-keyword">end</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-c-to_spec" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            to_spec(spec_hash) &rarr; spec_string
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Convert a hash back to a spec string. This method accepts a 
string, hash or
+any object that responds to to_spec.</p>
+          
+          
+
+          
+          <div class="method-source-code" id="to_spec-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 365</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">to_spec</span>(<span 
class="ruby-identifier">hash</span>)
+  <span class="ruby-identifier">hash</span> = <span 
class="ruby-identifier">to_hash</span>(<span 
class="ruby-identifier">hash</span>) <span class="ruby-keyword">unless</span> 
<span class="ruby-constant">Hash</span> <span class="ruby-operator">===</span> 
<span class="ruby-identifier">hash</span>
+  <span class="ruby-identifier">version</span> = <span 
class="ruby-node">&quot;:#{hash[:version]}&quot;</span> <span 
class="ruby-keyword">if</span> <span class="ruby-identifier">hash</span>[<span 
class="ruby-value">:version</span>]
+  <span class="ruby-identifier">classifier</span> = <span 
class="ruby-node">&quot;:#{hash[:classifier]}&quot;</span> <span 
class="ruby-keyword">if</span> <span class="ruby-identifier">hash</span>[<span 
class="ruby-value">:classifier</span>]
+  <span class="ruby-node">&quot;#{hash[:group]}:#{hash[:id]}:#{hash[:type] || 
DEFAULT_TYPE}#{classifier}#{version}&quot;</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+     <section id="public-instance-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Public Instance Methods</h3>
+       </header>
+
+    
+      <div id="method-i-content" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            content(string) &rarr; self
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            content(Proc) &rarr; self
+          </span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Use this when you want to install or upload an artifact from a 
given
+content, for example:</p>
+
+<pre>readme = 
artifact(&#39;com.example:readme:txt:1.0&#39;).content(&lt;&lt;-EOF
+  Please visit our website at http://example.com/readme
+&lt;&lt;EOF
+install readme</pre>
+
+<p>If the argument is a Proc the it will be called when the artifact is
+written out. If the result is not a proc and not a string, it will be
+converted to a string using to_s</p>
+          
+          
+
+          
+          <div class="method-source-code" id="content-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 430</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">content</span>(<span 
class="ruby-identifier">string</span> = <span class="ruby-keyword">nil</span>)
+  <span class="ruby-keyword">unless</span> <span 
class="ruby-identifier">string</span>
+    <span class="ruby-ivar">@content</span> = <span 
class="ruby-ivar">@content</span>.<span class="ruby-identifier">call</span> 
<span class="ruby-keyword">if</span> <span 
class="ruby-ivar">@content</span>.<span 
class="ruby-identifier">is_a?</span>(<span class="ruby-constant">Proc</span>)
+    <span class="ruby-keyword">return</span> <span 
class="ruby-ivar">@content</span>
+  <span class="ruby-keyword">end</span>
+
+  <span class="ruby-keyword">unless</span> <span 
class="ruby-ivar">@content</span>
+    <span class="ruby-identifier">enhance</span> <span 
class="ruby-keyword">do</span>
+      <span class="ruby-identifier">write</span> <span 
class="ruby-identifier">name</span>, <span 
class="ruby-keyword">self</span>.<span class="ruby-identifier">content</span>
+    <span class="ruby-keyword">end</span>
+
+    <span class="ruby-keyword">class</span> <span 
class="ruby-operator">&lt;&lt;</span> <span class="ruby-keyword">self</span>
+      <span class="ruby-comment"># Force overwriting target since we don&#39;t 
have source file</span>
+      <span class="ruby-comment"># to check for timestamp modification</span>
+      <span class="ruby-keyword">def</span> <span 
class="ruby-identifier">needed?</span>
+        <span class="ruby-keyword">true</span>
+      <span class="ruby-keyword">end</span>
+    <span class="ruby-keyword">end</span>
+  <span class="ruby-keyword">end</span>
+  <span class="ruby-ivar">@content</span> = <span 
class="ruby-identifier">string</span>
+  <span class="ruby-identifier">pom</span>.<span 
class="ruby-identifier">content</span> <span 
class="ruby-identifier">pom_xml</span> <span class="ruby-keyword">unless</span> 
<span class="ruby-identifier">pom</span> <span class="ruby-operator">==</span> 
<span class="ruby-keyword">self</span> <span class="ruby-operator">||</span> 
<span class="ruby-identifier">pom</span>.<span 
class="ruby-identifier">has_content?</span>
+  <span class="ruby-keyword">self</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-from" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            from(path) &rarr; self
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Use this when you want to install or upload an artifact from a 
given file,
+for example:</p>
+
+<pre class="ruby"><span class="ruby-identifier">test</span> = <span 
class="ruby-identifier">artifact</span>(<span 
class="ruby-string">&#39;group:id:jar:1.0&#39;</span>).<span 
class="ruby-identifier">from</span>(<span 
class="ruby-string">&#39;test.jar&#39;</span>)
+<span class="ruby-identifier">install</span> <span 
class="ruby-identifier">test</span>
+</pre>
+
+<p>See also Buildr#install and Buildr#upload.</p>
+          
+          
+
+          
+          <div class="method-source-code" id="from-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 408</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">from</span>(<span class="ruby-identifier">path</span>)
+  <span class="ruby-ivar">@from</span> = <span 
class="ruby-identifier">path</span>.<span 
class="ruby-identifier">is_a?</span>(<span 
class="ruby-constant">Rake</span><span class="ruby-operator">::</span><span 
class="ruby-constant">Task</span>) <span class="ruby-operator">?</span> <span 
class="ruby-identifier">path</span> <span class="ruby-operator">:</span> <span 
class="ruby-constant">File</span>.<span 
class="ruby-identifier">expand_path</span>(<span 
class="ruby-identifier">path</span>.<span class="ruby-identifier">to_s</span>)
+  <span class="ruby-identifier">enhance</span> [<span 
class="ruby-ivar">@from</span>] <span class="ruby-keyword">do</span>
+    <span class="ruby-identifier">mkpath</span> <span 
class="ruby-constant">File</span>.<span 
class="ruby-identifier">dirname</span>(<span 
class="ruby-identifier">name</span>)
+    <span class="ruby-identifier">cp</span> <span 
class="ruby-ivar">@from</span>.<span class="ruby-identifier">to_s</span>, <span 
class="ruby-identifier">name</span>
+  <span class="ruby-keyword">end</span>
+  <span class="ruby-identifier">pom</span>.<span 
class="ruby-identifier">content</span> <span 
class="ruby-identifier">pom_xml</span> <span class="ruby-keyword">unless</span> 
<span class="ruby-identifier">pom</span> <span class="ruby-operator">==</span> 
<span class="ruby-keyword">self</span> <span class="ruby-operator">||</span> 
<span class="ruby-identifier">pom</span>.<span 
class="ruby-identifier">has_content?</span>
+  <span class="ruby-keyword">self</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+     <section id="protected-instance-5Buntitled-5D-method-details" 
class="method-section">
+       <header>
+         <h3>Protected Instance Methods</h3>
+       </header>
+
+    
+      <div id="method-i-current_snapshot_repo_url" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">current_snapshot_repo_url</span><span
+            class="method-args">(repo_url)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" 
id="current_snapshot_repo_url-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 512</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">current_snapshot_repo_url</span>(<span 
class="ruby-identifier">repo_url</span>)
+  <span class="ruby-keyword">begin</span>
+    <span class="ruby-identifier">metadata_path</span> = <span 
class="ruby-node">&quot;#{group_path}/#{id}/#{version}/maven-metadata.xml&quot;</span>
+    <span class="ruby-identifier">metadata_xml</span> = <span 
class="ruby-constant">StringIO</span>.<span class="ruby-identifier">new</span>
+    <span class="ruby-constant">URI</span>.<span 
class="ruby-identifier">download</span> <span 
class="ruby-identifier">repo_url</span> <span class="ruby-operator">+</span> 
<span class="ruby-identifier">metadata_path</span>, <span 
class="ruby-identifier">metadata_xml</span>
+    <span class="ruby-identifier">metadata</span> = <span 
class="ruby-constant">REXML</span><span class="ruby-operator">::</span><span 
class="ruby-constant">Document</span>.<span 
class="ruby-identifier">new</span>(<span 
class="ruby-identifier">metadata_xml</span>.<span 
class="ruby-identifier">string</span>).<span class="ruby-identifier">root</span>
+    <span class="ruby-identifier">timestamp</span> = <span 
class="ruby-constant">REXML</span><span class="ruby-operator">::</span><span 
class="ruby-constant">XPath</span>.<span 
class="ruby-identifier">first</span>(<span 
class="ruby-identifier">metadata</span>, <span 
class="ruby-string">&#39;//timestamp&#39;</span>)
+    <span class="ruby-identifier">build_number</span> = <span 
class="ruby-constant">REXML</span><span class="ruby-operator">::</span><span 
class="ruby-constant">XPath</span>.<span 
class="ruby-identifier">first</span>(<span 
class="ruby-identifier">metadata</span>, <span 
class="ruby-string">&#39;//buildNumber&#39;</span>)
+    <span class="ruby-identifier">error</span> <span 
class="ruby-node">&quot;No timestamp provided for the snapshot 
#{to_spec}&quot;</span> <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">timestamp</span>.<span 
class="ruby-identifier">nil?</span>
+    <span class="ruby-identifier">error</span> <span 
class="ruby-node">&quot;No build number provided for the snapshot 
#{to_spec}&quot;</span> <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">build_number</span>.<span 
class="ruby-identifier">nil?</span>
+    <span class="ruby-keyword">return</span> <span 
class="ruby-keyword">nil</span> <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">timestamp</span>.<span 
class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span 
class="ruby-identifier">build_number</span>.<span 
class="ruby-identifier">nil?</span>
+    <span class="ruby-identifier">snapshot_of</span> = <span 
class="ruby-identifier">version</span>[<span class="ruby-value">0</span>, <span 
class="ruby-identifier">version</span>.<span 
class="ruby-identifier">size</span> <span class="ruby-operator">-</span> <span 
class="ruby-value">9</span>]
+    <span class="ruby-identifier">classifier_snippet</span> = (<span 
class="ruby-identifier">classifier</span> <span class="ruby-operator">!=</span> 
<span class="ruby-keyword">nil</span>) <span class="ruby-operator">?</span> 
<span class="ruby-node">&quot;-#{classifier}&quot;</span> <span 
class="ruby-operator">:</span> <span class="ruby-string">&quot;&quot;</span>
+    <span class="ruby-identifier">repo_url</span> <span 
class="ruby-operator">+</span> <span 
class="ruby-node">&quot;#{group_path}/#{id}/#{version}/#{id}-#{snapshot_of}-#{timestamp.text}-#{build_number.text}#{classifier_snippet}.#{type}&quot;</span>
+  <span class="ruby-keyword">rescue</span> <span 
class="ruby-constant">URI</span><span class="ruby-operator">::</span><span 
class="ruby-constant">NotFoundError</span>
+    <span class="ruby-keyword">nil</span>
+  <span class="ruby-keyword">end</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-download" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            download
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Downloads an artifact from one of the remote repositories, and 
stores it in
+the local repository. Raises an exception if the artifact is not found.</p>
+
+<p>This method attempts to download the artifact from each repository in the
+order in which they are returned from remote, until successful.</p>
+          
+          
+
+          
+          <div class="method-source-code" id="download-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 468</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">download</span>
+  <span class="ruby-identifier">trace</span> <span 
class="ruby-node">&quot;Downloading #{to_spec}&quot;</span>
+  <span class="ruby-identifier">remote</span> = <span 
class="ruby-constant">Buildr</span>.<span 
class="ruby-identifier">repositories</span>.<span 
class="ruby-identifier">remote_uri</span>
+  <span class="ruby-identifier">remote</span> = <span 
class="ruby-identifier">remote</span>.<span class="ruby-identifier">each</span> 
{ <span class="ruby-operator">|</span><span 
class="ruby-identifier">repo_url</span><span class="ruby-operator">|</span> 
<span class="ruby-identifier">repo_url</span>.<span 
class="ruby-identifier">path</span> <span class="ruby-operator">+=</span> <span 
class="ruby-string">&#39;/&#39;</span> <span class="ruby-keyword">unless</span> 
<span class="ruby-identifier">repo_url</span>.<span 
class="ruby-identifier">path</span>[<span class="ruby-value">-1</span>] <span 
class="ruby-operator">==</span> <span class="ruby-string">&#39;/&#39;</span> }
+  <span class="ruby-identifier">fail</span> <span 
class="ruby-node">&quot;Unable to download #{to_spec}. No remote repositories 
defined.&quot;</span> <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">remote</span>.<span 
class="ruby-identifier">empty?</span>
+  <span class="ruby-identifier">exact_success</span> = <span 
class="ruby-identifier">remote</span>.<span class="ruby-identifier">find</span> 
<span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span 
class="ruby-identifier">repo_url</span><span class="ruby-operator">|</span>
+    <span class="ruby-keyword">begin</span>
+      <span class="ruby-identifier">path</span> = <span 
class="ruby-node">&quot;#{group_path}/#{id}/#{version}/#{File.basename(name)}&quot;</span>
+      <span class="ruby-identifier">download_artifact</span>(<span 
class="ruby-identifier">repo_url</span> <span class="ruby-operator">+</span> 
<span class="ruby-identifier">path</span>)
+      <span class="ruby-keyword">true</span>
+    <span class="ruby-keyword">rescue</span> <span 
class="ruby-constant">URI</span><span class="ruby-operator">::</span><span 
class="ruby-constant">NotFoundError</span>
+      <span class="ruby-keyword">false</span>
+    <span class="ruby-keyword">rescue</span> <span 
class="ruby-constant">Exception</span>=<span 
class="ruby-operator">&gt;</span><span class="ruby-identifier">error</span>
+      <span class="ruby-identifier">info</span> <span 
class="ruby-identifier">error</span>
+      <span class="ruby-identifier">trace</span> <span 
class="ruby-identifier">error</span>.<span 
class="ruby-identifier">backtrace</span>.<span 
class="ruby-identifier">join</span>(<span 
class="ruby-string">&quot;\n&quot;</span>)
+      <span class="ruby-keyword">false</span>
+    <span class="ruby-keyword">end</span>
+  <span class="ruby-keyword">end</span>
+
+  <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">exact_success</span>
+    <span class="ruby-keyword">return</span>
+  <span class="ruby-keyword">elsif</span> <span 
class="ruby-identifier">snapshot?</span>
+    <span class="ruby-identifier">download_m2_snapshot</span>(<span 
class="ruby-identifier">remote</span>)
+  <span class="ruby-keyword">else</span>
+    <span class="ruby-identifier">fail_download</span>(<span 
class="ruby-identifier">remote</span>)
+  <span class="ruby-keyword">end</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-download_m2_snapshot" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">download_m2_snapshot</span><span
+            class="method-args">(remote_uris)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="download_m2_snapshot-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 496</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">download_m2_snapshot</span>(<span 
class="ruby-identifier">remote_uris</span>)
+  <span class="ruby-identifier">remote_uris</span>.<span 
class="ruby-identifier">find</span> <span class="ruby-keyword">do</span> <span 
class="ruby-operator">|</span><span 
class="ruby-identifier">repo_url</span><span class="ruby-operator">|</span>
+    <span class="ruby-identifier">snapshot_url</span> = <span 
class="ruby-identifier">current_snapshot_repo_url</span>(<span 
class="ruby-identifier">repo_url</span>)
+    <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">snapshot_url</span>
+      <span class="ruby-keyword">begin</span>
+        <span class="ruby-identifier">download_artifact</span> <span 
class="ruby-identifier">snapshot_url</span>
+        <span class="ruby-keyword">true</span>
+      <span class="ruby-keyword">rescue</span> <span 
class="ruby-constant">URI</span><span class="ruby-operator">::</span><span 
class="ruby-constant">NotFoundError</span>
+        <span class="ruby-keyword">false</span>
+      <span class="ruby-keyword">end</span>
+    <span class="ruby-keyword">else</span>
+      <span class="ruby-keyword">false</span>
+    <span class="ruby-keyword">end</span>
+  <span class="ruby-keyword">end</span> <span class="ruby-keyword">or</span> 
<span class="ruby-identifier">fail_download</span>(<span 
class="ruby-identifier">remote_uris</span>)
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-fail_download" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">fail_download</span><span
+            class="method-args">(remote_uris)</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="fail_download-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 531</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">fail_download</span>(<span 
class="ruby-identifier">remote_uris</span>)
+  <span class="ruby-identifier">fail</span> <span 
class="ruby-node">&quot;Failed to download #{to_spec}, tried the following 
repositories:\n#{remote_uris.join(&quot;\n&quot;)}&quot;</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-has_content-3F" class="method-detail ">
+        
+        <div class="method-heading">
+          <span class="method-name">has_content?</span><span
+            class="method-args">()</span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+
+        <div class="method-description">
+          
+          
+          
+          
+
+          
+          <div class="method-source-code" id="has_content-3F-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 456</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">has_content?</span>
+  <span class="ruby-ivar">@from</span> <span class="ruby-operator">||</span> 
<span class="ruby-ivar">@content</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+      <div id="method-i-needed-3F" class="method-detail ">
+        
+        
+        <div class="method-heading">
+          <span class="method-callseq">
+            needed?
+          </span>
+          
+          <span class="method-click-advice">click to toggle source</span>
+          
+        </div>
+        
+        
+
+        <div class="method-description">
+          
+          <p>Validates whether artifact is required to be downloaded from 
repository</p>
+          
+          
+            <div class="method-calls-super">
+              Calls superclass method
+              
+            </div>
+          
+
+          
+          <div class="method-source-code" id="needed-3F-source">
+            <pre><span class="ruby-comment"># File 
lib/buildr/packaging/artifact.rb, line 541</span>
+<span class="ruby-keyword">def</span> <span 
class="ruby-identifier">needed?</span>
+  <span class="ruby-keyword">return</span> <span 
class="ruby-keyword">true</span> <span class="ruby-keyword">if</span> <span 
class="ruby-identifier">snapshot?</span> <span 
class="ruby-operator">&amp;&amp;</span> <span 
class="ruby-constant">File</span>.<span 
class="ruby-identifier">exist?</span>(<span 
class="ruby-identifier">name</span>) <span 
class="ruby-operator">&amp;&amp;</span> (<span 
class="ruby-identifier">update_snapshot?</span> <span 
class="ruby-operator">||</span> <span class="ruby-identifier">old?</span>)
+  <span class="ruby-keyword">super</span>
+<span class="ruby-keyword">end</span></pre>
+          </div>
+          
+        </div>
+
+        
+
+        
+      </div>
+
+    
+    </section>
+  
+  </section>
+</main>
+
+
+<footer id="validator-badges" role="contentinfo">
+  <p><a href="http://validator.w3.org/check/referer";>Validate</a>
+  <p>Generated by <a href="http://docs.seattlerb.org/rdoc/";>RDoc</a> 4.2.2.
+  <p>Based on <a 
href="http://deveiate.org/projects/Darkfish-RDoc/";>Darkfish</a> by <a 
href="http://deveiate.org";>Michael Granger</a>.
+</footer>
+


Reply via email to