rjspotter-ramaze 2009.06.29
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/.gitignore +3 -0
- data/.mailmap +25 -0
- data/MANIFEST +502 -0
- data/README.md +457 -0
- data/Rakefile +88 -0
- data/benchmark/bench_templates/bench.rb +67 -0
- data/benchmark/bench_templates/view/large.erb +79 -0
- data/benchmark/bench_templates/view/large.haml +41 -0
- data/benchmark/bench_templates/view/large.xhtml +79 -0
- data/benchmark/bench_templates/view/small.erb +21 -0
- data/benchmark/bench_templates/view/small.haml +12 -0
- data/benchmark/bench_templates/view/small.xhtml +21 -0
- data/benchmark/results.txt +131 -0
- data/benchmark/run.rb +355 -0
- data/benchmark/suite/minimal.rb +11 -0
- data/benchmark/suite/no_informer.rb +7 -0
- data/benchmark/suite/no_sessions.rb +9 -0
- data/benchmark/suite/no_template.rb +7 -0
- data/benchmark/suite/simple.rb +5 -0
- data/benchmark/suite/template_erubis.rb +8 -0
- data/benchmark/suite/template_etanni.rb +8 -0
- data/benchmark/suite/template_ezamar.rb +8 -0
- data/benchmark/suite/template_haml.rb +13 -0
- data/benchmark/suite/template_liquid.rb +11 -0
- data/benchmark/suite/template_markaby.rb +9 -0
- data/benchmark/suite/template_nagoro.rb +8 -0
- data/benchmark/suite/template_redcloth.rb +13 -0
- data/benchmark/suite/template_tenjin.rb +8 -0
- data/benchmark/test.rb +35 -0
- data/bin/ramaze +15 -0
- data/doc/AUTHORS +44 -0
- data/doc/CHANGELOG +17362 -0
- data/doc/COPYING +56 -0
- data/doc/FAQ +92 -0
- data/doc/GPL +339 -0
- data/doc/INSTALL +92 -0
- data/doc/LEGAL +26 -0
- data/doc/TODO +29 -0
- data/doc/meta/announcement.txt +146 -0
- data/doc/meta/configuration.txt +163 -0
- data/doc/meta/internals.txt +278 -0
- data/doc/meta/users.kml +64 -0
- data/doc/tutorial/todolist.html +1379 -0
- data/doc/tutorial/todolist.txt +920 -0
- data/examples/app/auth/layout/auth.xhtml +25 -0
- data/examples/app/auth/start.rb +23 -0
- data/examples/app/auth/view/index.xhtml +4 -0
- data/examples/app/auth/view/login.xhtml +20 -0
- data/examples/app/auth/view/secret.xhtml +1 -0
- data/examples/app/blog/README +3 -0
- data/examples/app/blog/app.rb +69 -0
- data/examples/app/blog/config.ru +17 -0
- data/examples/app/blog/controller/comment.rb +45 -0
- data/examples/app/blog/controller/entry.rb +85 -0
- data/examples/app/blog/controller/init.rb +86 -0
- data/examples/app/blog/controller/main.rb +20 -0
- data/examples/app/blog/controller/tag.rb +9 -0
- data/examples/app/blog/layout/default.nag +31 -0
- data/examples/app/blog/model/comment.rb +58 -0
- data/examples/app/blog/model/entry.rb +89 -0
- data/examples/app/blog/model/init.rb +15 -0
- data/examples/app/blog/model/tag.rb +36 -0
- data/examples/app/blog/public/css/screen.css +273 -0
- data/examples/app/blog/spec/blog.rb +87 -0
- data/examples/app/blog/start.rb +5 -0
- data/examples/app/blog/view/comment/form.nag +10 -0
- data/examples/app/blog/view/comment/show.nag +16 -0
- data/examples/app/blog/view/entry/edit.nag +14 -0
- data/examples/app/blog/view/entry/feed.atom.nag +8 -0
- data/examples/app/blog/view/entry/feed.rss.nag +7 -0
- data/examples/app/blog/view/entry/index.nag +7 -0
- data/examples/app/blog/view/entry/new.nag +13 -0
- data/examples/app/blog/view/entry/show.nag +36 -0
- data/examples/app/blog/view/feed.atom.nag +18 -0
- data/examples/app/blog/view/feed.rss.nag +25 -0
- data/examples/app/blog/view/index.nag +6 -0
- data/examples/app/blog/view/tag/index.nag +5 -0
- data/examples/app/chat/layout/default.xhtml +13 -0
- data/examples/app/chat/model/history.rb +38 -0
- data/examples/app/chat/model/message.rb +7 -0
- data/examples/app/chat/public/css/chat.css +9 -0
- data/examples/app/chat/public/js/chat.js +28 -0
- data/examples/app/chat/public/js/jquery.js +3436 -0
- data/examples/app/chat/start.rb +39 -0
- data/examples/app/chat/view/chat.xhtml +9 -0
- data/examples/app/chat/view/index.xhtml +7 -0
- data/examples/app/localization/locale/de.yaml +5 -0
- data/examples/app/localization/locale/en.yaml +5 -0
- data/examples/app/localization/locale/ja.yaml +5 -0
- data/examples/app/localization/start.rb +48 -0
- data/examples/app/sourceview/public/coderay.css +104 -0
- data/examples/app/sourceview/public/images/file.gif +0 -0
- data/examples/app/sourceview/public/images/folder.gif +0 -0
- data/examples/app/sourceview/public/images/tv-collapsable-last.gif +0 -0
- data/examples/app/sourceview/public/images/tv-collapsable.gif +0 -0
- data/examples/app/sourceview/public/images/tv-expandable-last.gif +0 -0
- data/examples/app/sourceview/public/images/tv-expandable.gif +0 -0
- data/examples/app/sourceview/public/images/tv-item-last.gif +0 -0
- data/examples/app/sourceview/public/images/tv-item.gif +0 -0
- data/examples/app/sourceview/public/jquery.js +11 -0
- data/examples/app/sourceview/public/jquery.treeview.css +48 -0
- data/examples/app/sourceview/public/jquery.treeview.js +223 -0
- data/examples/app/sourceview/public/sourceview.js +52 -0
- data/examples/app/sourceview/start.rb +79 -0
- data/examples/app/sourceview/view/index.haml +59 -0
- data/examples/app/todolist/controller/init.rb +10 -0
- data/examples/app/todolist/controller/task.rb +39 -0
- data/examples/app/todolist/layout/default.xhtml +14 -0
- data/examples/app/todolist/model/init.rb +14 -0
- data/examples/app/todolist/model/task.rb +39 -0
- data/examples/app/todolist/public/css/screen.css +63 -0
- data/examples/app/todolist/public/favicon.ico +0 -0
- data/examples/app/todolist/start.rb +11 -0
- data/examples/app/todolist/view/index.xhtml +29 -0
- data/examples/app/upload/start.rb +19 -0
- data/examples/app/upload/view/index.xhtml +25 -0
- data/examples/app/whywiki/spec/whywiki.rb +58 -0
- data/examples/app/whywiki/start.rb +46 -0
- data/examples/app/whywiki/template/edit.xhtml +14 -0
- data/examples/app/whywiki/template/show.xhtml +18 -0
- data/examples/app/wikore/spec/wikore.rb +109 -0
- data/examples/app/wikore/src/controller.rb +78 -0
- data/examples/app/wikore/src/model.rb +56 -0
- data/examples/app/wikore/start.rb +9 -0
- data/examples/app/wikore/view/index.xhtml +8 -0
- data/examples/app/wiktacular/README +2 -0
- data/examples/app/wiktacular/mkd/link/2007-07-20_19-45-51.mkd +1 -0
- data/examples/app/wiktacular/mkd/link/current.mkd +1 -0
- data/examples/app/wiktacular/mkd/main/2007-07-20_16-31-33.mkd +1 -0
- data/examples/app/wiktacular/mkd/main/2007-07-20_19-21-12.mkd +1 -0
- data/examples/app/wiktacular/mkd/main/2007-07-20_19-23-10.mkd +2 -0
- data/examples/app/wiktacular/mkd/main/2007-07-20_19-45-07.mkd +2 -0
- data/examples/app/wiktacular/mkd/main/current.mkd +2 -0
- data/examples/app/wiktacular/mkd/markdown/current.mkd +3 -0
- data/examples/app/wiktacular/mkd/testing/2007-07-20_16-43-46.mkd +2 -0
- data/examples/app/wiktacular/mkd/testing/2007-07-20_19-43-50.mkd +3 -0
- data/examples/app/wiktacular/mkd/testing/2007-07-21_18-46-01.mkd +11 -0
- data/examples/app/wiktacular/mkd/testing/2007-07-21_18-46-32.mkd +13 -0
- data/examples/app/wiktacular/mkd/testing/2007-07-21_18-47-08.mkd +17 -0
- data/examples/app/wiktacular/mkd/testing/2007-07-21_18-47-54.mkd +17 -0
- data/examples/app/wiktacular/mkd/testing/current.mkd +17 -0
- data/examples/app/wiktacular/public/favicon.ico +0 -0
- data/examples/app/wiktacular/public/screen.css +72 -0
- data/examples/app/wiktacular/spec/wiktacular.rb +157 -0
- data/examples/app/wiktacular/src/controller.rb +55 -0
- data/examples/app/wiktacular/src/model.rb +102 -0
- data/examples/app/wiktacular/start.rb +8 -0
- data/examples/app/wiktacular/template/edit.xhtml +6 -0
- data/examples/app/wiktacular/template/html_layout.xhtml +27 -0
- data/examples/app/wiktacular/template/index.xhtml +9 -0
- data/examples/app/wiktacular/template/new.xhtml +6 -0
- data/examples/basic/element.rb +47 -0
- data/examples/basic/gestalt.rb +26 -0
- data/examples/basic/hello.rb +14 -0
- data/examples/basic/layout.rb +28 -0
- data/examples/basic/linking.rb +29 -0
- data/examples/basic/partial.rb +26 -0
- data/examples/basic/simple.rb +52 -0
- data/examples/helpers/cache.rb +33 -0
- data/examples/helpers/form_with_sequel.rb +24 -0
- data/examples/helpers/httpdigest.rb +107 -0
- data/examples/helpers/identity.rb +18 -0
- data/examples/helpers/nitro_form.rb +23 -0
- data/examples/helpers/paginate.rb +71 -0
- data/examples/helpers/rest.rb +28 -0
- data/examples/helpers/simple_captcha.rb +29 -0
- data/examples/misc/css.rb +37 -0
- data/examples/misc/facebook.rb +159 -0
- data/examples/misc/memleak_detector.rb +37 -0
- data/examples/misc/nagoro_element.rb +43 -0
- data/examples/misc/ramaise.rb +132 -0
- data/examples/misc/rapp.rb +56 -0
- data/examples/misc/sequel_scaffolding.rb +34 -0
- data/examples/misc/serve_directory.rb +6 -0
- data/examples/templates/template_erubis.rb +52 -0
- data/examples/templates/template_ezamar.rb +51 -0
- data/examples/templates/template_haml.rb +49 -0
- data/examples/templates/template_liquid.rb +66 -0
- data/examples/templates/template_markaby.rb +57 -0
- data/examples/templates/template_nagoro.rb +50 -0
- data/examples/templates/template_redcloth.rb +58 -0
- data/examples/templates/template_remarkably.rb +54 -0
- data/examples/templates/template_tenjin.rb +52 -0
- data/examples/templates/view/external.haml +22 -0
- data/examples/templates/view/external.liquid +28 -0
- data/examples/templates/view/external.mab +30 -0
- data/examples/templates/view/external.nag +28 -0
- data/examples/templates/view/external.redcloth +19 -0
- data/examples/templates/view/external.rem +30 -0
- data/examples/templates/view/external.rhtml +28 -0
- data/examples/templates/view/external.tenjin +28 -0
- data/examples/templates/view/external.zmr +28 -0
- data/lib/proto/app.rb +14 -0
- data/lib/proto/config.ru +20 -0
- data/lib/proto/controller/init.rb +11 -0
- data/lib/proto/controller/main.rb +20 -0
- data/lib/proto/layout/default.xhtml +24 -0
- data/lib/proto/model/init.rb +4 -0
- data/lib/proto/public/.htaccess +24 -0
- data/lib/proto/public/css/screen.css +30 -0
- data/lib/proto/public/dispatch.fcgi +11 -0
- data/lib/proto/public/favicon.ico +0 -0
- data/lib/proto/public/js/jquery.js +4376 -0
- data/lib/proto/public/ramaze.png +0 -0
- data/lib/proto/spec/main.rb +20 -0
- data/lib/proto/start.rb +8 -0
- data/lib/proto/view/index.xhtml +41 -0
- data/lib/ramaze.rb +87 -0
- data/lib/ramaze/app.rb +124 -0
- data/lib/ramaze/cache.rb +19 -0
- data/lib/ramaze/cache/localmemcache.rb +56 -0
- data/lib/ramaze/cache/memcache.rb +124 -0
- data/lib/ramaze/cache/sequel.rb +82 -0
- data/lib/ramaze/contrib/addressable_route.rb +55 -0
- data/lib/ramaze/contrib/app_graph.rb +64 -0
- data/lib/ramaze/contrib/email.rb +88 -0
- data/lib/ramaze/contrib/facebook.rb +23 -0
- data/lib/ramaze/contrib/facebook/facebook.rb +171 -0
- data/lib/ramaze/contrib/gettext.rb +113 -0
- data/lib/ramaze/contrib/gettext/mo.rb +155 -0
- data/lib/ramaze/contrib/gettext/parser.rb +46 -0
- data/lib/ramaze/contrib/gettext/po.rb +109 -0
- data/lib/ramaze/contrib/gzip_filter.rb +1 -0
- data/lib/ramaze/contrib/maruku_uv.rb +59 -0
- data/lib/ramaze/contrib/profiling.rb +36 -0
- data/lib/ramaze/contrib/rest.rb +22 -0
- data/lib/ramaze/contrib/sequel/create_join.rb +26 -0
- data/lib/ramaze/contrib/sequel/form_field.rb +129 -0
- data/lib/ramaze/contrib/sequel/image.rb +196 -0
- data/lib/ramaze/contrib/sequel/relation.rb +98 -0
- data/lib/ramaze/controller.rb +104 -0
- data/lib/ramaze/controller/default.rb +12 -0
- data/lib/ramaze/current.rb +7 -0
- data/lib/ramaze/files.rb +24 -0
- data/lib/ramaze/gestalt.rb +132 -0
- data/lib/ramaze/helper.rb +13 -0
- data/lib/ramaze/helper/auth.rb +84 -0
- data/lib/ramaze/helper/bench.rb +41 -0
- data/lib/ramaze/helper/cache.rb +117 -0
- data/lib/ramaze/helper/disqus.rb +26 -0
- data/lib/ramaze/helper/flash.rb +62 -0
- data/lib/ramaze/helper/form.rb +127 -0
- data/lib/ramaze/helper/formatting.rb +189 -0
- data/lib/ramaze/helper/gestalt.rb +47 -0
- data/lib/ramaze/helper/gravatar.rb +79 -0
- data/lib/ramaze/helper/httpdigest.rb +97 -0
- data/lib/ramaze/helper/identity.rb +119 -0
- data/lib/ramaze/helper/layout.rb +97 -0
- data/lib/ramaze/helper/link.rb +56 -0
- data/lib/ramaze/helper/localize.rb +138 -0
- data/lib/ramaze/helper/markaby.rb +31 -0
- data/lib/ramaze/helper/maruku.rb +16 -0
- data/lib/ramaze/helper/nitroform.rb +14 -0
- data/lib/ramaze/helper/pager.rb +367 -0
- data/lib/ramaze/helper/paginate.rb +242 -0
- data/lib/ramaze/helper/partial.rb +100 -0
- data/lib/ramaze/helper/remarkably.rb +14 -0
- data/lib/ramaze/helper/request_accessor.rb +16 -0
- data/lib/ramaze/helper/sequel.rb +55 -0
- data/lib/ramaze/helper/sequel_form.rb +284 -0
- data/lib/ramaze/helper/simple_captcha.rb +61 -0
- data/lib/ramaze/helper/stack.rb +75 -0
- data/lib/ramaze/helper/tagz.rb +19 -0
- data/lib/ramaze/helper/thread.rb +17 -0
- data/lib/ramaze/helper/ultraviolet.rb +46 -0
- data/lib/ramaze/helper/user.rb +229 -0
- data/lib/ramaze/helper/xhtml.rb +34 -0
- data/lib/ramaze/log.rb +39 -0
- data/lib/ramaze/log/analogger.rb +39 -0
- data/lib/ramaze/log/growl.rb +38 -0
- data/lib/ramaze/log/hub.rb +41 -0
- data/lib/ramaze/log/informer.rb +129 -0
- data/lib/ramaze/log/knotify.rb +28 -0
- data/lib/ramaze/log/logger.rb +26 -0
- data/lib/ramaze/log/logging.rb +83 -0
- data/lib/ramaze/log/rotatinginformer.rb +168 -0
- data/lib/ramaze/log/syslog.rb +51 -0
- data/lib/ramaze/log/xosd.rb +92 -0
- data/lib/ramaze/middleware_compiler.rb +13 -0
- data/lib/ramaze/plugin.rb +69 -0
- data/lib/ramaze/reloader.rb +172 -0
- data/lib/ramaze/reloader/watch_inotify.rb +85 -0
- data/lib/ramaze/reloader/watch_stat.rb +58 -0
- data/lib/ramaze/request.rb +115 -0
- data/lib/ramaze/response.rb +36 -0
- data/lib/ramaze/setup.rb +123 -0
- data/lib/ramaze/snippets.rb +22 -0
- data/lib/ramaze/snippets/array/put_within.rb +44 -0
- data/lib/ramaze/snippets/binding/locals.rb +25 -0
- data/lib/ramaze/snippets/blankslate.rb +7 -0
- data/lib/ramaze/snippets/fiber.rb +63 -0
- data/lib/ramaze/snippets/kernel/pretty_inspect.rb +21 -0
- data/lib/ramaze/snippets/metaid.rb +17 -0
- data/lib/ramaze/snippets/numeric/filesize_format.rb +32 -0
- data/lib/ramaze/snippets/numeric/time.rb +63 -0
- data/lib/ramaze/snippets/object/__dir__.rb +29 -0
- data/lib/ramaze/snippets/object/instance_variable_defined.rb +19 -0
- data/lib/ramaze/snippets/object/pretty.rb +16 -0
- data/lib/ramaze/snippets/object/scope.rb +18 -0
- data/lib/ramaze/snippets/ordered_set.rb +51 -0
- data/lib/ramaze/snippets/proc/locals.rb +19 -0
- data/lib/ramaze/snippets/ramaze/acquire.rb +31 -0
- data/lib/ramaze/snippets/ramaze/deprecated.rb +23 -0
- data/lib/ramaze/snippets/ramaze/dictionary.rb +400 -0
- data/lib/ramaze/snippets/ramaze/fiber.rb +24 -0
- data/lib/ramaze/snippets/ramaze/struct.rb +45 -0
- data/lib/ramaze/snippets/string/camel_case.rb +21 -0
- data/lib/ramaze/snippets/string/color.rb +31 -0
- data/lib/ramaze/snippets/string/end_with.rb +20 -0
- data/lib/ramaze/snippets/string/esc.rb +34 -0
- data/lib/ramaze/snippets/string/ord.rb +21 -0
- data/lib/ramaze/snippets/string/snake_case.rb +21 -0
- data/lib/ramaze/snippets/string/start_with.rb +19 -0
- data/lib/ramaze/snippets/string/unindent.rb +28 -0
- data/lib/ramaze/snippets/thread/into.rb +18 -0
- data/lib/ramaze/spec.rb +33 -0
- data/lib/ramaze/spec/bacon.rb +34 -0
- data/lib/ramaze/spec/helper/bacon.rb +8 -0
- data/lib/ramaze/spec/helper/pretty_output.rb +82 -0
- data/lib/ramaze/spec/helper/snippets.rb +16 -0
- data/lib/ramaze/spec/helper/template_examples.rb +19 -0
- data/lib/ramaze/tool/bin.rb +340 -0
- data/lib/ramaze/tool/create.rb +48 -0
- data/lib/ramaze/tool/project_creator.rb +111 -0
- data/lib/ramaze/version.rb +3 -0
- data/lib/ramaze/view.rb +39 -0
- data/lib/ramaze/view/erubis.rb +23 -0
- data/lib/ramaze/view/ezamar.rb +23 -0
- data/lib/ramaze/view/gestalt.rb +14 -0
- data/lib/ramaze/view/haml.rb +16 -0
- data/lib/ramaze/view/liquid.rb +100 -0
- data/lib/ramaze/view/maruku.rb +15 -0
- data/lib/ramaze/view/nagoro.rb +44 -0
- data/lib/ramaze/view/nagoro/render_partial.rb +32 -0
- data/lib/ramaze/view/redcloth.rb +21 -0
- data/lib/ramaze/view/remarkably.rb +21 -0
- data/lib/ramaze/view/sass.rb +21 -0
- data/lib/ramaze/view/tagz.rb +63 -0
- data/lib/ramaze/view/tenjin.rb +32 -0
- data/lib/vendor/etag.rb +22 -0
- data/lib/vendor/route_exceptions.rb +42 -0
- data/ramaze.gemspec +85 -0
- data/spec/contrib/addressable_route.rb +32 -0
- data/spec/contrib/rest.rb +28 -0
- data/spec/examples/caching.rb +16 -0
- data/spec/examples/css.rb +14 -0
- data/spec/examples/element.rb +15 -0
- data/spec/examples/hello.rb +10 -0
- data/spec/examples/helpers/httpdigest.rb +64 -0
- data/spec/examples/linking.rb +17 -0
- data/spec/examples/simple.rb +40 -0
- data/spec/examples/templates/template_erubis.rb +10 -0
- data/spec/examples/templates/template_ezamar.rb +10 -0
- data/spec/examples/templates/template_haml.rb +10 -0
- data/spec/examples/templates/template_liquid.rb +10 -0
- data/spec/examples/templates/template_markaby.rb +11 -0
- data/spec/examples/templates/template_nagoro.rb +10 -0
- data/spec/examples/templates/template_redcloth.rb +10 -0
- data/spec/examples/templates/template_remarkably.rb +10 -0
- data/spec/examples/templates/template_tenjin.rb +10 -0
- data/spec/helper.rb +9 -0
- data/spec/ramaze/action/render.rb +21 -0
- data/spec/ramaze/action/view/bar.xhtml +1 -0
- data/spec/ramaze/action/view/instancevars/layout.xhtml +1 -0
- data/spec/ramaze/action/view/other_wrapper.erb +1 -0
- data/spec/ramaze/action/view/other_wrapper.xhtml +1 -0
- data/spec/ramaze/action/view/single_wrapper.xhtml +1 -0
- data/spec/ramaze/action/view/sub/sub_wrapper.erb +1 -0
- data/spec/ramaze/action/view/sub/sub_wrapper.xhtml +1 -0
- data/spec/ramaze/app.rb +47 -0
- data/spec/ramaze/bin/ramaze.rb +91 -0
- data/spec/ramaze/cache/localmemcache.rb +49 -0
- data/spec/ramaze/cache/memcache.rb +60 -0
- data/spec/ramaze/cache/sequel.rb +51 -0
- data/spec/ramaze/controller/actionless_templates.rb +36 -0
- data/spec/ramaze/controller/lonely_mapping.rb +16 -0
- data/spec/ramaze/controller/mapping.rb +43 -0
- data/spec/ramaze/controller/provide_inheritance.rb +47 -0
- data/spec/ramaze/controller/resolve.rb +30 -0
- data/spec/ramaze/controller/subclass.rb +36 -0
- data/spec/ramaze/controller/template_resolving.rb +77 -0
- data/spec/ramaze/controller/view/bar.xhtml +1 -0
- data/spec/ramaze/controller/view/base/another.xhtml +1 -0
- data/spec/ramaze/controller/view/greet.xhtml +1 -0
- data/spec/ramaze/controller/view/list.xhtml +1 -0
- data/spec/ramaze/controller/view/other/greet/other.xhtml +1 -0
- data/spec/ramaze/controller/view/other_wrapper.xhtml +1 -0
- data/spec/ramaze/dispatcher/directory.rb +69 -0
- data/spec/ramaze/dispatcher/file.rb +71 -0
- data/spec/ramaze/dispatcher/public/favicon.ico +0 -0
- data/spec/ramaze/dispatcher/public/file name.txt +1 -0
- data/spec/ramaze/dispatcher/public/test_download.css +141 -0
- data/spec/ramaze/error.rb +88 -0
- data/spec/ramaze/files.rb +29 -0
- data/spec/ramaze/files/public_1/plain.txt +1 -0
- data/spec/ramaze/files/public_2/rich.txt +1 -0
- data/spec/ramaze/gestalt.rb +135 -0
- data/spec/ramaze/helper/auth.rb +83 -0
- data/spec/ramaze/helper/bench.rb +18 -0
- data/spec/ramaze/helper/cache.rb +124 -0
- data/spec/ramaze/helper/flash.rb +41 -0
- data/spec/ramaze/helper/form.rb +356 -0
- data/spec/ramaze/helper/formatting.rb +111 -0
- data/spec/ramaze/helper/gestalt.rb +15 -0
- data/spec/ramaze/helper/gravatar.rb +40 -0
- data/spec/ramaze/helper/httpdigest.rb +144 -0
- data/spec/ramaze/helper/layout.rb +79 -0
- data/spec/ramaze/helper/layout/default.xhtml +5 -0
- data/spec/ramaze/helper/link.rb +70 -0
- data/spec/ramaze/helper/localize.rb +62 -0
- data/spec/ramaze/helper/maruku.rb +19 -0
- data/spec/ramaze/helper/pager.rb +96 -0
- data/spec/ramaze/helper/paginate.rb +68 -0
- data/spec/ramaze/helper/request_accessor.rb +19 -0
- data/spec/ramaze/helper/sequel_form.rb +91 -0
- data/spec/ramaze/helper/simple_captcha.rb +45 -0
- data/spec/ramaze/helper/stack.rb +86 -0
- data/spec/ramaze/helper/user.rb +72 -0
- data/spec/ramaze/helper/view/locals.xhtml +1 -0
- data/spec/ramaze/helper/view/loop.xhtml +4 -0
- data/spec/ramaze/helper/view/num.xhtml +1 -0
- data/spec/ramaze/helper/view/partial.xhtml +1 -0
- data/spec/ramaze/helper/view/recursive.xhtml +8 -0
- data/spec/ramaze/helper/view/recursive_local_ivars.xhtml +7 -0
- data/spec/ramaze/helper/view/recursive_locals.xhtml +7 -0
- data/spec/ramaze/helper/view/test_template.xhtml +1 -0
- data/spec/ramaze/helper/xhtml.rb +32 -0
- data/spec/ramaze/log/informer.rb +73 -0
- data/spec/ramaze/log/logging.rb +63 -0
- data/spec/ramaze/log/syslog.rb +73 -0
- data/spec/ramaze/params.rb +153 -0
- data/spec/ramaze/public/favicon.ico +0 -0
- data/spec/ramaze/public/ramaze.png +0 -0
- data/spec/ramaze/public/test_download.css +141 -0
- data/spec/ramaze/request.rb +61 -0
- data/spec/ramaze/rewrite/file.css +1 -0
- data/spec/ramaze/session/memcache.rb +66 -0
- data/spec/ramaze/struct.rb +47 -0
- data/spec/ramaze/template/ramaze/external.test +1 -0
- data/spec/ramaze/view.rb +36 -0
- data/spec/ramaze/view/erubis.rb +73 -0
- data/spec/ramaze/view/erubis/external.rhtml +8 -0
- data/spec/ramaze/view/erubis/sum.rhtml +1 -0
- data/spec/ramaze/view/ezamar.rb +73 -0
- data/spec/ramaze/view/ezamar/external.zmr +8 -0
- data/spec/ramaze/view/ezamar/sum.zmr +1 -0
- data/spec/ramaze/view/gestalt.rb +94 -0
- data/spec/ramaze/view/gestalt/external.ges +8 -0
- data/spec/ramaze/view/haml.rb +86 -0
- data/spec/ramaze/view/haml/external.haml +5 -0
- data/spec/ramaze/view/haml/sum.haml +2 -0
- data/spec/ramaze/view/liquid.rb +73 -0
- data/spec/ramaze/view/liquid/external.liquid +8 -0
- data/spec/ramaze/view/liquid/sum.liquid +1 -0
- data/spec/ramaze/view/nagoro.rb +73 -0
- data/spec/ramaze/view/nagoro/external.nag +8 -0
- data/spec/ramaze/view/nagoro/sum.nag +1 -0
- data/spec/ramaze/view/redcloth.rb +66 -0
- data/spec/ramaze/view/redcloth/external.redcloth +8 -0
- data/spec/ramaze/view/remarkably.rb +49 -0
- data/spec/ramaze/view/remarkably/external.rem +8 -0
- data/spec/ramaze/view/remarkably/sum.rem +1 -0
- data/spec/ramaze/view/sass.rb +73 -0
- data/spec/ramaze/view/sass/file.css.sass +5 -0
- data/spec/ramaze/view/tagz.rb +51 -0
- data/spec/ramaze/view/tagz/external.tagz +8 -0
- data/spec/ramaze/view/tagz/sum.tagz +1 -0
- data/spec/ramaze/view/tenjin.rb +57 -0
- data/spec/ramaze/view/tenjin/external.rbhtml +8 -0
- data/spec/ramaze/view/tenjin/sum.rbhtml +1 -0
- data/spec/snippets/array/put_within.rb +33 -0
- data/spec/snippets/binding/locals.rb +9 -0
- data/spec/snippets/numeric/filesize_format.rb +12 -0
- data/spec/snippets/numeric/time.rb +12 -0
- data/spec/snippets/object/__dir__.rb +14 -0
- data/spec/snippets/ordered_set.rb +63 -0
- data/spec/snippets/ramaze/acquire.rb +77 -0
- data/spec/snippets/ramaze/dictionary.rb +110 -0
- data/spec/snippets/ramaze/struct.rb +12 -0
- data/spec/snippets/string/camel_case.rb +25 -0
- data/spec/snippets/string/color.rb +11 -0
- data/spec/snippets/string/snake_case.rb +24 -0
- data/spec/snippets/string/unindent.rb +43 -0
- data/spec/snippets/thread/into.rb +9 -0
- data/tasks/authors.rake +30 -0
- data/tasks/bacon.rake +66 -0
- data/tasks/changelog.rake +20 -0
- data/tasks/copyright.rake +21 -0
- data/tasks/gem.rake +22 -0
- data/tasks/gem_setup.rake +99 -0
- data/tasks/git.rake +46 -0
- data/tasks/grancher.rake +12 -0
- data/tasks/jquery.rake +15 -0
- data/tasks/manifest.rake +4 -0
- data/tasks/metric_changes.rake +24 -0
- data/tasks/rcov.rake +23 -0
- data/tasks/release.rake +54 -0
- data/tasks/reversion.rake +8 -0
- data/tasks/setup.rake +6 -0
- data/tasks/todo.rake +27 -0
- data/tasks/traits.rake +21 -0
- data/tasks/yard.rake +4 -0
- metadata +720 -0
data/doc/INSTALL
ADDED
@@ -0,0 +1,92 @@
|
|
1
|
+
* via RubyGems
|
2
|
+
|
3
|
+
The simplest way of installing Ramaze is via the gem.
|
4
|
+
|
5
|
+
[Rubygems](http://rubygems.org) is the package manager for ruby apps and
|
6
|
+
libraries and provides you with the last tagged version of Ramaze.
|
7
|
+
|
8
|
+
$ gem install ramaze
|
9
|
+
|
10
|
+
Versions are made as we see fit and get an announcment out (usually that's
|
11
|
+
the major obstacle as there is a lot to announce).
|
12
|
+
|
13
|
+
If you want to install the nightly gem of Ramaze you can do this with:
|
14
|
+
|
15
|
+
$ gem install ramaze --source=http://gem.ramaze.net/
|
16
|
+
|
17
|
+
We also use the gem building process on github, which locates gems at
|
18
|
+
http://gems.github.com - so you can get a version from there as well:
|
19
|
+
|
20
|
+
$ gem install manveru-ramaze --source=http://gems.github.com/
|
21
|
+
|
22
|
+
* via git
|
23
|
+
|
24
|
+
To get the latest and sweetest, you can just pull from the repository and run
|
25
|
+
Ramaze that way.
|
26
|
+
|
27
|
+
$ git clone git://github.com/manveru/ramaze.git
|
28
|
+
|
29
|
+
Please read the `man git` or `git help` for more information about updating
|
30
|
+
and creating your own patches.
|
31
|
+
This is at the moment the premier way to use Ramaze, since it is the way I
|
32
|
+
use it.
|
33
|
+
|
34
|
+
Some hints for the usage of Git.
|
35
|
+
|
36
|
+
* use `require 'ramaze'` from everywhere
|
37
|
+
|
38
|
+
Simply add the path to your repository to the RUBYLIB environment variable.
|
39
|
+
If you are using bash you can simply put following line into your .bashrc:
|
40
|
+
|
41
|
+
$ export RUBYLIB="$HOME/path/to/repo/lib/"
|
42
|
+
|
43
|
+
Of course you should put the real path instead, you can also add multiple
|
44
|
+
paths, or create your personal `site_ruby`:
|
45
|
+
|
46
|
+
$ export RUBYLIB="$HOME/ruby/ramaze/lib:$HOME/.site_ruby:$HOME/ruby/bacon/lib"
|
47
|
+
|
48
|
+
* use `require 'ramaze'` systemwide from everywhere
|
49
|
+
|
50
|
+
add a file to your `site_ruby` directory named 'ramaze.rb'
|
51
|
+
the content should be: `require '/path/to/git/repo/ramaze/lib/ramaze'`
|
52
|
+
|
53
|
+
* Pull the latest version
|
54
|
+
|
55
|
+
$ git pull
|
56
|
+
|
57
|
+
* Reset the repo to original state (if you screw up something)
|
58
|
+
|
59
|
+
$ git reset --hard # resets the whole repo
|
60
|
+
|
61
|
+
* Revert changes to (for example) lib/ramaze.rb only
|
62
|
+
|
63
|
+
$ git checkout master lib/ramaze.rb
|
64
|
+
|
65
|
+
* Add and commit all changes.
|
66
|
+
|
67
|
+
$ git commit -a
|
68
|
+
|
69
|
+
* Adding only specific changes.
|
70
|
+
|
71
|
+
# Add hunks you want to commit to the staging area (index)
|
72
|
+
$ git add -p
|
73
|
+
|
74
|
+
* Commit the changes into the history of your repository
|
75
|
+
|
76
|
+
# Create a commit from the hunks added
|
77
|
+
$ git commit
|
78
|
+
|
79
|
+
* output your patches into a bundle ready to be mailed (compress it before
|
80
|
+
sending to make sure it arrives in the way you sent it)
|
81
|
+
|
82
|
+
At the end of this process you will have a tar.bz2 for all your changes
|
83
|
+
that you can mail to ramaze@googlegroups.com
|
84
|
+
|
85
|
+
# make sure you are on latest revision to avoid conflicts
|
86
|
+
$ git pull
|
87
|
+
|
88
|
+
# create 00xx-blah.patch files against the remote repo
|
89
|
+
$ git format-patch origin/HEAD
|
90
|
+
|
91
|
+
# From here on you can use either git-send-email or go the manual route
|
92
|
+
$ tar -cjf ramaze_bundle.tar.bz2 *.patch
|
data/doc/LEGAL
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
This is a list of files included into ramaze but under different licenses.
|
2
|
+
Also included are files that are not under the copyright from Michael Fellinger.
|
3
|
+
|
4
|
+
lib/ramaze/helper/pager.rb
|
5
|
+
License: BSD License
|
6
|
+
Author: George K. Moschovitis
|
7
|
+
|
8
|
+
lib/ramaze/snippets/dictionary.rb
|
9
|
+
License: Ruby License
|
10
|
+
Authors: Jan Molic and Thomas Sawyer
|
11
|
+
|
12
|
+
lib/proto/js/jquery.js
|
13
|
+
License: Dual licensed under MIT and GPL
|
14
|
+
Author: John Resig
|
15
|
+
|
16
|
+
lib/ramaze/spec/helper/simple_http.rb
|
17
|
+
License: Ruby
|
18
|
+
Author: Tim Becker
|
19
|
+
|
20
|
+
lib/ramaze/template/xslt.rb
|
21
|
+
License: Ruby
|
22
|
+
Author: Stephan Maka
|
23
|
+
|
24
|
+
lib/vendor/bacon.rb
|
25
|
+
License: MIT
|
26
|
+
Author: Christian Neukirchen
|
data/doc/TODO
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
This list is programmaticly generated by `rake todolist`
|
2
|
+
If you want to add/remove items from the list, change them at the
|
3
|
+
position specified in the list.
|
4
|
+
|
5
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/template/ezamar/morpher.rb
|
6
|
+
- Add pure Ruby implementation as a fall-back.
|
7
|
+
|
8
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/helper/pager.rb
|
9
|
+
++
|
10
|
+
|
11
|
+
/home/manveru/prog/projects/ramaze/spec/ramaze/action/basics.rb
|
12
|
+
|
13
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/template/ezamar/engine.rb
|
14
|
+
- provide C version or maybe use erbuis
|
15
|
+
|
16
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/template/xslt.rb
|
17
|
+
* Error handling
|
18
|
+
* Maybe prevent extFunction to be called by HTTP
|
19
|
+
|
20
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/helper/identity.rb
|
21
|
+
- maybe using StackHelper, but this is a really minimal overlap?
|
22
|
+
|
23
|
+
/home/manveru/prog/projects/ramaze/spec/snippets/ramaze/caller_info.rb
|
24
|
+
|
25
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/snippets/dictionary.rb
|
26
|
+
++
|
27
|
+
|
28
|
+
/home/manveru/prog/projects/ramaze/lib/ramaze/helper/redirect.rb
|
29
|
+
- maybe some more options, like a delay
|
@@ -0,0 +1,146 @@
|
|
1
|
+
The Ramaze development team is happy to announce version 2009.06 of Ramaze, the
|
2
|
+
light and modular open source web framework that tries to stay out of your way.
|
3
|
+
|
4
|
+
This release features a lot of work directly from our community and we are
|
5
|
+
really greatful for everybody who helped in testing, patching and contributing
|
6
|
+
exciting new features.
|
7
|
+
|
8
|
+
Our extensive set of specs and docs now covers almost every detail of
|
9
|
+
implementation and usage. Ramaze is under development by a growing community
|
10
|
+
and in production use at companies.
|
11
|
+
|
12
|
+
There have been too many changes since the last official announcement in
|
13
|
+
2008.07, so I will only list changes since the last release.
|
14
|
+
|
15
|
+
|
16
|
+
== Metadata
|
17
|
+
|
18
|
+
Home page: http://ramaze.net
|
19
|
+
Wiki: http://wiki.ramaze.net
|
20
|
+
|
21
|
+
Repository: http://github.com/manveru/ramaze
|
22
|
+
|
23
|
+
Git clone: git://github.com/manveru/ramaze
|
24
|
+
Current tarball: http://github.com/manveru/ramaze/tarball/master
|
25
|
+
|
26
|
+
IRC: #ramaze on irc.freenode.net
|
27
|
+
|
28
|
+
|
29
|
+
Simple example:
|
30
|
+
|
31
|
+
require 'ramaze'
|
32
|
+
|
33
|
+
class MainController
|
34
|
+
def index
|
35
|
+
'Hello, World!'
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
Ramaze.start
|
40
|
+
|
41
|
+
|
42
|
+
== Around 80 commits since 2009.05
|
43
|
+
|
44
|
+
- Improved bin/ramaze with lots of specs, should work now even on windows.
|
45
|
+
- Middleware order has been inverted.
|
46
|
+
- Support for Webrat out of the box.
|
47
|
+
- Fixed MemCache caching and sessions.
|
48
|
+
- Removed a whole lot of methods that were marked deprecated.
|
49
|
+
- New default Layout helper
|
50
|
+
|
51
|
+
|
52
|
+
== Summarized changes with their respective commits
|
53
|
+
|
54
|
+
- Antti Tuomi
|
55
|
+
- Link helper did not set the prefix, added spec and fixed the behaviour
|
56
|
+
[ af753a0 | bae2b53 | eba4734 ]
|
57
|
+
|
58
|
+
- Michael Fellinger (manveru)
|
59
|
+
- Fix bug that made default port/handler break in bin/ramaze [ e6715e1 ]
|
60
|
+
- Remove deprecated methods on Ramaze::Controller, Helper::Cache,
|
61
|
+
Helper::Link, and Helper::Auth. Also remove the deprecated methods
|
62
|
+
Object#acquire, String#/, and Symbol#/
|
63
|
+
[ 272fced | 1e4ac92 | a0a9329 | 68242b3 | 57e7a85 | 31b809a | 3fc4622 ]
|
64
|
+
- The bacon scope :mock was renamed to :rack_test, added shared :webrat, so
|
65
|
+
you can run your specs with that as well. Also move the bacon-specific code
|
66
|
+
to ramaze/spec/bacon, prepare for test-framework-agnostic behaviour.
|
67
|
+
[ f1a2669 | c12a0a4 | fdde916 ]
|
68
|
+
- Fix ordering of middleware [ 508bffc ]
|
69
|
+
- Warn and fix the ttl if someone exceeds the maximum ttl allowed by MemCache
|
70
|
+
[ 3124879 | bc08091 ]
|
71
|
+
- Comaptibility with localmemcache 0.4.0 [ 096f051 ]
|
72
|
+
- Fixed Cache::Sequel to work with 3.1.0 [ d2c2b85 ]
|
73
|
+
- Fix bug with memcache on 1.9, make sure the Etag middleware works on it
|
74
|
+
[ 21763df | 1d0dff5 ]
|
75
|
+
- A little bit of example-usage for Helper::Form#form_select, improve by
|
76
|
+
allowing :multiple => 10 [ a634582 | de73014 ]
|
77
|
+
- Avoid useless iteration and fix ambigous linking in helper/paginate
|
78
|
+
[ 6fb74df | 9b73450 ]
|
79
|
+
- Respect preset options for port/adapter on ramaze start [ 6efaaaa ]
|
80
|
+
- Preserve file permissions during `ramaze create` [ 3e3bc0a ]
|
81
|
+
- Implement and spec the lonely controller rule [ fdfe5b9 | 4dd866b ]
|
82
|
+
- Fix "bug" pointed out by druby [ 796627a ]
|
83
|
+
- Output to logger in ramaze/setup if Log is available, don't output the
|
84
|
+
require exception twice. Avoid infinite recursion when a
|
85
|
+
gem name does not match it's lib name [ b9fa0c4 | 7bc9d65 | e6b4996 ]
|
86
|
+
- Put a notice into config.ru making clear that the handler cannot be set
|
87
|
+
inside [ b4bad57 ]
|
88
|
+
- Some mods to contrib, fix facebook.rb syntax for ruby 1.9 and adding
|
89
|
+
Ramaze::AddressableRoute for great profit! [ c7fbf0c | cafe657 ]
|
90
|
+
- Don't write a file to /tmp during the bin/ramaze spec [ eb5e4ef ]
|
91
|
+
|
92
|
+
- Pistos
|
93
|
+
- Explicitly state top-level namespace for ::File in config.ru, since
|
94
|
+
otherwise it is confused for Rack::File.
|
95
|
+
[ 5509950 ]
|
96
|
+
- Added Layout helper with specs and documentation
|
97
|
+
[ a84f675 | 41ad023 | 4f23d16 ]
|
98
|
+
|
99
|
+
- TJ Vanderpoel (bougyman)
|
100
|
+
- Added some specs for ramaze/bin, correcting a require bug already in
|
101
|
+
bin/ramaze. [ 8bbb8e8 | 9a3edf3 | 33fa3aa ]
|
102
|
+
|
103
|
+
A complete Changelog is available at
|
104
|
+
http://github.com/manveru/ramaze/tree/master/doc/CHANGELOG?raw=true
|
105
|
+
|
106
|
+
|
107
|
+
== Known issues
|
108
|
+
|
109
|
+
- Some problems may show up when running the specs, these are mostly caused
|
110
|
+
by the gem-versions of Rack::Test and Rack, they only affect the specs and
|
111
|
+
should have no influence on the actual runtime.
|
112
|
+
|
113
|
+
|
114
|
+
== Ramaze Features
|
115
|
+
|
116
|
+
- Builds on top of the Rack library, which provides easy use of adapters like
|
117
|
+
Mongrel, WEBrick, LiteSpeed, Thin, CGI or FCGI.
|
118
|
+
|
119
|
+
- Supports a wide range of templating-engines like: ERB, Erubis, Haml, Liquid,
|
120
|
+
Maruku, Redcloth, Remarkably, Sass, Tagz, Tenjin. And its own engines called
|
121
|
+
Etanni, Ezamar, Gestalt, and Nagoro.
|
122
|
+
|
123
|
+
- Highly modular structure: you can just use the parts you like. This also
|
124
|
+
means that it's very simple to add your own customizations.
|
125
|
+
|
126
|
+
- A variety of helpers is already available, giving you things like advanced
|
127
|
+
caching, OpenID-authentication or aspect-oriented programming for your
|
128
|
+
controllers.
|
129
|
+
|
130
|
+
- It is possible to use the ORM you like, be it Sequel, DataMapper,
|
131
|
+
ActiveRecord, Og, Kansas or something more simplistic like DBI, or a wrapper
|
132
|
+
around YAML::Store.
|
133
|
+
|
134
|
+
- Good documentation: although we don't have 100% documentation right now (dcov
|
135
|
+
says around 75%), just about every part of Ramaze is covered with basic and
|
136
|
+
advanced docs. There are a variety of examples, screencasts and a tutorial
|
137
|
+
available.
|
138
|
+
|
139
|
+
- Friendly community: there are people from all over the world using Ramaze, so
|
140
|
+
you can get almost instant help and info.
|
141
|
+
|
142
|
+
|
143
|
+
For more information please come to http://ramaze.net or ask directly on IRC
|
144
|
+
irc://irc.freenode.net/#ramaze
|
145
|
+
|
146
|
+
Thank you, Michael 'manveru' Fellinger and the Ramaze community
|
@@ -0,0 +1,163 @@
|
|
1
|
+
This chapter covers how to do configuration in Ramaze for your application.
|
2
|
+
|
3
|
+
|
4
|
+
### Global
|
5
|
+
|
6
|
+
The object holding most configuration is called Global. It resides in the Ramaze
|
7
|
+
module/name space.
|
8
|
+
|
9
|
+
Global is an instance of GlobalStruct, which itself is an instance of Struct.
|
10
|
+
There have been some changes to it to suit its purpose.
|
11
|
+
|
12
|
+
Before covering some of the available options let us see how to actually use it.
|
13
|
+
|
14
|
+
For the examples shown here we will assume that you did include Ramaze
|
15
|
+
into your main into your main name space. If you don't do that, just prefix
|
16
|
+
Global with Ramaze so it is written Ramaze::Global.
|
17
|
+
|
18
|
+
|
19
|
+
#### Basic assignment:
|
20
|
+
|
21
|
+
Global.port = 10
|
22
|
+
|
23
|
+
if you do that before calling Ramaze::start Ramaze will choose the given number
|
24
|
+
as port.
|
25
|
+
|
26
|
+
|
27
|
+
#### Multiple assignment:
|
28
|
+
|
29
|
+
Global.setup :adapter => :mongrel,
|
30
|
+
:cache => :memcached
|
31
|
+
|
32
|
+
So you can pass a Hash of all the options you want to change.
|
33
|
+
In this case you would use Mongrel as the adapter and use memcached for your
|
34
|
+
sessions and general caching.
|
35
|
+
|
36
|
+
|
37
|
+
#### Block assignment:
|
38
|
+
|
39
|
+
Global.setup do |g|
|
40
|
+
g.error_page = false
|
41
|
+
g.host = '127.0.0.1'
|
42
|
+
g.port = 7070
|
43
|
+
end
|
44
|
+
|
45
|
+
This method is similar to the hash-assignment, but may be preferred for some
|
46
|
+
applications.
|
47
|
+
|
48
|
+
|
49
|
+
#### Pass on Ramaze.start
|
50
|
+
|
51
|
+
Ramaze.start :run_loose => true
|
52
|
+
|
53
|
+
This way you can save a line or two in a small script.
|
54
|
+
Please note that the values passed here have precedence over the ones directly
|
55
|
+
set on Global and will overwrite them if you set them before, that is mostly
|
56
|
+
useful to quickly test some configuration.
|
57
|
+
|
58
|
+
|
59
|
+
### Global options
|
60
|
+
|
61
|
+
This listing is here to provide you with descriptions of the most common
|
62
|
+
configurations in alphabetical order per section showing the default value next
|
63
|
+
to the key.
|
64
|
+
|
65
|
+
This chapter has been shrunk a lot to cover only essentials, please look at
|
66
|
+
lib/ramaze/global.rb to see all available options.
|
67
|
+
|
68
|
+
Date of last update: 2007-05-20
|
69
|
+
|
70
|
+
#### General Configuration:
|
71
|
+
|
72
|
+
:sourcereload => 3
|
73
|
+
|
74
|
+
SourceReload is a nifty mechanism that takes advantage of the dynamics of Ruby,
|
75
|
+
it's basically a Thread that runs in the background and polls for files in the
|
76
|
+
application and framework that have changed (using mtime). The value specifies
|
77
|
+
roughly how fast your changes are going to be loaded and should be a number.
|
78
|
+
If you set this to false, it will not start.
|
79
|
+
|
80
|
+
|
81
|
+
:adapter => :webrick
|
82
|
+
|
83
|
+
The adapter is the server Ramaze runs to serve your application. This can be any
|
84
|
+
of mongrel/webrick/fcgi/cgi, please note that so far neither fcgi nor cgi have
|
85
|
+
received the necessary testing, but, as they are only wrappers around the
|
86
|
+
underlying Rack library, should work fine. Both fcgi and mongrel require
|
87
|
+
additional libraries to be installed, webrick and cgi run out of the box.
|
88
|
+
Generally the most supported and recommended for deployment is Mongrel.
|
89
|
+
|
90
|
+
|
91
|
+
:cache => :memory
|
92
|
+
|
93
|
+
Possible: :memory, :memcached, :yaml
|
94
|
+
The cache is one of the more important things for deployment, the default for
|
95
|
+
this is MemoryCache, a simple Hash.
|
96
|
+
What you specify here will be used by Ramaze::Cache and is used throughout
|
97
|
+
Ramaze to cache various things, like sessions, page- and value-caching.
|
98
|
+
Included in Ramaze are the MemoryCache and YAMLStoreCache, after you install
|
99
|
+
'memcached' you can also use the much more performant MemcachedCache that also
|
100
|
+
makes it easy to use the same cache between different applications (sharing
|
101
|
+
sessions is one of the most obvious uses).
|
102
|
+
|
103
|
+
|
104
|
+
:cache_all => false
|
105
|
+
|
106
|
+
Setting this value to true would enable caching for all pages served from the
|
107
|
+
Controller (all actions).
|
108
|
+
This is a very powerful setting and you might want to enable it if all pages
|
109
|
+
you serve are only built once and have no further dynamics, the key for this
|
110
|
+
cache consists of the controller and parameters, when repeated requests are
|
111
|
+
made it will always serve the same (now static) page.
|
112
|
+
|
113
|
+
|
114
|
+
:sessions => true
|
115
|
+
|
116
|
+
Enables creation of sessions and automatic creation/setting of cookies.
|
117
|
+
Please note that many functionalities of Ramaze depend on an intact session and
|
118
|
+
you will have to be careful not to use these.
|
119
|
+
This is most likely useful in combination with `cache_all`
|
120
|
+
|
121
|
+
|
122
|
+
:error_page => true
|
123
|
+
|
124
|
+
Enables the default Error page of Ramaze which is mostly useful for manual
|
125
|
+
testing and faster debugging. In most deployment-scenarios you will however
|
126
|
+
want to use your own Error page and so you can safely disable this setting.
|
127
|
+
|
128
|
+
:host => '0.0.0.0'
|
129
|
+
|
130
|
+
Tell the adapter where it accepts requests from, 0.0.0.0 says that every
|
131
|
+
IP will be accepted, 127.0.0.1 would accept only requests from loopback.
|
132
|
+
|
133
|
+
|
134
|
+
:mapping => {}
|
135
|
+
|
136
|
+
This is a very central and special setting, it contains key/value pairs
|
137
|
+
that define routes to your controllers, the keys are simple strings and
|
138
|
+
start with '/', which means http://yourhost.com/ - '/foo/bar' would point
|
139
|
+
to http://yourhost.com/foo/bar.
|
140
|
+
The value is the class of your controller.
|
141
|
+
|
142
|
+
|
143
|
+
:port => 7000
|
144
|
+
|
145
|
+
The port Ramaze runs on, if you can think of more information about this feel
|
146
|
+
free to tell us.
|
147
|
+
|
148
|
+
|
149
|
+
:run_loose => false
|
150
|
+
|
151
|
+
This option is mostly used to run the specs, it means that Ramaze will not
|
152
|
+
join the adapter-threads and therefor you are free to run any code you want
|
153
|
+
afterwards. You won't have to use this in most cases, example usage is in
|
154
|
+
spec/spec_helper.
|
155
|
+
|
156
|
+
|
157
|
+
:template_root => 'template'
|
158
|
+
|
159
|
+
The template_root is the point your templates are located relative to the
|
160
|
+
location of the entry-file (usually start.rb)
|
161
|
+
It is also worth to mention that inside this directory the `mapping` is used
|
162
|
+
to locate templates for each controller, only the controller mapped to '/' uses
|
163
|
+
the templates directly from the `template_root`
|