pupu 0.0.3 → 0.0.4.pre

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. data/CHANGELOG +3 -0
  2. data/README.textile +2 -2
  3. data/TODO.txt +8 -3
  4. data/bin/pupu +16 -24
  5. data/examples/merb/.gitignore +7 -11
  6. data/examples/merb/Gemfile +27 -0
  7. data/examples/merb/README.textile +3 -5
  8. data/examples/merb/config/init.rb +7 -0
  9. data/examples/rails/.gitignore +7 -0
  10. data/examples/rails/Gemfile +28 -0
  11. data/examples/rails/README.textile +5 -0
  12. data/examples/rails/Rakefile +10 -0
  13. data/examples/rails/app/controllers/application_controller.rb +10 -0
  14. data/examples/rails/app/controllers/home_controller.rb +8 -0
  15. data/examples/rails/app/helpers/application_helper.rb +3 -0
  16. data/{spec/pupu/adapters/merb_spec.rb → examples/rails/app/views/examples/arguments.html.erb} +0 -0
  17. data/{spec/pupu/adapters/rango_spec.rb → examples/rails/app/views/examples/dependencies.html.erb} +0 -0
  18. data/examples/rails/app/views/examples/simple.html.erb +4 -0
  19. data/examples/rails/app/views/index.html.erb +7 -0
  20. data/examples/rails/app/views/layout.html.erb +12 -0
  21. data/examples/rails/config/boot.rb +110 -0
  22. data/examples/rails/config/environment.rb +55 -0
  23. data/examples/rails/config/environments/development.rb +17 -0
  24. data/examples/rails/config/environments/production.rb +28 -0
  25. data/examples/rails/config/environments/test.rb +28 -0
  26. data/examples/rails/config/initializers/backtrace_silencers.rb +7 -0
  27. data/examples/rails/config/initializers/inflections.rb +10 -0
  28. data/examples/rails/config/initializers/mime_types.rb +5 -0
  29. data/examples/rails/config/initializers/new_rails_defaults.rb +21 -0
  30. data/examples/rails/config/initializers/session_store.rb +15 -0
  31. data/examples/rails/config/routes.rb +43 -0
  32. data/examples/rails/db/seeds.rb +7 -0
  33. data/examples/rails/public/404.html +30 -0
  34. data/examples/rails/public/422.html +30 -0
  35. data/examples/rails/public/500.html +30 -0
  36. data/examples/rails/public/favicon.ico +0 -0
  37. data/examples/rails/public/robots.txt +5 -0
  38. data/examples/rails/script/about +4 -0
  39. data/examples/rails/script/console +3 -0
  40. data/examples/rails/script/dbconsole +3 -0
  41. data/examples/rails/script/destroy +3 -0
  42. data/examples/rails/script/generate +3 -0
  43. data/examples/rails/script/performance/benchmarker +3 -0
  44. data/examples/rails/script/performance/profiler +3 -0
  45. data/examples/rails/script/plugin +3 -0
  46. data/examples/rails/script/runner +3 -0
  47. data/examples/rails/script/server +3 -0
  48. data/examples/rails/spec/application_spec.rb +37 -0
  49. data/examples/rails/spec/spec_helper.rb +0 -0
  50. data/examples/rango/.gitignore +4 -0
  51. data/examples/rango/Gemfile +56 -0
  52. data/examples/rango/README.textile +4 -6
  53. data/examples/rango/init.rb +7 -0
  54. data/gems/cache/media-path-0.1.2.gem +0 -0
  55. data/gems/cache/nake-0.0.8.gem +0 -0
  56. data/gems/cache/rspec-1.3.0.gem +0 -0
  57. data/gems/cache/term-ansicolor-1.0.4.gem +0 -0
  58. data/lib/pupu.rb +2 -1
  59. data/lib/pupu/adapters/merb.rb +2 -0
  60. data/lib/pupu/adapters/rails.rb +2 -0
  61. data/lib/pupu/adapters/rango.rb +2 -0
  62. data/lib/pupu/cli.rb +2 -0
  63. data/lib/pupu/dsl.rb +2 -0
  64. data/lib/pupu/exceptions.rb +2 -0
  65. data/lib/pupu/github.rb +2 -0
  66. data/lib/pupu/helpers.rb +2 -0
  67. data/lib/pupu/metadata.rb +2 -0
  68. data/lib/pupu/parser.rb +2 -0
  69. data/lib/pupu/pupu.rb +2 -0
  70. data/lib/pupu/version.rb +5 -0
  71. data/pupu.gemspec +2 -1
  72. data/spec/data/public/pupu/autocompleter/config.rb +2 -0
  73. data/spec/pupu/dsl_spec.rb +3 -0
  74. data/spec/pupu/exceptions_spec.rb +3 -0
  75. data/spec/pupu/github_spec.rb +3 -0
  76. data/spec/pupu/helpers_spec.rb +4 -1
  77. data/spec/pupu/metadata_spec.rb +3 -0
  78. data/spec/pupu/parser_spec.rb +3 -0
  79. data/spec/pupu/pupu_spec.rb +3 -0
  80. data/tasks.rb +3 -2
  81. metadata +53 -9
File without changes
@@ -0,0 +1,4 @@
1
+ # You usually don't want to ignore gems/cache, but examples are
2
+ # part of the pupu gem and we want to keep it as small as possible
3
+ gems/*
4
+ bin/*
@@ -0,0 +1,56 @@
1
+ # encoding: utf-8
2
+
3
+ # === Usage === #
4
+ # Run gem bundle for installation. You have to have bundler gem installed.
5
+
6
+ # http://github.com/wycats/bundler
7
+ # http://litanyagainstfear.com/blog/2009/10/14/gem-bundler-is-the-future
8
+ # http://yehudakatz.com/2009/11/03/using-the-new-gem-bundler-today
9
+ # http://www.engineyard.com/blog/2009/using-the-rubygems-bundler-for-your-app
10
+
11
+ # === Shared Gems === #
12
+ # Specify a dependency on rango. When the bundler downloads gems,
13
+ # it will download rango as well as all of rango' dependencies
14
+
15
+ # rango stack
16
+ gem "rango"#, git: "git://github.com/botanicus/rango.git"
17
+ gem "rack"#, git: "git://github.com/rack/rack.git"
18
+ gem "tilt"#, git: "git://github.com/rtomayko/tilt.git"
19
+
20
+ # router
21
+ gem "usher"#, git: "git://github.com/joshbuddy/usher.git"
22
+
23
+ # template engine
24
+ gem "haml"#, git: "git://github.com/nex3/haml.git"
25
+
26
+ # NOTE: do not use require_as: nil because if you do so, bundler will require the library anyway
27
+ # Check last section of http://wiki.github.com/merb/merb/howto-using-the-bundler for more informations
28
+ only(:bundle) do
29
+ gem "thin"#, git: "git://github.com/macournoyer/thin.git" # there seems to be some problems with latest thin
30
+ #gem "unicorn"#, git: "git://repo.or.cz/unicorn.git"
31
+ gem "racksh"#, git: "git://github.com/sickill/racksh.git"
32
+ gem "shotgun"#, git: "git://github.com/rtomayko/shotgun.git"
33
+ end
34
+
35
+ gem "simple-logger"#, git: "git://github.com/botanicus/simple-logger.git"
36
+ gem "media-path"#, git: "git://github.com/botanicus/media-path.git"
37
+
38
+ # === Environment-Specific Setup === #
39
+ only(:test) do
40
+ gem "rspec"#, git: "git://github.com/dchelimsky/rspec.git"
41
+ gem "rack-test", require_as: "rack/test"#, git: "git://github.com/brynary/rack-test.git"
42
+ end
43
+
44
+ # === Bundler Setup === #
45
+ # Specify where the bundled gems should be stashed. This directory will
46
+ # be a gem repository where all gems are downloaded to and installed to.
47
+ #
48
+ # This is an optional setting.
49
+ # The default is: vendor/gems
50
+ bundle_path "gems"
51
+
52
+ # Specify where gem executables should be copied to.
53
+ #
54
+ # This is an optional setting.
55
+ # The default is: bin
56
+ bin_path "bin"
@@ -1,7 +1,5 @@
1
- h1. Rango Example
1
+ h1. Merb Example
2
2
 
3
- * Dependencies for running: @rango@, @usher@, @haml@
4
- * Run with @./config.ru@ (will start at @http://localhost:4000@)
5
-
6
- * Dependencies for testing: @rspec@, @webrat@, @rack-test@
7
- * Specs: @spec spec/pupu_spec.rb --colour@
3
+ * @gem bundle@ (you have to have bundler 0.7.2 installed)
4
+ * Run with @./bin/merb -a webrick@ (will start at @http://localhost:4000@)
5
+ * Specs: @./bin/spec spec/application_spec.rb --colour@
@@ -4,6 +4,13 @@
4
4
  # === Usage === #
5
5
  # init.rb
6
6
 
7
+ # bundler
8
+ begin
9
+ require_relative "gems/environment.rb"
10
+ rescue LoadError => exception
11
+ abort "LoadError during loading gems/environment: #{exception.message}\nRun gem bundle to fix it."
12
+ end
13
+
7
14
  # setup $:
8
15
  pupu_libdir = File.expand_path("../../lib")
9
16
  raise Errno::ENOENT, "#{pupu_libdir} doesn't exist" unless File.directory?(pupu_libdir)
Binary file
Binary file
Binary file
Binary file
data/lib/pupu.rb CHANGED
@@ -1,7 +1,8 @@
1
+ # encoding: utf-8
2
+
1
3
  require "media-path"
2
4
  require "pupu/exceptions"
3
5
  require "pupu/pupu"
4
6
 
5
7
  module Pupu
6
- VERSION ||= "0.0.2"
7
8
  end
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "pupu"
2
4
  require "pupu/helpers"
3
5
 
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "pupu"
2
4
  require "pupu/helpers"
3
5
 
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "pupu"
2
4
  require "pupu/helpers"
3
5
 
data/lib/pupu/cli.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "fileutils"
2
4
  require "yaml"
3
5
  require "ostruct"
data/lib/pupu/dsl.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "ostruct"
2
4
  require "media-path"
3
5
 
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  module Pupu
2
4
  class PupuRootNotFound < StandardError
3
5
  end
data/lib/pupu/github.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "fileutils"
2
4
  require "yaml"
3
5
  require "ostruct"
data/lib/pupu/helpers.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "pupu/parser"
2
4
 
3
5
  module Pupu
data/lib/pupu/metadata.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  module Pupu
2
4
  class Metadata
3
5
  class << self
data/lib/pupu/parser.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "pupu/dsl"
2
4
  require "pupu/pupu"
3
5
 
data/lib/pupu/pupu.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  require "yaml"
2
4
  require "ostruct"
3
5
  require "fileutils"
@@ -0,0 +1,5 @@
1
+ # encoding: utf-8
2
+
3
+ module Pupu
4
+ VERSION = "0.0.4"
5
+ end
data/pupu.gemspec CHANGED
@@ -2,10 +2,11 @@
2
2
  # encoding: utf-8
3
3
 
4
4
  require "base64"
5
+ require File.join(File.dirname(__FILE__), "lib/pupu/version")
5
6
 
6
7
  Gem::Specification.new do |s|
7
8
  s.name = "pupu"
8
- s.version = "0.0.3"
9
+ s.version = Pupu::VERSION
9
10
  s.authors = ["Jakub Šťastný aka Botanicus"]
10
11
  s.homepage = "http://github.com/botanicus/pupu"
11
12
  s.summary = "Framework-agnostic package system for media files"
@@ -1,3 +1,5 @@
1
+ # encoding: utf-8
2
+
1
3
  # autocompleter depends on mootools
2
4
  dependencies :mootools
3
5
 
@@ -1,4 +1,7 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/dsl"
3
6
  require "pupu/pupu"
4
7
 
@@ -1,4 +1,7 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/exceptions"
3
6
 
4
7
  describe Pupu::PupuRootNotFound do
@@ -1,4 +1,7 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/github"
3
6
 
4
7
  # TODO
@@ -1,9 +1,12 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/pupu"
3
6
  require "pupu/helpers"
4
- include Pupu::Helpers
5
7
 
6
8
  describe "Helpers#pupu" do
9
+ include Pupu::Helpers
7
10
  before(:each) do
8
11
  Pupu.root = File.dirname(__FILE__) + "/data/root/pupu"
9
12
  end
@@ -1,4 +1,7 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/metadata"
3
6
 
4
7
  describe Pupu do
@@ -1,4 +1,7 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/parser"
3
6
 
4
7
  # TODO
@@ -1,4 +1,7 @@
1
+ # encoding: utf-8
2
+
1
3
  require_relative "../spec_helper"
4
+
2
5
  require "pupu/pupu"
3
6
 
4
7
  describe Pupu::Pupu do
data/tasks.rb CHANGED
@@ -7,8 +7,11 @@ rescue LoadError
7
7
  abort "You have to install bundler and run gem bundle first!"
8
8
  end
9
9
 
10
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), "lib"))
11
+
10
12
  ENV["PATH"] = "script:#{ENV["PATH"]}"
11
13
 
14
+ require "pupu/version"
12
15
  require "nake/tasks/gem"
13
16
  require "nake/tasks/spec"
14
17
  require "nake/tasks/release"
@@ -24,8 +27,6 @@ rescue LoadError
24
27
  warn "If you want to contribute to Pupu, please install code-cleaner and then run ./tasks.rb hooks:whitespace:install to get Git pre-commit hook for removing trailing whitespace."
25
28
  end
26
29
 
27
- require_relative "lib/pupu"
28
-
29
30
  # Setup encoding, so all the operations
30
31
  # with strings from another files will work
31
32
  Encoding.default_internal = "utf-8"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pupu
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4.pre
5
5
  platform: ruby
6
6
  authors:
7
7
  - "Jakub \xC5\xA0\xC5\xA5astn\xC3\xBD aka Botanicus"
@@ -49,6 +49,7 @@ files:
49
49
  - bin/pupu
50
50
  - deps.rip
51
51
  - examples/merb/.gitignore
52
+ - examples/merb/Gemfile
52
53
  - examples/merb/README.textile
53
54
  - examples/merb/Rakefile
54
55
  - examples/merb/application.rb
@@ -161,6 +162,49 @@ files:
161
162
  - examples/merb/views/examples/simple.html.erb
162
163
  - examples/merb/views/index.html.erb
163
164
  - examples/merb/views/layout.html.erb
165
+ - examples/rails/.gitignore
166
+ - examples/rails/Gemfile
167
+ - examples/rails/README.textile
168
+ - examples/rails/Rakefile
169
+ - examples/rails/app/controllers/application_controller.rb
170
+ - examples/rails/app/controllers/home_controller.rb
171
+ - examples/rails/app/helpers/application_helper.rb
172
+ - examples/rails/app/views/examples/arguments.html.erb
173
+ - examples/rails/app/views/examples/dependencies.html.erb
174
+ - examples/rails/app/views/examples/simple.html.erb
175
+ - examples/rails/app/views/index.html.erb
176
+ - examples/rails/app/views/layout.html.erb
177
+ - examples/rails/config/boot.rb
178
+ - examples/rails/config/environment.rb
179
+ - examples/rails/config/environments/development.rb
180
+ - examples/rails/config/environments/production.rb
181
+ - examples/rails/config/environments/test.rb
182
+ - examples/rails/config/initializers/backtrace_silencers.rb
183
+ - examples/rails/config/initializers/inflections.rb
184
+ - examples/rails/config/initializers/mime_types.rb
185
+ - examples/rails/config/initializers/new_rails_defaults.rb
186
+ - examples/rails/config/initializers/session_store.rb
187
+ - examples/rails/config/routes.rb
188
+ - examples/rails/db/seeds.rb
189
+ - examples/rails/public/404.html
190
+ - examples/rails/public/422.html
191
+ - examples/rails/public/500.html
192
+ - examples/rails/public/favicon.ico
193
+ - examples/rails/public/robots.txt
194
+ - examples/rails/script/about
195
+ - examples/rails/script/console
196
+ - examples/rails/script/dbconsole
197
+ - examples/rails/script/destroy
198
+ - examples/rails/script/generate
199
+ - examples/rails/script/performance/benchmarker
200
+ - examples/rails/script/performance/profiler
201
+ - examples/rails/script/plugin
202
+ - examples/rails/script/runner
203
+ - examples/rails/script/server
204
+ - examples/rails/spec/application_spec.rb
205
+ - examples/rails/spec/spec_helper.rb
206
+ - examples/rango/.gitignore
207
+ - examples/rango/Gemfile
164
208
  - examples/rango/README.textile
165
209
  - examples/rango/Rakefile
166
210
  - examples/rango/config.ru
@@ -274,6 +318,10 @@ files:
274
318
  - examples/rango/templates/examples/dependencies.html.haml
275
319
  - examples/rango/templates/examples/simple.html.haml
276
320
  - examples/rango/templates/index.html.haml
321
+ - gems/cache/media-path-0.1.2.gem
322
+ - gems/cache/nake-0.0.8.gem
323
+ - gems/cache/rspec-1.3.0.gem
324
+ - gems/cache/term-ansicolor-1.0.4.gem
277
325
  - lib/pupu.rb
278
326
  - lib/pupu/adapters/merb.rb
279
327
  - lib/pupu/adapters/rails.rb
@@ -288,9 +336,9 @@ files:
288
336
  - lib/pupu/pupu.rb
289
337
  - lib/pupu/tasks/pupu.rake
290
338
  - lib/pupu/tasks/pupu.thor
339
+ - lib/pupu/version.rb
291
340
  - pupu.gemspec
292
341
  - pupu.pre.gemspec
293
- - script/spec
294
342
  - simple-templater.scope
295
343
  - spec/data/public/pupu/autocompleter/.gitignore
296
344
  - spec/data/public/pupu/autocompleter/CHANGELOG
@@ -306,8 +354,6 @@ files:
306
354
  - spec/data/public/pupu/autocompleter/javascripts/autocompleter.request.js
307
355
  - spec/data/public/pupu/autocompleter/javascripts/observer.js
308
356
  - spec/data/public/pupu/autocompleter/stylesheets/autocompleter.css
309
- - spec/pupu/adapters/merb_spec.rb
310
- - spec/pupu/adapters/rango_spec.rb
311
357
  - spec/pupu/cli_spec.rb
312
358
  - spec/pupu/dsl_spec.rb
313
359
  - spec/pupu/exceptions_spec.rb
@@ -337,9 +383,7 @@ has_rdoc: true
337
383
  homepage: http://github.com/botanicus/pupu
338
384
  licenses: []
339
385
 
340
- post_install_message: "[\e[32mVersion 0.0.3\e[0m] Bug fixes\n\
341
- [\e[32mVersion 0.0.3\e[0m] Refactoring\n\
342
- [\e[32mVersion 0.0.3\e[0m] Examples\n"
386
+ post_install_message: "[\e[32mVersion 0.0.4\e[0m] Added Rails example app\n"
343
387
  rdoc_options: []
344
388
 
345
389
  require_paths:
@@ -352,9 +396,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
352
396
  version:
353
397
  required_rubygems_version: !ruby/object:Gem::Requirement
354
398
  requirements:
355
- - - ">="
399
+ - - ">"
356
400
  - !ruby/object:Gem::Version
357
- version: "0"
401
+ version: 1.3.1
358
402
  version:
359
403
  requirements: []
360
404