thinner 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/.document ADDED
@@ -0,0 +1,5 @@
1
+ README
2
+ lib/**/*.rb
3
+ bin/*
4
+ features/**/*.feature
5
+ LICENSE
data/.gitignore ADDED
@@ -0,0 +1,21 @@
1
+ ## MAC OS
2
+ .DS_Store
3
+
4
+ ## TEXTMATE
5
+ *.tmproj
6
+ tmtags
7
+
8
+ ## EMACS
9
+ *~
10
+ \#*
11
+ .\#*
12
+
13
+ ## VIM
14
+ *.swp
15
+
16
+ ## PROJECT::GENERAL
17
+ coverage
18
+ rdoc
19
+ pkg
20
+
21
+ ## PROJECT::SPECIFIC
data/LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2009 ProPublica
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README ADDED
@@ -0,0 +1,17 @@
1
+ =
2
+ ______ __ __ __ __ __ __ __ ______ ______
3
+ /\__ _\ /\ \_\ \ /\ \ /\ "-.\ \ /\ "-.\ \ /\ ___\ /\ == \
4
+ \/_/\ \/ \ \ __ \ \ \ \ \ \ \-. \ \ \ \-. \ \ \ __\ \ \ __<
5
+ \ \_\ \ \_\ \_\ \ \_\ \ \_\\"\_\ \ \_\\"\_\ \ \_____\ \ \_\ \_\
6
+ \/_/ \/_/\/_/ \/_/ \/_/ \/_/ \/_/ \/_/ \/_____/ \/_/ /_/
7
+
8
+ Thinner purges varnish caches as slowly as you need it to. Rather than
9
+ deploying an application and purging your cache in one fell swoop, thinner
10
+ allows you to purge urls from a varnish cache in batches and over time.
11
+
12
+ For usage and installation instructions, see:
13
+ http://propublica.github.com/thinner/
14
+
15
+ To report a bug or suggest a feature:
16
+ http://github.com/propublica/thinner/issues
17
+
data/Rakefile ADDED
@@ -0,0 +1,64 @@
1
+ require 'rubygems'
2
+ require 'rake'
3
+
4
+ begin
5
+ require 'jeweler'
6
+ Jeweler::Tasks.new do |gem|
7
+ gem.name = "thinner"
8
+ gem.summary = %Q{Thinner removes Varnish cache, as slowly as you need it to.}
9
+ gem.description = %Q{Thinner takes a list of urls or newline seperated stdin and purges them from Varnish.}
10
+ gem.email = "thejefflarson@gmail.com"
11
+ gem.homepage = "http://github.com/propublica/thinner"
12
+ gem.authors = ["Jeff Larson"]
13
+ gem.executables = "thinner"
14
+ gem.require_paths = ['lib']
15
+ gem.add_dependency "klarlack", "~> 0.0.6"
16
+ gem.add_development_dependency "thoughtbot-shoulda", ">= 0"
17
+ # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
18
+ end
19
+ Jeweler::GemcutterTasks.new
20
+ rescue LoadError
21
+ puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
22
+ end
23
+
24
+ require 'rake/testtask'
25
+ Rake::TestTask.new(:test) do |test|
26
+ test.libs << 'lib' << 'test'
27
+ test.pattern = 'test/**/test_*.rb'
28
+ test.verbose = true
29
+ end
30
+
31
+ begin
32
+ require 'rcov/rcovtask'
33
+ Rcov::RcovTask.new do |test|
34
+ test.libs << 'test'
35
+ test.pattern = 'test/**/test_*.rb'
36
+ test.verbose = true
37
+ end
38
+ rescue LoadError
39
+ task :rcov do
40
+ abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
41
+ end
42
+ end
43
+
44
+ task :test => :check_dependencies
45
+
46
+ task :default => :test
47
+
48
+ require 'rake/rdoctask'
49
+ Rake::RDocTask.new do |rdoc|
50
+ version = File.exist?('VERSION') ? File.read('VERSION') : ""
51
+ rdoc.rdoc_dir = 'rdoc'
52
+ rdoc.title = "thinner #{version}"
53
+ rdoc.rdoc_files.include('README*')
54
+ rdoc.rdoc_files.include('lib/**/*.rb')
55
+ end
56
+
57
+ desc "Render prose documentation"
58
+ task :gh do
59
+ require 'erb'
60
+ File.open("index.html", "w") do |f|
61
+ f.write ERB.new(File.open("documentation/index.html.erb").read).result
62
+ end
63
+ end
64
+
data/VERSION ADDED
@@ -0,0 +1 @@
1
+ 0.1.0
data/bin/thinner ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby -rubygems
2
+ require "#{File.dirname __FILE__}/../lib/thinner/command_line.rb"
3
+
4
+ Thinner::CommandLine.new