Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

First commit :)

  • Loading branch information...
commit db2be8d42e913017a9a9587ee2e9982e34b11dc2 0 parents
@billhorsman authored
6 .gitignore
@@ -0,0 +1,6 @@
+s3.yml
+tmp
+.rvmrc
+pkg/*
+*.gem
+.bundle
3  Gemfile
@@ -0,0 +1,3 @@
+source :rubygems
+
+gemspec
105 README.rdoc
@@ -0,0 +1,105 @@
+= s3aps
+
+The "s3" bit of the name refers to Amazon's {S3}[http://aws.amazon.com/s3/]
+(simple storage service). The "aps" bit of the name is a reference to the
+{taps}[https://github.com/ricardochimal/taps] gem that inspired this gem. Taps will
+push and pull data between remote and local databases. S3aps will push and pull files between S3
+and the filesystem.
+
+== Usage
+
+List the files in an S3 bucket and on filesystem
+
+ s3aps list
+
+Copy files from S3 to filesystem
+
+ s3aps pull
+
+Copy files from filesystem to S3
+
+ s3aps push
+
+== S3 Credentials
+
+You can provide your S3 credentials either on the command line or in a YAML file. By default, S3aps
+will look for a file called <tt>s3.yml</tt> in the current directory and then in a sub-directory called +config+.
+If your YAML is somewhere else then use the <tt>--config</tt> option:
+
+ s3aps list --config my_s3.yml
+
+It looks for the following values:
+
+* bucket
+* key (aliased as access_key_id)
+* secret (aliased as secret_access_key)
+
+The YAML file might look like this:
+
+ bucket: foo
+ key: 01234567890123456789
+ secret: abcdefabcdefabcdef
+
+If your YAML file is separated into environments then you'll need to tell it which one you're interested
+in:
+
+ s3aps list --config my_s3.yml --env production
+
+In which case, the YAML file might look like this:
+
+ staging:
+ bucket: foo.staging
+ key: 01234567890123456789
+ secret: abcdefabcdefabcdef
+ production:
+ bucket: foo.production
+ key: 01234567890123456780
+ secret: abcdefabcdefabcdef
+
+You can also define (or override) the credentials on the command line:
+
+ s3aps list --bucket foo --key 01234567890123456789 --secret abcdefabcdefabcdef
+
+== Synchronizing two S3 buckets
+
+You can do this by pulling the files to the filesystem and then pushing them to a new
+bucket. For instance, if you have two environments setup in <tt>s3.yml</tt>, you might do this:
+
+ s3aps pull --env production
+ s3aps push --env staging
+
+== SSL
+
+S3aps uses the http protocol on port 80. This is not configurable.
+
+== Sloppy Sync
+
+This early version is satisfied that two files are synchronized if the file exists locally and remotely.
+That works for what I need it for right now. I don't change files, just add new ones. However, I'd like
+to add an MD5 check too. I'd make that an option rather than the default because it makes it more time
+consuming.
+
+It doesn't attempt to delete files that shouldn't be there. That would be useful and I am considering
+adding a <tt>--delete</tt> option to do that. It's also a little scary.
+
+== Hand Holding
+
+It's quite easy to write stuff to production. We should seek confirmation, like Taps does. Fortunately,
+that risk is mitigated a little by not having a delete feature. I guess we should make it a bit more
+cautious when we do have delete.
+
+== Performance
+
+I only use this on a smallish bucket. Only a few thousand files and none more than a couple of Mb in
+size. It works very well in that situation. It does some non-scalable things like put a list of
+all the local and remote files in a couple of arrays so that it can quickly see what is different. At
+some point that is going to be a problem if you are dealing with lots of files.
+
+Similarly, it copies the file by reading the whole lot and then writing it out again. That won't work
+very well if you have files that are, say, 1Gb in size.
+
+== Meta
+
+Written and maintained by {Bill Horsman}[http://bill.logicalcobwebs.com]. Hat tip to {Ricardo Chimal, Jr}[http://github.com/ricardochimal] for inspiration with {Taps}[https://github.com/ricardochimal/taps]. Thanks to Mikel Lindsaar's RailsConf 2010 talk for encouragement to contribute.
+
+Released under the {MIT License}[http://www.opensource.org/licenses/mit-license.php]
2  Rakefile
@@ -0,0 +1,2 @@
+require 'bundler'
+Bundler::GemHelper.install_tasks
17 bin/s3aps
@@ -0,0 +1,17 @@
+#!/usr/bin/env ruby
+require 'rubygems'
+
+$LOAD_PATH.unshift(File.dirname(__FILE__) + '/../lib') unless $LOAD_PATH.include?(File.dirname(__FILE__) + '/../lib')
+
+require 's3aps'
+
+begin
+ success = S3aps::Runner.new(ARGV.dup).run
+ Kernel.exit(success ? 0 : 1)
+rescue SystemExit => e
+ Kernel.exit(e.status)
+rescue Exception => e
+ STDERR.puts("#{e.message} (#{e.class})")
+ STDERR.puts(e.backtrace.join("\n"))
+ Kernel.exit 1
+end
161 doc/S3aps.html
@@ -0,0 +1,161 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>Module: S3aps</title>
+
+ <link rel="stylesheet" href="./rdoc.css" type="text/css" media="screen" />
+
+ <script src="./js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="./js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="./js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="./js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+
+</head>
+<body class="module">
+
+ <div id="metadata">
+ <div id="home-metadata">
+ <div id="home-section" class="section">
+ <h3 class="section-header">
+ <a href="./index.html">Home</a>
+ <a href="./index.html#classes">Classes</a>
+ <a href="./index.html#methods">Methods</a>
+ </h3>
+ </div>
+ </div>
+
+ <div id="file-metadata">
+ <div id="file-list-section" class="section">
+ <h3 class="section-header">In Files</h3>
+ <div class="section-body">
+ <ul>
+
+ <li><a href="./lib/s3aps/file_adapter_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/file_adapter.rb">lib/s3aps/file_adapter.rb</a></li>
+
+ <li><a href="./lib/s3aps/runner_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/runner.rb">lib/s3aps/runner.rb</a></li>
+
+ <li><a href="./lib/s3aps/s3_adapter_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/s3_adapter.rb">lib/s3aps/s3_adapter.rb</a></li>
+
+ <li><a href="./lib/s3aps/sync_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/sync.rb">lib/s3aps/sync.rb</a></li>
+
+ <li><a href="./lib/s3aps/version_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/version.rb">lib/s3aps/version.rb</a></li>
+
+ </ul>
+ </div>
+ </div>
+
+
+ </div>
+
+ <div id="class-metadata">
+
+ <!-- Parent Class -->
+
+
+ <!-- Namespace Contents -->
+
+ <div id="namespace-list-section" class="section">
+ <h3 class="section-header">Namespace</h3>
+ <ul class="link-list">
+
+ <li><span class="type">CLASS</span> <a href="S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li><span class="type">CLASS</span> <a href="S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li><span class="type">CLASS</span> <a href="S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li><span class="type">CLASS</span> <a href="S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+ </div>
+
+
+ <!-- Method Quickref -->
+
+
+ <!-- Included Modules -->
+
+ </div>
+
+ <div id="project-metadata">
+
+
+
+ <div id="classindex-section" class="section project-section">
+ <h3 class="section-header">Class Index
+ <span class="search-toggle"><img src="./images/find.png"
+ height="16" width="16" alt="[+]"
+ title="show/hide quicksearch" /></span></h3>
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
+ <fieldset>
+ <legend>Quicksearch</legend>
+ <input type="text" name="quicksearch" value=""
+ class="quicksearch-field" />
+ </fieldset>
+ </form>
+
+ <ul class="link-list">
+
+ <li><a href="./S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li><a href="./S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li><a href="./S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li><a href="./S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
+ </div>
+
+
+ </div>
+ </div>
+
+ <div id="documentation">
+ <h1 class="module">S3aps</h1>
+
+ <div id="description">
+
+ </div>
+
+ <!-- Constants -->
+
+
+ <!-- Attributes -->
+
+
+ <!-- Methods -->
+
+
+ </div>
+
+
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
+
+ <p>Disabled; run with --debug to generate this.</p>
+
+ </div>
+
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
+
+</body>
+</html>
+
335 doc/S3aps/FileAdapter.html
@@ -0,0 +1,335 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>Class: S3aps::FileAdapter</title>
+
+ <link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
+
+ <script src="../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+
+</head>
+<body class="class">
+
+ <div id="metadata">
+ <div id="home-metadata">
+ <div id="home-section" class="section">
+ <h3 class="section-header">
+ <a href="../index.html">Home</a>
+ <a href="../index.html#classes">Classes</a>
+ <a href="../index.html#methods">Methods</a>
+ </h3>
+ </div>
+ </div>
+
+ <div id="file-metadata">
+ <div id="file-list-section" class="section">
+ <h3 class="section-header">In Files</h3>
+ <div class="section-body">
+ <ul>
+
+ <li><a href="../lib/s3aps/file_adapter_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/file_adapter.rb">lib/s3aps/file_adapter.rb</a></li>
+
+ </ul>
+ </div>
+ </div>
+
+
+ </div>
+
+ <div id="class-metadata">
+
+ <!-- Parent Class -->
+
+ <div id="parent-class-section" class="section">
+ <h3 class="section-header">Parent</h3>
+
+ <p class="link">Object</p>
+
+ </div>
+
+
+ <!-- Namespace Contents -->
+
+
+ <!-- Method Quickref -->
+
+ <div id="method-list-section" class="section">
+ <h3 class="section-header">Methods</h3>
+ <ul class="link-list">
+
+ <li><a href="#method-c-new">::new</a></li>
+
+ <li><a href="#method-i-list">#list</a></li>
+
+ <li><a href="#method-i-read">#read</a></li>
+
+ <li><a href="#method-i-write">#write</a></li>
+
+ </ul>
+ </div>
+
+
+ <!-- Included Modules -->
+
+ </div>
+
+ <div id="project-metadata">
+
+
+
+ <div id="classindex-section" class="section project-section">
+ <h3 class="section-header">Class Index
+ <span class="search-toggle"><img src="../images/find.png"
+ height="16" width="16" alt="[+]"
+ title="show/hide quicksearch" /></span></h3>
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
+ <fieldset>
+ <legend>Quicksearch</legend>
+ <input type="text" name="quicksearch" value=""
+ class="quicksearch-field" />
+ </fieldset>
+ </form>
+
+ <ul class="link-list">
+
+ <li><a href="../S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li><a href="../S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li><a href="../S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li><a href="../S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
+ </div>
+
+
+ </div>
+ </div>
+
+ <div id="documentation">
+ <h1 class="class">S3aps::FileAdapter</h1>
+
+ <div id="description">
+ <p>
+Reads, writes and lists files on the filesystem.
+</p>
+
+ </div>
+
+ <!-- Constants -->
+
+
+ <!-- Attributes -->
+
+
+ <!-- Methods -->
+
+ <div id="public-class-method-details" class="method-section section">
+ <h3 class="section-header">Public Class Methods</h3>
+
+
+ <div id="new-method" class="method-detail ">
+ <a name="method-c-new"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">new</span><span
+ class="method-args">(options = {})</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Options:
+</p>
+<ul>
+<li><p>
+:path - where the local files are (default is <tt>tmp</tt>)
+</p>
+</li>
+</ul>
+
+
+
+ <div class="method-source-code"
+ id="new-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/file_adapter.rb, line 9</span>
+ 9: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">options</span> = {})
+10: <span class="ruby-ivar">@path</span> = <span class="ruby-identifier">options</span>[<span class="ruby-value">:path</span>] <span class="ruby-operator">||</span> <span class="ruby-value str">&quot;tmp&quot;</span>
+11: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+ <div id="public-instance-method-details" class="method-section section">
+ <h3 class="section-header">Public Instance Methods</h3>
+
+
+ <div id="list-method" class="method-detail ">
+ <a name="method-i-list"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">list</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+List all the files in the path, recursively
+</p>
+
+
+
+ <div class="method-source-code"
+ id="list-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/file_adapter.rb, line 14</span>
+14: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">list</span>
+15: <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">glob</span>(<span class="ruby-node">&quot;#{@path}/**/*&quot;</span>).<span class="ruby-identifier">select</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">file?</span>(<span class="ruby-identifier">path</span>) }.<span class="ruby-identifier">map</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">path</span><span class="ruby-operator">|</span>
+16: <span class="ruby-identifier">path</span>.<span class="ruby-identifier">sub</span> <span class="ruby-constant">Regexp</span>.<span class="ruby-identifier">new</span>(<span class="ruby-node">&quot;^#{@path}\/&quot;</span>), <span class="ruby-value str">''</span>
+17: <span class="ruby-keyword kw">end</span>
+18: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="read-method" class="method-detail ">
+ <a name="method-i-read"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">read</span><span
+ class="method-args">(path)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Read the file.
+</p>
+
+
+
+ <div class="method-source-code"
+ id="read-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/file_adapter.rb, line 38</span>
+38: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">read</span>(<span class="ruby-identifier">path</span>)
+39: <span class="ruby-constant">File</span>.<span class="ruby-identifier">open</span>(<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-ivar">@path</span>, <span class="ruby-identifier">path</span>),<span class="ruby-value str">&quot;rb&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">io</span><span class="ruby-operator">|</span> <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>}
+40: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="write-method" class="method-detail ">
+ <a name="method-i-write"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">write</span><span
+ class="method-args">(path, value, md5sum = nil)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Write the file. It will always write the file whether it&#8217;s there or
+not, unless you supply an <tt>md5sum</tt> in which case it will check
+whether it&#8217;s different first.
+</p>
+
+
+
+ <div class="method-source-code"
+ id="write-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/file_adapter.rb, line 23</span>
+23: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">write</span>(<span class="ruby-identifier">path</span>, <span class="ruby-identifier">value</span>, <span class="ruby-identifier">md5sum</span> = <span class="ruby-keyword kw">nil</span>)
+24: <span class="ruby-identifier">just_path</span> = <span class="ruby-identifier">path</span>.<span class="ruby-identifier">sub</span> <span class="ruby-regexp re">/\/[^\/]*$/</span>, <span class="ruby-value str">''</span>
+25: <span class="ruby-identifier">local_md5</span> = <span class="ruby-identifier">md5sum</span>(<span class="ruby-identifier">path</span>)
+26: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">local_md5</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span class="ruby-identifier">local_md5</span> <span class="ruby-operator">!=</span> <span class="ruby-identifier">md5sum</span>
+27: <span class="ruby-constant">FileUtils</span>.<span class="ruby-identifier">mkdir_p</span>(<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-ivar">@path</span>, <span class="ruby-identifier">just_path</span>))
+28: <span class="ruby-constant">File</span>.<span class="ruby-identifier">open</span>(<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-ivar">@path</span>, <span class="ruby-identifier">path</span>), <span class="ruby-value str">'w'</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">outfile</span><span class="ruby-operator">|</span>
+29: <span class="ruby-identifier">outfile</span>.<span class="ruby-identifier">print</span>(<span class="ruby-identifier">value</span>)
+30: }
+31: <span class="ruby-keyword kw">true</span>
+32: <span class="ruby-keyword kw">else</span>
+33: <span class="ruby-keyword kw">false</span>
+34: <span class="ruby-keyword kw">end</span>
+35: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+
+ </div>
+
+
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
+
+ <p>Disabled; run with --debug to generate this.</p>
+
+ </div>
+
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
+
+</body>
+</html>
+
363 doc/S3aps/Runner.html
@@ -0,0 +1,363 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>Class: S3aps::Runner</title>
+
+ <link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
+
+ <script src="../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+
+</head>
+<body class="class">
+
+ <div id="metadata">
+ <div id="home-metadata">
+ <div id="home-section" class="section">
+ <h3 class="section-header">
+ <a href="../index.html">Home</a>
+ <a href="../index.html#classes">Classes</a>
+ <a href="../index.html#methods">Methods</a>
+ </h3>
+ </div>
+ </div>
+
+ <div id="file-metadata">
+ <div id="file-list-section" class="section">
+ <h3 class="section-header">In Files</h3>
+ <div class="section-body">
+ <ul>
+
+ <li><a href="../lib/s3aps/runner_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/runner.rb">lib/s3aps/runner.rb</a></li>
+
+ </ul>
+ </div>
+ </div>
+
+
+ </div>
+
+ <div id="class-metadata">
+
+ <!-- Parent Class -->
+
+ <div id="parent-class-section" class="section">
+ <h3 class="section-header">Parent</h3>
+
+ <p class="link">Object</p>
+
+ </div>
+
+
+ <!-- Namespace Contents -->
+
+
+ <!-- Method Quickref -->
+
+ <div id="method-list-section" class="section">
+ <h3 class="section-header">Methods</h3>
+ <ul class="link-list">
+
+ <li><a href="#method-c-new">::new</a></li>
+
+ <li><a href="#method-i-list">#list</a></li>
+
+ <li><a href="#method-i-pull">#pull</a></li>
+
+ <li><a href="#method-i-push">#push</a></li>
+
+ </ul>
+ </div>
+
+
+ <!-- Included Modules -->
+
+ </div>
+
+ <div id="project-metadata">
+
+
+
+ <div id="classindex-section" class="section project-section">
+ <h3 class="section-header">Class Index
+ <span class="search-toggle"><img src="../images/find.png"
+ height="16" width="16" alt="[+]"
+ title="show/hide quicksearch" /></span></h3>
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
+ <fieldset>
+ <legend>Quicksearch</legend>
+ <input type="text" name="quicksearch" value=""
+ class="quicksearch-field" />
+ </fieldset>
+ </form>
+
+ <ul class="link-list">
+
+ <li><a href="../S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li><a href="../S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li><a href="../S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li><a href="../S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
+ </div>
+
+
+ </div>
+ </div>
+
+ <div id="documentation">
+ <h1 class="class">S3aps::Runner</h1>
+
+ <div id="description">
+ <p>
+Allows you to run S3aps from the command line
+</p>
+
+ </div>
+
+ <!-- Constants -->
+
+
+ <!-- Attributes -->
+
+ <div id="attribute-method-details" class="method-section section">
+ <h3 class="section-header">Attributes</h3>
+
+
+ <div id="argv-attribute-method" class="method-detail">
+ <a name="argv"></a>
+
+ <a name="argv="></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">argv</span><span
+ class="attribute-access-type">[RW]</span>
+ </div>
+
+ <div class="method-description">
+
+
+
+ </div>
+ </div>
+
+ </div>
+
+
+ <!-- Methods -->
+
+ <div id="public-class-method-details" class="method-section section">
+ <h3 class="section-header">Public Class Methods</h3>
+
+
+ <div id="new-method" class="method-detail ">
+ <a name="method-c-new"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">new</span><span
+ class="method-args">(argv)</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 cmt"># File lib/s3aps/runner.rb, line 12</span>
+12: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">argv</span>)
+13: <span class="ruby-ivar">@options</span> = {}
+14: <span class="ruby-ivar">@cmd</span> = <span class="ruby-value">:help</span>
+15: <span class="ruby-ivar">@option_parser</span> = <span class="ruby-constant">OptionParser</span>.<span class="ruby-identifier">new</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">o</span><span class="ruby-operator">|</span>
+16: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">banner</span> = <span class="ruby-value str">S3aps version #{S3aps::VERSION}Usage: s3aps (list|pull|push|version) [OPTIONS] list List files locally and remotely pull Pull new files from remote push Push new files to remote (be careful)</span>
+17: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">on</span>(<span class="ruby-value str">&quot;-c&quot;</span>, <span class="ruby-value str">&quot;--config FILE&quot;</span>, <span class="ruby-value str">&quot;YAML file containing S3 credentials&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@options</span>[<span class="ruby-value">:config</span>] = <span class="ruby-identifier">name</span> }
+18: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">on</span>(<span class="ruby-value str">&quot;-e&quot;</span>, <span class="ruby-value str">&quot;--env ENV&quot;</span>, <span class="ruby-value str">&quot;Section of YAML to use&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@options</span>[<span class="ruby-value">:env</span>] = <span class="ruby-identifier">name</span> }
+19: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">on</span>(<span class="ruby-value str">&quot;-b&quot;</span>, <span class="ruby-value str">&quot;--bucket NAME&quot;</span>, <span class="ruby-value str">&quot;S3 bucket name&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@options</span>[<span class="ruby-value">:bucket</span>] = <span class="ruby-identifier">name</span> }
+20: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">on</span>(<span class="ruby-value str">&quot;-k&quot;</span>, <span class="ruby-value str">&quot;--key KEY&quot;</span>, <span class="ruby-value str">&quot;S3 access key&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@options</span>[<span class="ruby-value">:key</span>] = <span class="ruby-identifier">name</span> }
+21: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">on</span>(<span class="ruby-value str">&quot;-s&quot;</span>, <span class="ruby-value str">&quot;--secret KEY&quot;</span>, <span class="ruby-value str">&quot;S3 secret key&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@options</span>[<span class="ruby-value">:secret</span>] = <span class="ruby-identifier">name</span> }
+22: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">on</span>(<span class="ruby-value str">&quot;-p&quot;</span>, <span class="ruby-value str">&quot;--path PATH&quot;</span>, <span class="ruby-value str">&quot;Local path&quot;</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@options</span>[<span class="ruby-value">:path</span>] = <span class="ruby-identifier">name</span> }
+23: <span class="ruby-identifier">o</span>.<span class="ruby-identifier">parse!</span>(<span class="ruby-identifier">argv</span>)
+24: <span class="ruby-keyword kw">end</span>
+25: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">argv</span>.<span class="ruby-identifier">size</span> <span class="ruby-operator">==</span> <span class="ruby-value">1</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-node">%(list push pull version)</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">argv</span>.<span class="ruby-identifier">first</span>)
+26: <span class="ruby-ivar">@sync</span> = <span class="ruby-constant">S3aps</span><span class="ruby-operator">::</span><span class="ruby-constant">Sync</span>.<span class="ruby-identifier">new</span> <span class="ruby-ivar">@options</span>
+27: <span class="ruby-ivar">@cmd</span> = <span class="ruby-identifier">argv</span>.<span class="ruby-identifier">first</span>
+28: <span class="ruby-keyword kw">end</span>
+29: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+ <div id="public-instance-method-details" class="method-section section">
+ <h3 class="section-header">Public Instance Methods</h3>
+
+
+ <div id="list-method" class="method-detail ">
+ <a name="method-i-list"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">list</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Prints out a list of all remote and local files and shows which ones are
+remote, local or both.
+</p>
+
+
+
+ <div class="method-source-code"
+ id="list-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/runner.rb, line 53</span>
+53: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">list</span>
+54: <span class="ruby-identifier">array</span> = <span class="ruby-ivar">@sync</span>.<span class="ruby-identifier">list</span>
+55: <span class="ruby-identifier">local_count</span> = <span class="ruby-value">0</span>
+56: <span class="ruby-identifier">remote_count</span> = <span class="ruby-value">0</span>
+57: <span class="ruby-identifier">array</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">item</span><span class="ruby-operator">|</span>
+58: <span class="ruby-identifier">line</span> = <span class="ruby-identifier">item</span>.<span class="ruby-identifier">join</span>(<span class="ruby-value str">' '</span>)
+59: <span class="ruby-identifier">local_count</span> <span class="ruby-operator">+=</span><span class="ruby-value">1</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">line</span> <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/^L\s\s/</span>
+60: <span class="ruby-identifier">remote_count</span> <span class="ruby-operator">+=</span><span class="ruby-value">1</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">line</span> <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/^\s\sR/</span>
+61: <span class="ruby-identifier">puts</span> <span class="ruby-identifier">item</span>.<span class="ruby-identifier">join</span>(<span class="ruby-value str">' '</span>)
+62: <span class="ruby-keyword kw">end</span>
+63: <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;Found #{array.size} file(s): #{local_count} local only, #{remote_count} remote only, #{array.size - local_count - remote_count} common.&quot;</span>
+64: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="pull-method" class="method-detail ">
+ <a name="method-i-pull"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">pull</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Pull files from S3
+</p>
+
+
+
+ <div class="method-source-code"
+ id="pull-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/runner.rb, line 67</span>
+67: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">pull</span>
+68: <span class="ruby-identifier">count</span>, <span class="ruby-identifier">total</span> = <span class="ruby-ivar">@sync</span>.<span class="ruby-identifier">pull</span>
+69: <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;\nPulled #{count}/#{total} file#{'s' unless count == 1} from S3&quot;</span>
+70: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="push-method" class="method-detail ">
+ <a name="method-i-push"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">push</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Push files to S3
+</p>
+
+
+
+ <div class="method-source-code"
+ id="push-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/runner.rb, line 73</span>
+73: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">push</span>
+74: <span class="ruby-identifier">count</span>, <span class="ruby-identifier">total</span> = <span class="ruby-ivar">@sync</span>.<span class="ruby-identifier">push</span>
+75: <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;\nPushed #{count} file#{'s' unless count == 1} to S3&quot;</span>
+76: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+
+ </div>
+
+
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
+
+ <p>Disabled; run with --debug to generate this.</p>
+
+ </div>
+
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
+
+</body>
+</html>
+
322 doc/S3aps/S3Adapter.html
@@ -0,0 +1,322 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>Class: S3aps::S3Adapter</title>
+
+ <link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
+
+ <script src="../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+
+</head>
+<body class="class">
+
+ <div id="metadata">
+ <div id="home-metadata">
+ <div id="home-section" class="section">
+ <h3 class="section-header">
+ <a href="../index.html">Home</a>
+ <a href="../index.html#classes">Classes</a>
+ <a href="../index.html#methods">Methods</a>
+ </h3>
+ </div>
+ </div>
+
+ <div id="file-metadata">
+ <div id="file-list-section" class="section">
+ <h3 class="section-header">In Files</h3>
+ <div class="section-body">
+ <ul>
+
+ <li><a href="../lib/s3aps/s3_adapter_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/s3_adapter.rb">lib/s3aps/s3_adapter.rb</a></li>
+
+ </ul>
+ </div>
+ </div>
+
+
+ </div>
+
+ <div id="class-metadata">
+
+ <!-- Parent Class -->
+
+ <div id="parent-class-section" class="section">
+ <h3 class="section-header">Parent</h3>
+
+ <p class="link">Object</p>
+
+ </div>
+
+
+ <!-- Namespace Contents -->
+
+
+ <!-- Method Quickref -->
+
+ <div id="method-list-section" class="section">
+ <h3 class="section-header">Methods</h3>
+ <ul class="link-list">
+
+ <li><a href="#method-c-new">::new</a></li>
+
+ <li><a href="#method-i-list">#list</a></li>
+
+ <li><a href="#method-i-read">#read</a></li>
+
+ <li><a href="#method-i-write">#write</a></li>
+
+ </ul>
+ </div>
+
+
+ <!-- Included Modules -->
+
+ </div>
+
+ <div id="project-metadata">
+
+
+
+ <div id="classindex-section" class="section project-section">
+ <h3 class="section-header">Class Index
+ <span class="search-toggle"><img src="../images/find.png"
+ height="16" width="16" alt="[+]"
+ title="show/hide quicksearch" /></span></h3>
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
+ <fieldset>
+ <legend>Quicksearch</legend>
+ <input type="text" name="quicksearch" value=""
+ class="quicksearch-field" />
+ </fieldset>
+ </form>
+
+ <ul class="link-list">
+
+ <li><a href="../S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li><a href="../S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li><a href="../S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li><a href="../S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
+ </div>
+
+
+ </div>
+ </div>
+
+ <div id="documentation">
+ <h1 class="class">S3aps::S3Adapter</h1>
+
+ <div id="description">
+ <p>
+Reads, writes and lists files on S3.
+</p>
+
+ </div>
+
+ <!-- Constants -->
+
+
+ <!-- Attributes -->
+
+
+ <!-- Methods -->
+
+ <div id="public-class-method-details" class="method-section section">
+ <h3 class="section-header">Public Class Methods</h3>
+
+
+ <div id="new-method" class="method-detail ">
+ <a name="method-c-new"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">new</span><span
+ class="method-args">(options)</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 cmt"># File lib/s3aps/s3_adapter.rb, line 9</span>
+ 9: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">options</span>)
+10: <span class="ruby-ivar">@s3</span> = <span class="ruby-constant">RightAws</span><span class="ruby-operator">::</span><span class="ruby-constant">S3Interface</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">options</span>[<span class="ruby-value">:key</span>], <span class="ruby-identifier">options</span>[<span class="ruby-value">:secret</span>], <span class="ruby-value">:protocol</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">'http'</span>, <span class="ruby-value">:port</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value">80</span>)
+11: <span class="ruby-ivar">@bucket_name</span> = <span class="ruby-identifier">options</span>[<span class="ruby-value">:bucket</span>]
+12: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+ <div id="public-instance-method-details" class="method-section section">
+ <h3 class="section-header">Public Instance Methods</h3>
+
+
+ <div id="list-method" class="method-detail ">
+ <a name="method-i-list"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">list</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+List the keys of all files in the bucket
+</p>
+
+
+
+ <div class="method-source-code"
+ id="list-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/s3_adapter.rb, line 15</span>
+15: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">list</span>
+16: <span class="ruby-identifier">keys</span> = []
+17: <span class="ruby-ivar">@s3</span>.<span class="ruby-identifier">incrementally_list_bucket</span>(<span class="ruby-ivar">@bucket_name</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">key_set</span><span class="ruby-operator">|</span>
+18: <span class="ruby-identifier">keys</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">key_set</span>[<span class="ruby-value">:contents</span>].<span class="ruby-identifier">map</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">key</span><span class="ruby-operator">|</span>
+19: <span class="ruby-identifier">key</span>
+20: }
+21: }
+22: <span class="ruby-identifier">keys</span>.<span class="ruby-identifier">flatten</span>
+23: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="read-method" class="method-detail ">
+ <a name="method-i-read"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">read</span><span
+ class="method-args">(key)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+
+
+
+
+ <div class="method-source-code"
+ id="read-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/s3_adapter.rb, line 30</span>
+30: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">read</span>(<span class="ruby-identifier">key</span>)
+31: <span class="ruby-keyword kw">begin</span>
+32: <span class="ruby-ivar">@s3</span>.<span class="ruby-identifier">get_object</span>(<span class="ruby-ivar">@bucket_name</span>, <span class="ruby-identifier">key</span>)
+33: <span class="ruby-keyword kw">rescue</span>
+34: <span class="ruby-identifier">raise</span> <span class="ruby-identifier">exc</span>
+35: <span class="ruby-keyword kw">end</span>
+36: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="write-method" class="method-detail ">
+ <a name="method-i-write"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">write</span><span
+ class="method-args">(s3_name, value)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Write a value, potentially overwriting what is already there.
+</p>
+
+
+
+ <div class="method-source-code"
+ id="write-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/s3_adapter.rb, line 26</span>
+26: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">write</span>(<span class="ruby-identifier">s3_name</span>, <span class="ruby-identifier">value</span>)
+27: <span class="ruby-ivar">@s3</span>.<span class="ruby-identifier">put</span>(<span class="ruby-ivar">@bucket_name</span>, <span class="ruby-identifier">s3_name</span>, <span class="ruby-identifier">value</span>)
+28: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+
+ </div>
+
+
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
+
+ <p>Disabled; run with --debug to generate this.</p>
+
+ </div>
+
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
+
+</body>
+</html>
+
380 doc/S3aps/Sync.html
@@ -0,0 +1,380 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>Class: S3aps::Sync</title>
+
+ <link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
+
+ <script src="../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+
+</head>
+<body class="class">
+
+ <div id="metadata">
+ <div id="home-metadata">
+ <div id="home-section" class="section">
+ <h3 class="section-header">
+ <a href="../index.html">Home</a>
+ <a href="../index.html#classes">Classes</a>
+ <a href="../index.html#methods">Methods</a>
+ </h3>
+ </div>
+ </div>
+
+ <div id="file-metadata">
+ <div id="file-list-section" class="section">
+ <h3 class="section-header">In Files</h3>
+ <div class="section-body">
+ <ul>
+
+ <li><a href="../lib/s3aps/sync_rb.html?TB_iframe=true&amp;height=550&amp;width=785"
+ class="thickbox" title="lib/s3aps/sync.rb">lib/s3aps/sync.rb</a></li>
+
+ </ul>
+ </div>
+ </div>
+
+
+ </div>
+
+ <div id="class-metadata">
+
+ <!-- Parent Class -->
+
+ <div id="parent-class-section" class="section">
+ <h3 class="section-header">Parent</h3>
+
+ <p class="link">Object</p>
+
+ </div>
+
+
+ <!-- Namespace Contents -->
+
+
+ <!-- Method Quickref -->
+
+ <div id="method-list-section" class="section">
+ <h3 class="section-header">Methods</h3>
+ <ul class="link-list">
+
+ <li><a href="#method-c-new">::new</a></li>
+
+ <li><a href="#method-i-list">#list</a></li>
+
+ <li><a href="#method-i-pull">#pull</a></li>
+
+ <li><a href="#method-i-push">#push</a></li>
+
+ </ul>
+ </div>
+
+
+ <!-- Included Modules -->
+
+ </div>
+
+ <div id="project-metadata">
+
+
+
+ <div id="classindex-section" class="section project-section">
+ <h3 class="section-header">Class Index
+ <span class="search-toggle"><img src="../images/find.png"
+ height="16" width="16" alt="[+]"
+ title="show/hide quicksearch" /></span></h3>
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
+ <fieldset>
+ <legend>Quicksearch</legend>
+ <input type="text" name="quicksearch" value=""
+ class="quicksearch-field" />
+ </fieldset>
+ </form>
+
+ <ul class="link-list">
+
+ <li><a href="../S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li><a href="../S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li><a href="../S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li><a href="../S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
+ </div>
+
+
+ </div>
+ </div>
+
+ <div id="documentation">
+ <h1 class="class">S3aps::Sync</h1>
+
+ <div id="description">
+ <p>
+The controller for everything else.
+</p>
+
+ </div>
+
+ <!-- Constants -->
+
+
+ <!-- Attributes -->
+
+
+ <!-- Methods -->
+
+ <div id="public-class-method-details" class="method-section section">
+ <h3 class="section-header">Public Class Methods</h3>
+
+
+ <div id="new-method" class="method-detail ">
+ <a name="method-c-new"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">new</span><span
+ class="method-args">(options = {})</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 cmt"># File lib/s3aps/sync.rb, line 22</span>
+22: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">options</span> = {})
+23: <span class="ruby-identifier">options</span> = <span class="ruby-constant">S3aps</span><span class="ruby-operator">::</span><span class="ruby-identifier">symbolize_keys</span>(<span class="ruby-identifier">options</span>)
+24: <span class="ruby-identifier">s3_file</span> = [<span class="ruby-identifier">options</span>[<span class="ruby-value">:config</span>], <span class="ruby-value str">&quot;s3.yml&quot;</span>, <span class="ruby-value str">&quot;config/s3.yml&quot;</span>].<span class="ruby-identifier">detect</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span> <span class="ruby-identifier">f</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">file?</span>(<span class="ruby-identifier">f</span>) }
+25: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">s3_file</span>
+26: <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;Configuring S3 from #{s3_file}&quot;</span>
+27: <span class="ruby-identifier">yaml_options</span> = <span class="ruby-constant">S3aps</span><span class="ruby-operator">::</span><span class="ruby-identifier">symbolize_keys</span> <span class="ruby-constant">YAML</span>.<span class="ruby-identifier">load_file</span>(<span class="ruby-identifier">s3_file</span>)
+28: <span class="ruby-identifier">env</span> = <span class="ruby-identifier">options</span>[<span class="ruby-value">:env</span>]
+29: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">env</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">yaml_options</span>[<span class="ruby-identifier">env</span>.<span class="ruby-identifier">to_sym</span>]
+30: <span class="ruby-identifier">yaml_options</span> = <span class="ruby-constant">S3aps</span><span class="ruby-operator">::</span><span class="ruby-identifier">symbolize_keys</span> <span class="ruby-identifier">yaml_options</span>[<span class="ruby-identifier">env</span>.<span class="ruby-identifier">to_sym</span>]
+31: <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;Using #{env} environment&quot;</span>
+32: <span class="ruby-keyword kw">end</span>
+33: <span class="ruby-comment cmt"># Support for alias: access_key_id = key </span>
+34: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">yaml_options</span>[<span class="ruby-value">:access_key_id</span>]
+35: <span class="ruby-identifier">yaml_options</span>[<span class="ruby-value">:key</span>] <span class="ruby-operator">||=</span> <span class="ruby-identifier">yaml_options</span>[<span class="ruby-value">:access_key_id</span>]
+36: <span class="ruby-identifier">yaml_options</span>.<span class="ruby-identifier">delete</span>(<span class="ruby-value">:access_key_id</span>)
+37: <span class="ruby-keyword kw">end</span>
+38: <span class="ruby-comment cmt"># Support for alias: secret_access_key = secret </span>
+39: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">yaml_options</span>[<span class="ruby-value">:secret_access_key</span>]
+40: <span class="ruby-identifier">yaml_options</span>[<span class="ruby-value">:secret</span>] <span class="ruby-operator">||=</span> <span class="ruby-identifier">yaml_options</span>[<span class="ruby-value">:secret_access_key</span>]
+41: <span class="ruby-identifier">yaml_options</span>.<span class="ruby-identifier">delete</span>(<span class="ruby-value">:secret_access_key</span>)
+42: <span class="ruby-keyword kw">end</span>
+43: <span class="ruby-identifier">options</span>.<span class="ruby-identifier">merge!</span>(<span class="ruby-identifier">yaml_options</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">k</span>,<span class="ruby-identifier">o</span>,<span class="ruby-identifier">n</span><span class="ruby-operator">|</span> <span class="ruby-identifier">o</span> }
+44: <span class="ruby-keyword kw">end</span>
+45: <span class="ruby-ivar">@s3_adapter</span> = <span class="ruby-constant">S3aps</span><span class="ruby-operator">::</span><span class="ruby-constant">S3Adapter</span>.<span class="ruby-identifier">new</span> <span class="ruby-identifier">options</span>
+46: <span class="ruby-ivar">@file_adapter</span> = <span class="ruby-constant">S3aps</span><span class="ruby-operator">::</span><span class="ruby-constant">FileAdapter</span>.<span class="ruby-identifier">new</span> <span class="ruby-identifier">options</span>
+47: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+ <div id="public-instance-method-details" class="method-section section">
+ <h3 class="section-header">Public Instance Methods</h3>
+
+
+ <div id="list-method" class="method-detail ">
+ <a name="method-i-list"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">list</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Merge the local and remote lists into one and indicate whether each item is
+local, remote or both
+</p>
+
+
+
+ <div class="method-source-code"
+ id="list-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/sync.rb, line 51</span>
+51: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">list</span>
+52: <span class="ruby-identifier">local</span> = <span class="ruby-ivar">@file_adapter</span>.<span class="ruby-identifier">list</span>
+53: <span class="ruby-identifier">remote</span> = <span class="ruby-ivar">@s3_adapter</span>.<span class="ruby-identifier">list</span>.<span class="ruby-identifier">map</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span> <span class="ruby-identifier">i</span>[<span class="ruby-value">:key</span>]}
+54: <span class="ruby-identifier">all</span> = (<span class="ruby-identifier">local</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">remote</span>).<span class="ruby-identifier">uniq</span>.<span class="ruby-identifier">sort</span>
+55: <span class="ruby-identifier">all</span>.<span class="ruby-identifier">map</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">path</span><span class="ruby-operator">|</span>
+56: [
+57: <span class="ruby-identifier">local</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">path</span>) <span class="ruby-operator">?</span> <span class="ruby-value str">&quot;L&quot;</span> <span class="ruby-operator">:</span> <span class="ruby-value str">&quot; &quot;</span>,
+58: <span class="ruby-identifier">remote</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">path</span>) <span class="ruby-operator">?</span> <span class="ruby-value str">&quot;R&quot;</span> <span class="ruby-operator">:</span> <span class="ruby-value str">&quot; &quot;</span>,
+59: <span class="ruby-identifier">path</span>
+60: ]
+61: <span class="ruby-keyword kw">end</span>
+62: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="pull-method" class="method-detail ">
+ <a name="method-i-pull"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">pull</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Get all the remote files and write them out locally, if they don&#8217;t
+already exist. For simplicity, we assume that if a file of the same name
+already exists then it is the same as the remote one.
+</p>
+
+
+
+ <div class="method-source-code"
+ id="pull-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/sync.rb, line 67</span>
+67: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">pull</span>
+68: <span class="ruby-identifier">check_list</span> = <span class="ruby-identifier">local_list</span>
+69: <span class="ruby-identifier">count</span> = <span class="ruby-value">0</span>
+70: <span class="ruby-identifier">total</span> = <span class="ruby-value">0</span>
+71: <span class="ruby-ivar">@s3_adapter</span>.<span class="ruby-identifier">list</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">o</span><span class="ruby-operator">|</span>
+72: <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">check_list</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">o</span>[<span class="ruby-value">:key</span>])
+73: <span class="ruby-identifier">$stdout</span>.<span class="ruby-identifier">print</span> <span class="ruby-value str">&quot;*&quot;</span>
+74: <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@file_adapter</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">o</span>[<span class="ruby-value">:key</span>], <span class="ruby-ivar">@s3_adapter</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">o</span>[<span class="ruby-value">:key</span>]), <span class="ruby-identifier">o</span>[<span class="ruby-value">:etag</span>])
+75: <span class="ruby-identifier">count</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>
+76: <span class="ruby-keyword kw">end</span>
+77: <span class="ruby-keyword kw">else</span>
+78: <span class="ruby-identifier">$stdout</span>.<span class="ruby-identifier">print</span> <span class="ruby-value str">&quot;.&quot;</span>
+79: <span class="ruby-keyword kw">end</span>
+80: <span class="ruby-identifier">$stdout</span>.<span class="ruby-identifier">flush</span>
+81: <span class="ruby-identifier">total</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>
+82: <span class="ruby-keyword kw">end</span>
+83: [<span class="ruby-identifier">count</span>, <span class="ruby-identifier">total</span>]
+84: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ <div id="push-method" class="method-detail ">
+ <a name="method-i-push"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">push</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Get all the local files, recursively, and write them to S3, if they
+don&#8217;t already exist. For simplicity, we assume that if a file of the
+same name already exists then it is the same as the local one.
+</p>
+
+
+
+ <div class="method-source-code"
+ id="push-source">
+<pre>
+ <span class="ruby-comment cmt"># File lib/s3aps/sync.rb, line 89</span>
+ 89: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">push</span>
+ 90: <span class="ruby-identifier">check_list</span> = <span class="ruby-identifier">remote_list</span>
+ 91: <span class="ruby-identifier">count</span> = <span class="ruby-value">0</span>
+ 92: <span class="ruby-identifier">total</span> = <span class="ruby-value">0</span>
+ 93: <span class="ruby-ivar">@file_adapter</span>.<span class="ruby-identifier">list</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">path</span><span class="ruby-operator">|</span>
+ 94: <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">check_list</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">path</span>)
+ 95: <span class="ruby-identifier">$stdout</span>.<span class="ruby-identifier">print</span> <span class="ruby-value str">&quot;*&quot;</span>
+ 96: <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@s3_adapter</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">path</span>, <span class="ruby-ivar">@file_adapter</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">path</span>))
+ 97: <span class="ruby-identifier">count</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>
+ 98: <span class="ruby-keyword kw">end</span>
+ 99: <span class="ruby-keyword kw">else</span>
+100: <span class="ruby-identifier">$stdout</span>.<span class="ruby-identifier">print</span> <span class="ruby-value str">&quot;.&quot;</span>
+101: <span class="ruby-keyword kw">end</span>
+102: <span class="ruby-identifier">$stdout</span>.<span class="ruby-identifier">flush</span>
+103: <span class="ruby-identifier">total</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>
+104: <span class="ruby-keyword kw">end</span>
+105: [<span class="ruby-identifier">count</span>, <span class="ruby-identifier">total</span>]
+106: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+
+
+ </div>
+
+
+ </div>
+
+
+ </div>
+
+
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
+
+ <p>Disabled; run with --debug to generate this.</p>
+
+ </div>
+
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
+
+</body>
+</html>
+
7 doc/created.rid
@@ -0,0 +1,7 @@
+Thu, 12 May 2011 07:56:24 -0700
+lib/s3aps/file_adapter.rb Wed, 11 May 2011 18:28:37 -0700
+lib/s3aps/runner.rb Wed, 11 May 2011 19:09:39 -0700
+lib/s3aps/s3_adapter.rb Wed, 11 May 2011 22:35:12 -0700
+lib/s3aps/sync.rb Thu, 12 May 2011 07:48:13 -0700
+lib/s3aps/version.rb Thu, 12 May 2011 07:49:52 -0700
+lib/s3aps.rb Wed, 11 May 2011 17:40:32 -0700
87 doc/index.html
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
+ "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>RDoc Documentation</title>
+
+ <link type="text/css" media="screen" href="rdoc.css" rel="stylesheet" />
+
+ <script src="js/jquery.js" type="text/javascript" charset="utf-8"></script>
+ <script src="js/thickbox-compressed.js" type="text/javascript" charset="utf-8"></script>
+ <script src="js/quicksearch.js" type="text/javascript" charset="utf-8"></script>
+ <script src="js/darkfish.js" type="text/javascript" charset="utf-8"></script>
+
+</head>
+<body class="indexpage">
+
+
+ <h1>RDoc Documentation</h1>
+
+
+ <p>This is the API documentation for 'RDoc Documentation'.</p>
+
+
+
+
+
+ <h2 id="classes">Classes/Modules</h2>
+ <ul>
+
+ <li class="class"><a href="S3aps/FileAdapter.html">S3aps::FileAdapter</a></li>
+
+ <li class="class"><a href="S3aps/Runner.html">S3aps::Runner</a></li>
+
+ <li class="class"><a href="S3aps/S3Adapter.html">S3aps::S3Adapter</a></li>
+
+ <li class="class"><a href="S3aps/Sync.html">S3aps::Sync</a></li>
+
+ </ul>
+
+ <h2 id="methods">Methods</h2>
+ <ul>
+
+ <li><a href="S3aps/FileAdapter.html#method-c-new">::new &mdash; S3aps::FileAdapter</a></li>
+
+ <li><a href="S3aps/Sync.html#method-c-new">::new &mdash; S3aps::Sync</a></li>
+
+ <li><a href="S3aps/Runner.html#method-c-new">::new &mdash; S3aps::Runner</a></li>
+
+ <li><a href="S3aps/S3Adapter.html#method-c-new">::new &mdash; S3aps::S3Adapter</a></li>
+
+ <li><a href="S3aps/FileAdapter.html#method-i-list">#list &mdash; S3aps::FileAdapter</a></li>
+
+ <li><a href="S3aps/Runner.html#method-i-list">#list &mdash; S3aps::Runner</a></li>
+
+ <li><a href="S3aps/Sync.html#method-i-list">#list &mdash; S3aps::Sync</a></li>
+
+ <li><a href="S3aps/S3Adapter.html#method-i-list">#list &mdash; S3aps::S3Adapter</a></li>
+
+ <li><a href="S3aps/Runner.html#method-i-pull">#pull &mdash; S3aps::Runner</a></li>
+
+ <li><a href="S3aps/Sync.html#method-i-pull">#pull &mdash; S3aps::Sync</a></li>
+
+ <li><a href="S3aps/Runner.html#method-i-push">#push &mdash; S3aps::Runner</a></li>
+
+ <li><a href="S3aps/Sync.html#method-i-push">#push &mdash; S3aps::Sync</a></li>
+
+ <li><a href="S3aps/S3Adapter.html#method-i-read">#read &mdash; S3aps::S3Adapter</a></li>
+
+ <li><a href="S3aps/FileAdapter.html#method-i-read">#read &mdash; S3aps::FileAdapter</a></li>
+
+ <li><a href="S3aps/FileAdapter.html#method-i-write">#write &mdash; S3aps::FileAdapter</a></li>
+
+ <li><a href="S3aps/S3Adapter.html#method-i-write">#write &mdash; S3aps::S3Adapter</a></li>
+
+ </ul>
+
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
+</body>
+</html>
52 doc/lib/s3aps/file_adapter_rb.html
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>File: file_adapter.rb [RDoc Documentation]</title>
+
+ <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet" />
+
+ <script src="../../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+</head>
+
+<body class="file file-popup">
+ <div id="metadata">
+ <dl>
+ <dt class="modified-date">Last Modified</dt>
+ <dd class="modified-date">2011-05-11 18:28:37 -0700</dd>
+
+
+ <dt class="requires">Requires</dt>
+ <dd class="requires">
+ <ul>
+
+ </ul>
+ </dd>
+
+
+
+ </dl>
+ </div>
+
+ <div id="documentation">
+
+ <div class="description">
+ <h2>Description</h2>
+
+ </div>
+
+ </div>
+</body>
+</html>
+
58 doc/lib/s3aps/runner_rb.html
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>File: runner.rb [RDoc Documentation]</title>
+
+ <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet" />
+
+ <script src="../../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+</head>
+
+<body class="file file-popup">
+ <div id="metadata">
+ <dl>
+ <dt class="modified-date">Last Modified</dt>
+ <dd class="modified-date">2011-05-11 19:09:39 -0700</dd>
+
+
+ <dt class="requires">Requires</dt>
+ <dd class="requires">
+ <ul>
+
+ <li>optparse</li>
+
+ <li>fileutils</li>
+
+ <li>s3aps/sync</li>
+
+ </ul>
+ </dd>
+
+
+
+ </dl>
+ </div>
+
+ <div id="documentation">
+
+ <div class="description">
+ <h2>Description</h2>
+
+ </div>
+
+ </div>
+</body>
+</html>
+
56 doc/lib/s3aps/s3_adapter_rb.html
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>File: s3_adapter.rb [RDoc Documentation]</title>
+
+ <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet" />
+
+ <script src="../../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+</head>
+
+<body class="file file-popup">
+ <div id="metadata">
+ <dl>
+ <dt class="modified-date">Last Modified</dt>
+ <dd class="modified-date">2011-05-11 22:35:12 -0700</dd>
+
+
+ <dt class="requires">Requires</dt>
+ <dd class="requires">
+ <ul>
+
+ <li>rubygems</li>
+
+ <li>right_aws</li>
+
+ </ul>
+ </dd>
+
+
+
+ </dl>
+ </div>
+
+ <div id="documentation">
+
+ <div class="description">
+ <h2>Description</h2>
+
+ </div>
+
+ </div>
+</body>
+</html>
+
58 doc/lib/s3aps/sync_rb.html
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>File: sync.rb [RDoc Documentation]</title>
+
+ <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet" />
+
+ <script src="../../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+</head>
+
+<body class="file file-popup">
+ <div id="metadata">
+ <dl>
+ <dt class="modified-date">Last Modified</dt>
+ <dd class="modified-date">2011-05-12 07:48:13 -0700</dd>
+
+
+ <dt class="requires">Requires</dt>
+ <dd class="requires">
+ <ul>
+
+ <li>s3aps/file_adapter</li>
+
+ <li>s3aps/s3_adapter</li>
+
+ <li>yaml</li>
+
+ </ul>
+ </dd>
+
+
+
+ </dl>
+ </div>
+
+ <div id="documentation">
+
+ <div class="description">
+ <h2>Description</h2>
+
+ </div>
+
+ </div>
+</body>
+</html>
+
52 doc/lib/s3aps/version_rb.html
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>File: version.rb [RDoc Documentation]</title>
+
+ <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet" />
+
+ <script src="../../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+</head>
+
+<body class="file file-popup">
+ <div id="metadata">
+ <dl>
+ <dt class="modified-date">Last Modified</dt>
+ <dd class="modified-date">2011-05-12 07:49:52 -0700</dd>
+
+
+ <dt class="requires">Requires</dt>
+ <dd class="requires">
+ <ul>
+
+ </ul>
+ </dd>
+
+
+
+ </dl>
+ </div>
+
+ <div id="documentation">
+
+ <div class="description">
+ <h2>Description</h2>
+
+ </div>
+
+ </div>
+</body>
+</html>
+
62 doc/lib/s3aps_rb.html
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+
+ <title>File: s3aps.rb [RDoc Documentation]</title>
+
+ <link type="text/css" media="screen" href="../rdoc.css" rel="stylesheet" />
+
+ <script src="../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
+</head>
+
+<body class="file file-popup">
+ <div id="metadata">
+ <dl>
+ <dt class="modified-date">Last Modified</dt>
+ <dd class="modified-date">2011-05-11 17:40:32 -0700</dd>
+
+
+ <dt class="requires">Requires</dt>
+ <dd class="requires">
+ <ul>
+
+ <li>s3aps/runner</li>
+
+ <li>s3aps/file_adapter</li>
+
+ <li>s3aps/s3_adapter</li>
+
+ <li>s3aps/sync</li>
+
+ <li>s3aps/version</li>
+
+ </ul>
+ </dd>
+
+
+
+ </dl>
+ </div>
+
+ <div id="documentation">
+
+ <div class="description">
+ <h2>Description</h2>
+
+ </div>
+
+ </div>
+</body>