basiszwo-reflection 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.document +5 -0
- data/.gitignore +21 -0
- data/.yardoc +0 -0
- data/History.rdoc +21 -0
- data/LICENSE +20 -0
- data/README.rdoc +117 -0
- data/Rakefile +75 -0
- data/Reflection.gemspec +135 -0
- data/TODO.rdoc +38 -0
- data/VERSION +1 -0
- data/bin/reflection +5 -0
- data/doc/Reflection/CLI.html +153 -0
- data/doc/Reflection/Command/Apply.html +266 -0
- data/doc/Reflection/Command/Base.html +385 -0
- data/doc/Reflection/Command/Stash.html +342 -0
- data/doc/Reflection/Command.html +85 -0
- data/doc/Reflection/Config.html +902 -0
- data/doc/Reflection/ConfigArgumentError.html +92 -0
- data/doc/Reflection/Directory/Base.html +657 -0
- data/doc/Reflection/Directory/Stash.html +411 -0
- data/doc/Reflection/Directory.html +85 -0
- data/doc/Reflection/Rails.html +409 -0
- data/doc/Reflection/Repository.html +745 -0
- data/doc/Reflection/Support/Home.html +182 -0
- data/doc/Reflection/Support/Log.html +222 -0
- data/doc/Reflection/Support.html +141 -0
- data/doc/Reflection/Validations.html +135 -0
- data/doc/Reflection.html +285 -0
- data/doc/_index.html +267 -0
- data/doc/class_list.html +197 -0
- data/doc/css/common.css +1 -0
- data/doc/css/full_list.css +23 -0
- data/doc/css/style.css +261 -0
- data/doc/file.README.html +200 -0
- data/doc/file_list.html +29 -0
- data/doc/index.html +200 -0
- data/doc/js/app.js +91 -0
- data/doc/js/full_list.js +39 -0
- data/doc/js/jquery.js +19 -0
- data/doc/method_list.html +572 -0
- data/doc/top-level-namespace.html +80 -0
- data/lib/reflection/cli.rb +35 -0
- data/lib/reflection/command/apply.rb +71 -0
- data/lib/reflection/command/base.rb +28 -0
- data/lib/reflection/command/stash.rb +64 -0
- data/lib/reflection/command.rb +7 -0
- data/lib/reflection/config.rb +139 -0
- data/lib/reflection/directory/base.rb +58 -0
- data/lib/reflection/directory/stash.rb +30 -0
- data/lib/reflection/directory.rb +6 -0
- data/lib/reflection/rails/database.rb +96 -0
- data/lib/reflection/rails.rb +40 -0
- data/lib/reflection/repository.rb +71 -0
- data/lib/reflection/support/home.rb +17 -0
- data/lib/reflection/support/log.rb +20 -0
- data/lib/reflection/support.rb +12 -0
- data/lib/reflection/validations.rb +23 -0
- data/lib/reflection.rb +32 -0
- data/spec/reflection/cli_spec.rb +41 -0
- data/spec/reflection/command/stash_spec.rb +104 -0
- data/spec/reflection/config_spec.rb +126 -0
- data/spec/reflection/directory/base_spec.rb +38 -0
- data/spec/reflection/directory/stash_spec.rb +39 -0
- data/spec/reflection/rails/database_spec.rb +161 -0
- data/spec/reflection/rails_spec.rb +62 -0
- data/spec/reflection/repository_spec.rb +71 -0
- data/spec/reflection/support/home_spec.rb +30 -0
- data/spec/reflection/support_spec.rb +4 -0
- data/spec/reflection_spec.rb +21 -0
- data/spec/spec.opts +1 -0
- data/spec/spec_helper.rb +15 -0
- metadata +157 -0
data/.document
ADDED
data/.gitignore
ADDED
data/.yardoc
ADDED
Binary file
|
data/History.rdoc
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
=== current HEAD
|
2
|
+
|
3
|
+
* enhancements
|
4
|
+
* Move instead of copy to preserve even more cpu-io-wait
|
5
|
+
* Show the current version (--version)
|
6
|
+
* Rails: Recreate the database before applying a dump
|
7
|
+
* Rails: Run pending migrations after applying a dump
|
8
|
+
|
9
|
+
=== 0.4.6 / 2009-11-19
|
10
|
+
|
11
|
+
* fixes
|
12
|
+
* Fixed a blocking command call
|
13
|
+
|
14
|
+
=== 0.4.5 / 2009-11-19
|
15
|
+
|
16
|
+
* enhancements
|
17
|
+
* Added --force option to skip moments of user-interaction
|
18
|
+
* Replaced FileUtils#methods with its native brothers to gain more speed (and to preserve your cpu)
|
19
|
+
|
20
|
+
* fixes
|
21
|
+
* Fixed no-working repository-pull
|
data/LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2009 Andreas Wolff
|
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.rdoc
ADDED
@@ -0,0 +1,117 @@
|
|
1
|
+
= Reflection
|
2
|
+
|
3
|
+
Reflection is designed to keep your development system in sync with your production system's files and database (by dumping).
|
4
|
+
It uses a shared git repository to store these files, which allows you to mirror your production environment without the need of
|
5
|
+
direct access to your production servers.
|
6
|
+
|
7
|
+
It provides two main command modes:
|
8
|
+
|
9
|
+
* Stash: Indented to be run on the server side, adds a specified directory and, optionally, a database dump to a shared Git repository
|
10
|
+
* Apply: To be used on a local development machine, gets content from the repository, copies it to a specified directory and optionally loads the database dump into your local database
|
11
|
+
|
12
|
+
|
13
|
+
== Get it
|
14
|
+
|
15
|
+
Reflection is a gem, hosted on Gemcutter:
|
16
|
+
|
17
|
+
gem install reflection
|
18
|
+
|
19
|
+
|
20
|
+
== Stashing your production data
|
21
|
+
|
22
|
+
==== The simplest form:
|
23
|
+
|
24
|
+
$ reflection --stash --directory /path/to/your/assets --repository git@your-shared-repository.git
|
25
|
+
|
26
|
+
This will clone <tt>git@your-shared-repository.git</tt> and add the directory <tt>/path/to/your/assets</tt> to the repository.
|
27
|
+
Reflection keeps a local version of your repository in HOME/.reflection/stash. So the next time you run the command, there is no need of cloning it again.
|
28
|
+
|
29
|
+
|
30
|
+
==== Now, lets include a database dump
|
31
|
+
|
32
|
+
$ reflection --stash \
|
33
|
+
--directory /path/to/your/assets \
|
34
|
+
--repository git@your-shared-repository.git \
|
35
|
+
--rails /rails/root \
|
36
|
+
--rails-env production
|
37
|
+
|
38
|
+
This does the same as above, but additionally dumps your production database and adds the fresh dump to your repository.
|
39
|
+
|
40
|
+
|
41
|
+
==== I'm lazy..
|
42
|
+
|
43
|
+
You too, aren't you? So Reflection allows you to store all command line options in a config file.
|
44
|
+
|
45
|
+
|
46
|
+
$ reflection --stash \
|
47
|
+
--directory /path/to/your/assets \
|
48
|
+
--repository git@your-shared-repository.git \
|
49
|
+
--rails /rails/root \
|
50
|
+
--rails-env production \
|
51
|
+
--write /path/to/your/config
|
52
|
+
|
53
|
+
|
54
|
+
The next time you want to run the same command as above (useful for cron), you could simply call Reflection with:
|
55
|
+
|
56
|
+
$ reflection /path/to/your/config
|
57
|
+
|
58
|
+
|
59
|
+
== Getting the production stuff on your local development machine
|
60
|
+
|
61
|
+
This works exactly the same as describe above, but you would use --apply instead of --stash:
|
62
|
+
|
63
|
+
$ reflection --apply \
|
64
|
+
--directory /path/to/your/assets \
|
65
|
+
--repository git@your-shared-repository.git \
|
66
|
+
--rails /rails/root \
|
67
|
+
--rails-env development
|
68
|
+
|
69
|
+
This clones or pulls <tt>git@your-shared-repository.git</tt> (again, Reflection keeps a version of your Repository in HOME/.reflection/apply), copies the content to the specified directory (e.g. rails/application/public/assets) and optionally loads the dump into your database.
|
70
|
+
|
71
|
+
As you may have noticed, the Reflection command above got called with <tt>--rails-env development</tt>, which loads the dump in your development database (as defined by /rails/root/config/database.yml).
|
72
|
+
|
73
|
+
|
74
|
+
==== A little productivity hint
|
75
|
+
|
76
|
+
If you have a <tt>reflection.yml</tt> config file in your current application-development-directory, syncing your server-production environment is as easy as running:
|
77
|
+
|
78
|
+
$ reflection
|
79
|
+
|
80
|
+
|
81
|
+
== reflection --help
|
82
|
+
|
83
|
+
$ reflection --help
|
84
|
+
Usage: reflection --COMMAND --repository=GIT_REPO --directory=PATH
|
85
|
+
-or-
|
86
|
+
Usage: reflection /path/to/reflection-config-file.yml
|
87
|
+
|
88
|
+
On the server side:
|
89
|
+
-s, --stash Store your assets and/or a database dump in a git-repository.
|
90
|
+
On the client side:
|
91
|
+
-a, --apply Apply assets and/or a database dump loaded from a git-repository.
|
92
|
+
|
93
|
+
Required options for both:
|
94
|
+
-r, --repository GIT_URL A Git repository(url) to be used as storage
|
95
|
+
-d, --directory PATH Path to your asset directory
|
96
|
+
|
97
|
+
Additional options for both:
|
98
|
+
--rails [RAILS_ROOT] Enable dumping/applying of a Rails managed MySQL database
|
99
|
+
--rails-env [ENV] Rails environment to instrument
|
100
|
+
--write [FILE] Create a configuration FILE from the current commandline options
|
101
|
+
--force Hide tedious warnings
|
102
|
+
-v, --verbose Include debug information in output
|
103
|
+
--version Show version
|
104
|
+
|
105
|
+
|
106
|
+
== Note on Patches/Pull Requests
|
107
|
+
|
108
|
+
* Fork the project.
|
109
|
+
* Make your feature addition or bug fix.
|
110
|
+
* Add specs for it. This is important so I don't break it in a future version unintentionally.
|
111
|
+
* Commit, do not mess with rakefile, version, or history.
|
112
|
+
(if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
|
113
|
+
* Send me a pull request. Bonus points for topic branches.
|
114
|
+
|
115
|
+
== Copyright
|
116
|
+
|
117
|
+
Copyright (c) 2009 Andreas Wolff. See LICENSE for details.
|
data/Rakefile
ADDED
@@ -0,0 +1,75 @@
|
|
1
|
+
require 'rubygems'
|
2
|
+
require 'rake'
|
3
|
+
|
4
|
+
begin
|
5
|
+
require 'jeweler'
|
6
|
+
Jeweler::Tasks.new do |gem|
|
7
|
+
gem.name = "basiszwo-reflection"
|
8
|
+
gem.summary = %Q{Keep your development machine in sync with production.}
|
9
|
+
gem.description = %Q{
|
10
|
+
Reflection is designed to keep your development system in sync with your production system's files and database (by dumping).
|
11
|
+
It uses a shared git repository to store these files, which allows you to mirror your production environment without the need of
|
12
|
+
direct access to your production servers.
|
13
|
+
}
|
14
|
+
gem.email = "stefan@ninjaconcept.com"
|
15
|
+
gem.homepage = "http://github.com/basiszwo/reflection"
|
16
|
+
gem.authors = ["Stefan Botzenhart", "Andreas Wolff"]
|
17
|
+
gem.add_development_dependency "rspec", ">= 1.2.9"
|
18
|
+
gem.add_dependency "git", ">= 1.2.5"
|
19
|
+
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
|
20
|
+
end
|
21
|
+
Jeweler::GemcutterTasks.new
|
22
|
+
rescue LoadError
|
23
|
+
puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
|
24
|
+
end
|
25
|
+
|
26
|
+
require 'spec/rake/spectask'
|
27
|
+
Spec::Rake::SpecTask.new(:spec) do |spec|
|
28
|
+
spec.libs << 'lib' << 'spec'
|
29
|
+
spec.spec_files = FileList['spec/**/*_spec.rb']
|
30
|
+
end
|
31
|
+
|
32
|
+
Spec::Rake::SpecTask.new(:rcov) do |spec|
|
33
|
+
spec.libs << 'lib' << 'spec'
|
34
|
+
spec.pattern = 'spec/**/*_spec.rb'
|
35
|
+
spec.rcov = true
|
36
|
+
end
|
37
|
+
|
38
|
+
task :spec => :check_dependencies
|
39
|
+
|
40
|
+
begin
|
41
|
+
require 'reek/adapters/rake_task'
|
42
|
+
Reek::RakeTask.new do |t|
|
43
|
+
t.fail_on_error = true
|
44
|
+
t.verbose = false
|
45
|
+
t.source_files = 'lib/**/*.rb'
|
46
|
+
end
|
47
|
+
rescue LoadError
|
48
|
+
task :reek do
|
49
|
+
abort "Reek is not available. In order to run reek, you must: sudo gem install reek"
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
begin
|
54
|
+
require 'roodi'
|
55
|
+
require 'roodi_task'
|
56
|
+
RoodiTask.new do |t|
|
57
|
+
t.verbose = false
|
58
|
+
end
|
59
|
+
rescue LoadError
|
60
|
+
task :roodi do
|
61
|
+
abort "Roodi is not available. In order to run roodi, you must: sudo gem install roodi"
|
62
|
+
end
|
63
|
+
end
|
64
|
+
|
65
|
+
task :default => :spec
|
66
|
+
|
67
|
+
require 'rake/rdoctask'
|
68
|
+
Rake::RDocTask.new do |rdoc|
|
69
|
+
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
70
|
+
|
71
|
+
rdoc.rdoc_dir = 'rdoc'
|
72
|
+
rdoc.title = "reflection #{version}"
|
73
|
+
rdoc.rdoc_files.include('README*')
|
74
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
75
|
+
end
|
data/Reflection.gemspec
ADDED
@@ -0,0 +1,135 @@
|
|
1
|
+
# Generated by jeweler
|
2
|
+
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
|
4
|
+
# -*- encoding: utf-8 -*-
|
5
|
+
|
6
|
+
Gem::Specification.new do |s|
|
7
|
+
s.name = %q{reflection}
|
8
|
+
s.version = "0.5.0"
|
9
|
+
|
10
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
+
s.authors = ["Andreas Wolff"]
|
12
|
+
s.date = %q{2009-12-01}
|
13
|
+
s.default_executable = %q{reflection}
|
14
|
+
s.description = %q{
|
15
|
+
Reflection is designed to keep your development system in sync with your production system's files and database (by dumping).
|
16
|
+
It uses a shared git repository to store these files, which allows you to mirror your production environment without the need of
|
17
|
+
direct access to your production servers.
|
18
|
+
}
|
19
|
+
s.email = %q{rubyphunk@gmail.com}
|
20
|
+
s.executables = ["reflection"]
|
21
|
+
s.extra_rdoc_files = [
|
22
|
+
"LICENSE",
|
23
|
+
"README.rdoc",
|
24
|
+
"TODO"
|
25
|
+
]
|
26
|
+
s.files = [
|
27
|
+
".document",
|
28
|
+
".gitignore",
|
29
|
+
".yardoc",
|
30
|
+
"History.rdoc",
|
31
|
+
"LICENSE",
|
32
|
+
"README.rdoc",
|
33
|
+
"Rakefile",
|
34
|
+
"Reflection.gemspec",
|
35
|
+
"TODO",
|
36
|
+
"VERSION",
|
37
|
+
"bin/reflection",
|
38
|
+
"doc/Reflection.html",
|
39
|
+
"doc/Reflection/CLI.html",
|
40
|
+
"doc/Reflection/Command.html",
|
41
|
+
"doc/Reflection/Command/Apply.html",
|
42
|
+
"doc/Reflection/Command/Base.html",
|
43
|
+
"doc/Reflection/Command/Stash.html",
|
44
|
+
"doc/Reflection/Config.html",
|
45
|
+
"doc/Reflection/ConfigArgumentError.html",
|
46
|
+
"doc/Reflection/Directory.html",
|
47
|
+
"doc/Reflection/Directory/Base.html",
|
48
|
+
"doc/Reflection/Directory/Stash.html",
|
49
|
+
"doc/Reflection/Rails.html",
|
50
|
+
"doc/Reflection/Repository.html",
|
51
|
+
"doc/Reflection/Support.html",
|
52
|
+
"doc/Reflection/Support/Home.html",
|
53
|
+
"doc/Reflection/Support/Log.html",
|
54
|
+
"doc/Reflection/Validations.html",
|
55
|
+
"doc/_index.html",
|
56
|
+
"doc/class_list.html",
|
57
|
+
"doc/css/common.css",
|
58
|
+
"doc/css/full_list.css",
|
59
|
+
"doc/css/style.css",
|
60
|
+
"doc/file.README.html",
|
61
|
+
"doc/file_list.html",
|
62
|
+
"doc/index.html",
|
63
|
+
"doc/js/app.js",
|
64
|
+
"doc/js/full_list.js",
|
65
|
+
"doc/js/jquery.js",
|
66
|
+
"doc/method_list.html",
|
67
|
+
"doc/top-level-namespace.html",
|
68
|
+
"lib/reflection.rb",
|
69
|
+
"lib/reflection/cli.rb",
|
70
|
+
"lib/reflection/command.rb",
|
71
|
+
"lib/reflection/command/apply.rb",
|
72
|
+
"lib/reflection/command/base.rb",
|
73
|
+
"lib/reflection/command/stash.rb",
|
74
|
+
"lib/reflection/config.rb",
|
75
|
+
"lib/reflection/directory.rb",
|
76
|
+
"lib/reflection/directory/base.rb",
|
77
|
+
"lib/reflection/directory/stash.rb",
|
78
|
+
"lib/reflection/rails.rb",
|
79
|
+
"lib/reflection/rails/database.rb",
|
80
|
+
"lib/reflection/repository.rb",
|
81
|
+
"lib/reflection/support.rb",
|
82
|
+
"lib/reflection/support/home.rb",
|
83
|
+
"lib/reflection/support/log.rb",
|
84
|
+
"lib/reflection/validations.rb",
|
85
|
+
"spec/reflection/cli_spec.rb",
|
86
|
+
"spec/reflection/command/stash_spec.rb",
|
87
|
+
"spec/reflection/config_spec.rb",
|
88
|
+
"spec/reflection/directory/base_spec.rb",
|
89
|
+
"spec/reflection/directory/stash_spec.rb",
|
90
|
+
"spec/reflection/rails/database_spec.rb",
|
91
|
+
"spec/reflection/rails_spec.rb",
|
92
|
+
"spec/reflection/repository_spec.rb",
|
93
|
+
"spec/reflection/support/home_spec.rb",
|
94
|
+
"spec/reflection/support_spec.rb",
|
95
|
+
"spec/reflection_spec.rb",
|
96
|
+
"spec/spec.opts",
|
97
|
+
"spec/spec_helper.rb"
|
98
|
+
]
|
99
|
+
s.homepage = %q{http://github.com/rubyphunk/reflection}
|
100
|
+
s.rdoc_options = ["--charset=UTF-8"]
|
101
|
+
s.require_paths = ["lib"]
|
102
|
+
s.rubygems_version = %q{1.3.5}
|
103
|
+
s.summary = %q{Keep your development machine in sync with production.}
|
104
|
+
s.test_files = [
|
105
|
+
"spec/reflection/cli_spec.rb",
|
106
|
+
"spec/reflection/command/stash_spec.rb",
|
107
|
+
"spec/reflection/config_spec.rb",
|
108
|
+
"spec/reflection/directory/base_spec.rb",
|
109
|
+
"spec/reflection/directory/stash_spec.rb",
|
110
|
+
"spec/reflection/rails/database_spec.rb",
|
111
|
+
"spec/reflection/rails_spec.rb",
|
112
|
+
"spec/reflection/repository_spec.rb",
|
113
|
+
"spec/reflection/support/home_spec.rb",
|
114
|
+
"spec/reflection/support_spec.rb",
|
115
|
+
"spec/reflection_spec.rb",
|
116
|
+
"spec/spec_helper.rb"
|
117
|
+
]
|
118
|
+
|
119
|
+
if s.respond_to? :specification_version then
|
120
|
+
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
121
|
+
s.specification_version = 3
|
122
|
+
|
123
|
+
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
124
|
+
s.add_development_dependency(%q<rspec>, [">= 1.2.9"])
|
125
|
+
s.add_runtime_dependency(%q<git>, [">= 1.2.5"])
|
126
|
+
else
|
127
|
+
s.add_dependency(%q<rspec>, [">= 1.2.9"])
|
128
|
+
s.add_dependency(%q<git>, [">= 1.2.5"])
|
129
|
+
end
|
130
|
+
else
|
131
|
+
s.add_dependency(%q<rspec>, [">= 1.2.9"])
|
132
|
+
s.add_dependency(%q<git>, [">= 1.2.5"])
|
133
|
+
end
|
134
|
+
end
|
135
|
+
|
data/TODO.rdoc
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
= Things To Do
|
2
|
+
|
3
|
+
== Fixes
|
4
|
+
|
5
|
+
* Rails: Database: Broken Encoding
|
6
|
+
|
7
|
+
|
8
|
+
== Enhancements
|
9
|
+
|
10
|
+
* Replace CLI handing with Thor (http://github.com/wycats/thor)
|
11
|
+
* Add Logger (Reflection::Support.log)
|
12
|
+
* Callbacks
|
13
|
+
* Remove ruby-git dependency
|
14
|
+
|
15
|
+
|
16
|
+
=== Reflectables
|
17
|
+
|
18
|
+
* Objects that take care of getting data from or to a system
|
19
|
+
* Objects must respond to #apply and #stash
|
20
|
+
* Types:
|
21
|
+
* Database (can get information from Rails Apps)
|
22
|
+
* Directories/Files
|
23
|
+
|
24
|
+
|
25
|
+
=== Bundles
|
26
|
+
|
27
|
+
* Defined in a config file
|
28
|
+
* Must have a name
|
29
|
+
* Can contain any number of reflectables (databases, directories)
|
30
|
+
|
31
|
+
|
32
|
+
=== Buckets
|
33
|
+
|
34
|
+
* A place to store stashed data (bundle.stash)
|
35
|
+
* Types:
|
36
|
+
* Git
|
37
|
+
* S3
|
38
|
+
* Filesystem
|
data/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
0.5.1
|
data/bin/reflection
ADDED
@@ -0,0 +1,153 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
|
+
<head>
|
5
|
+
<meta name="Content-Type" content="text/html; charset=UTF-8" />
|
6
|
+
<title>Module: Reflection::CLI</title>
|
7
|
+
<link rel="stylesheet" href="../css/style.css" type="text/css" media="screen" charset="utf-8" />
|
8
|
+
<link rel="stylesheet" href="../css/common.css" type="text/css" media="screen" charset="utf-8" />
|
9
|
+
|
10
|
+
<script type="text/javascript" charset="utf-8">
|
11
|
+
relpath = '..';
|
12
|
+
if (relpath != '') relpath += '/';
|
13
|
+
</script>
|
14
|
+
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
15
|
+
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
16
|
+
|
17
|
+
</head>
|
18
|
+
<body>
|
19
|
+
<div id="header">
|
20
|
+
<div id="menu">
|
21
|
+
|
22
|
+
<a href="../_index.html">Index (C)</a> »
|
23
|
+
<a title="Reflection" href="../Reflection.html">Reflection</a>
|
24
|
+
»
|
25
|
+
<span class="title">CLI</span>
|
26
|
+
|
27
|
+
</div>
|
28
|
+
|
29
|
+
<div id="search">
|
30
|
+
<a id="class_list_link" href="#">Namespace List</a>
|
31
|
+
<a id="method_list_link" href="#">Method List</a>
|
32
|
+
<a id ="file_list_link" href="#">File List</a>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div class="clear"></div>
|
36
|
+
</div>
|
37
|
+
|
38
|
+
<iframe id="search_frame"></iframe>
|
39
|
+
|
40
|
+
<div id="content"><h1>Module: Reflection::CLI
|
41
|
+
|
42
|
+
|
43
|
+
</h1>
|
44
|
+
|
45
|
+
<dl class="box">
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
|
50
|
+
|
51
|
+
|
52
|
+
|
53
|
+
<dt class="r1 last">Defined in:</dt>
|
54
|
+
<dd class="r1 last">lib/reflection/cli.rb</dd>
|
55
|
+
|
56
|
+
</dl>
|
57
|
+
<div class="clear"></div>
|
58
|
+
|
59
|
+
|
60
|
+
|
61
|
+
|
62
|
+
<h2>Method Summary</h2>
|
63
|
+
<ul class="summary">
|
64
|
+
|
65
|
+
<li class="public ">
|
66
|
+
<span class="summary_signature"><a title="run! (class method)" href="#run%21-class_method">+ (Object) <strong>run!</strong>(args = nil) </a>
|
67
|
+
|
68
|
+
</span>
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
<span class="summary_desc"></span>
|
76
|
+
|
77
|
+
</li>
|
78
|
+
|
79
|
+
|
80
|
+
</ul>
|
81
|
+
|
82
|
+
|
83
|
+
|
84
|
+
<div id="method_details">
|
85
|
+
<h2>Method Details</h2>
|
86
|
+
|
87
|
+
<div class="method_details first">
|
88
|
+
<p class="signature first" id="run!-class_method">
|
89
|
+
|
90
|
+
+ (<tt>Object</tt>) <strong>run!</strong>(args = nil)
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
</p><table class="source_code">
|
95
|
+
<tr>
|
96
|
+
<td>
|
97
|
+
<pre class="lines">
|
98
|
+
|
99
|
+
|
100
|
+
5
|
101
|
+
6
|
102
|
+
7
|
103
|
+
8
|
104
|
+
9
|
105
|
+
10
|
106
|
+
11
|
107
|
+
12
|
108
|
+
13
|
109
|
+
14
|
110
|
+
15
|
111
|
+
16
|
112
|
+
17
|
113
|
+
18
|
114
|
+
19
|
115
|
+
20</pre>
|
116
|
+
</td>
|
117
|
+
<td>
|
118
|
+
<pre class="code"><span class="info file"># File 'lib/reflection/cli.rb', line 5</span>
|
119
|
+
|
120
|
+
<span class='def def kw'>def</span> <span class='run! fid id'>run!</span><span class='lparen token'>(</span><span class='args identifier id'>args</span> <span class='assign token'>=</span> <span class='nil nil kw'>nil</span><span class='rparen token'>)</span>
|
121
|
+
<span class='config identifier id'>config</span> <span class='assign token'>=</span> <span class='Reflection constant id'>Reflection</span><span class='colon2 op'>::</span><span class='Config constant id'>Config</span><span class='dot token'>.</span><span class='parse identifier id'>parse</span><span class='lparen token'>(</span><span class='args identifier id'>args</span><span class='rparen token'>)</span>
|
122
|
+
|
123
|
+
<span class='if if kw'>if</span> <span class='verify_config identifier id'>verify_config</span><span class='lparen token'>(</span><span class='config identifier id'>config</span><span class='rparen token'>)</span> <span class='eq op'>==</span> <span class='false false kw'>false</span>
|
124
|
+
<span class='Reflection constant id'>Reflection</span><span class='colon2 op'>::</span><span class='Support constant id'>Support</span><span class='dot token'>.</span><span class='exit_with_error identifier id'>exit_with_error</span><span class='lparen token'>(</span><span class='string val'>"Ahh ja, missing arguments. Please read 'reflection --help' to get a feeling of how it works."</span><span class='rparen token'>)</span>
|
125
|
+
<span class='else else kw'>else</span>
|
126
|
+
<span class='case case kw'>case</span> <span class='config identifier id'>config</span><span class='dot token'>.</span><span class='command identifier id'>command</span>
|
127
|
+
<span class='when when kw'>when</span> <span class='symbol val'>:apply</span>
|
128
|
+
<span class='Reflection constant id'>Reflection</span><span class='colon2 op'>::</span><span class='Command constant id'>Command</span><span class='colon2 op'>::</span><span class='Apply constant id'>Apply</span><span class='dot token'>.</span><span class='run! fid id'>run!</span><span class='lparen token'>(</span><span class='config identifier id'>config</span><span class='rparen token'>)</span>
|
129
|
+
<span class='when when kw'>when</span> <span class='symbol val'>:stash</span>
|
130
|
+
<span class='Reflection constant id'>Reflection</span><span class='colon2 op'>::</span><span class='Command constant id'>Command</span><span class='colon2 op'>::</span><span class='Stash constant id'>Stash</span><span class='dot token'>.</span><span class='run! fid id'>run!</span><span class='lparen token'>(</span><span class='config identifier id'>config</span><span class='rparen token'>)</span>
|
131
|
+
<span class='else else kw'>else</span>
|
132
|
+
<span class='Reflection constant id'>Reflection</span><span class='colon2 op'>::</span><span class='Support constant id'>Support</span><span class='dot token'>.</span><span class='exit_with_error identifier id'>exit_with_error</span><span class='lparen token'>(</span><span class='string val'>"Couldn't identify command. Please run 'reflection --help'."</span><span class='rparen token'>)</span>
|
133
|
+
<span class='end end kw'>end</span>
|
134
|
+
<span class='end end kw'>end</span>
|
135
|
+
<span class='end end kw'>end</span>
|
136
|
+
</pre>
|
137
|
+
</td>
|
138
|
+
</tr>
|
139
|
+
</table>
|
140
|
+
</div>
|
141
|
+
|
142
|
+
</div>
|
143
|
+
|
144
|
+
</div>
|
145
|
+
|
146
|
+
<div id="footer">
|
147
|
+
Generated on Wed Nov 18 18:17:11 2009 by
|
148
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool">yard</a>
|
149
|
+
0.4.0 (ruby-1.8.7).
|
150
|
+
</div>
|
151
|
+
|
152
|
+
</body>
|
153
|
+
</html>
|