refinerycms-core 2.1.5 → 3.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/images/refinery/add.png +0 -0
- data/app/assets/images/refinery/admin_bg.png +0 -0
- data/app/assets/images/refinery/ajax-loader.gif +0 -0
- data/app/assets/images/refinery/branch-end.gif +0 -0
- data/app/assets/images/refinery/branch.gif +0 -0
- data/app/assets/images/refinery/cross.png +0 -0
- data/app/assets/images/refinery/dialogLoadingAnimation.gif +0 -0
- data/app/assets/images/refinery/header_background.png +0 -0
- data/app/assets/images/refinery/hover-gradient.jpg +0 -0
- data/app/assets/images/refinery/icons/accept.png +0 -0
- data/app/assets/images/refinery/icons/add.png +0 -0
- data/app/assets/images/refinery/icons/ajax-loader.gif +0 -0
- data/app/assets/images/refinery/icons/application_edit.png +0 -0
- data/app/assets/images/refinery/icons/application_go.png +0 -0
- data/app/assets/images/refinery/icons/arrow_left.png +0 -0
- data/app/assets/images/refinery/icons/arrow_left_right.png +0 -0
- data/app/assets/images/refinery/icons/arrow_switch.png +0 -0
- data/app/assets/images/refinery/icons/arrow_up.png +0 -0
- data/app/assets/images/refinery/icons/arrow_up_down.png +0 -0
- data/app/assets/images/refinery/icons/bin.png +0 -0
- data/app/assets/images/refinery/icons/bin_closed.png +0 -0
- data/app/assets/images/refinery/icons/cancel.png +0 -0
- data/app/assets/images/refinery/icons/cog_add.png +0 -0
- data/app/assets/images/refinery/icons/cog_edit.png +0 -0
- data/app/assets/images/refinery/icons/cross.png +0 -0
- data/app/assets/images/refinery/icons/delete.png +0 -0
- data/app/assets/images/refinery/icons/doc.png +0 -0
- data/app/assets/images/refinery/icons/down.gif +0 -0
- data/app/assets/images/refinery/icons/edit.png +0 -0
- data/app/assets/images/refinery/icons/email.png +0 -0
- data/app/assets/images/refinery/icons/email_edit.png +0 -0
- data/app/assets/images/refinery/icons/email_go.png +0 -0
- data/app/assets/images/refinery/icons/email_open.png +0 -0
- data/app/assets/images/refinery/icons/eye.png +0 -0
- data/app/assets/images/refinery/icons/folder.png +0 -0
- data/app/assets/images/refinery/icons/folder_open.png +0 -0
- data/app/assets/images/refinery/icons/folder_page_white.png +0 -0
- data/app/assets/images/refinery/icons/image_add.png +0 -0
- data/app/assets/images/refinery/icons/image_edit.png +0 -0
- data/app/assets/images/refinery/icons/img.png +0 -0
- data/app/assets/images/refinery/icons/information.png +0 -0
- data/app/assets/images/refinery/icons/layout_add.png +0 -0
- data/app/assets/images/refinery/icons/layout_edit.png +0 -0
- data/app/assets/images/refinery/icons/locale-blue.svg +15 -0
- data/app/assets/images/refinery/icons/locale.svg +11 -0
- data/app/assets/images/refinery/icons/music.png +0 -0
- data/app/assets/images/refinery/icons/page.png +0 -0
- data/app/assets/images/refinery/icons/page_add.png +0 -0
- data/app/assets/images/refinery/icons/page_edit.png +0 -0
- data/app/assets/images/refinery/icons/page_white_edit.png +0 -0
- data/app/assets/images/refinery/icons/page_white_gear.png +0 -0
- data/app/assets/images/refinery/icons/page_white_put.png +0 -0
- data/app/assets/images/refinery/icons/pdf.png +0 -0
- data/app/assets/images/refinery/icons/ppt.png +0 -0
- data/app/assets/images/refinery/icons/star.png +0 -0
- data/app/assets/images/refinery/icons/tick.png +0 -0
- data/app/assets/images/refinery/icons/up.gif +0 -0
- data/app/assets/images/refinery/icons/user_add.png +0 -0
- data/app/assets/images/refinery/icons/user_comment.png +0 -0
- data/app/assets/images/refinery/icons/user_edit.png +0 -0
- data/app/assets/images/refinery/icons/xls.png +0 -0
- data/app/assets/images/refinery/icons/zip.png +0 -0
- data/app/assets/images/refinery/icons/zoom.png +0 -0
- data/app/assets/images/refinery/logo-large.png +0 -0
- data/app/assets/images/refinery/logo-medium.png +0 -0
- data/app/assets/images/refinery/logo-site-bar.png +0 -0
- data/app/assets/images/refinery/logo-small-medium.png +0 -0
- data/app/assets/images/refinery/logo-small.png +0 -0
- data/app/assets/images/refinery/logo-tiny.png +0 -0
- data/app/assets/images/refinery/logo.png +0 -0
- data/app/assets/images/refinery/nav-3-background.gif +0 -0
- data/app/assets/images/refinery/nav_inactive_background.png +0 -0
- data/app/assets/images/refinery/orange_button.png +0 -0
- data/app/assets/images/refinery/page_bg.png +0 -0
- data/app/assets/images/refinery/text_field_background.png +0 -0
- data/app/assets/images/refinery/tooltip-nib.gif +0 -0
- data/app/assets/images/refinery/tooltip-nib.png +0 -0
- data/app/assets/javascripts/admin.js +7 -6
- data/app/assets/javascripts/refinery/admin.js.erb +99 -60
- data/app/assets/javascripts/refinery/ajaxy_pagination.js.coffee +2 -5
- data/app/assets/javascripts/refinery/application.js +8 -0
- data/app/assets/javascripts/refinery/core.js +4 -18
- data/app/assets/javascripts/refinery/interface.js.coffee.erb +5 -29
- data/app/assets/javascripts/refinery/modal_dialogs.js.erb +0 -105
- data/app/assets/javascripts/refinery/nestedsortables.js +183 -110
- data/app/assets/javascripts/refinery/refinery.js.erb +3 -9
- data/app/assets/javascripts/refinery/serializelist.js +1 -1
- data/app/assets/javascripts/refinery/site_bar.js +0 -5
- data/app/assets/javascripts/refinery/sortable_list.js +10 -11
- data/app/assets/javascripts/refinery/submit_continue.js.coffee.erb +1 -1
- data/app/assets/stylesheets/application.scss +2 -0
- data/app/assets/stylesheets/refinery/_colours.scss +18 -0
- data/app/assets/stylesheets/refinery/_icons.scss +85 -0
- data/app/assets/stylesheets/refinery/{layout.css.scss → _layout.scss} +306 -338
- data/app/assets/stylesheets/refinery/_mixins.scss +84 -0
- data/app/assets/stylesheets/refinery/{submenu.css.scss → _submenu.scss} +2 -2
- data/app/assets/stylesheets/refinery/{tooltips.css.scss → _tooltips.scss} +0 -0
- data/app/assets/stylesheets/refinery/_ui.scss +252 -0
- data/app/assets/stylesheets/refinery/{formatting.css.scss → formatting.scss} +0 -0
- data/app/assets/stylesheets/refinery/refinery.scss +10 -0
- data/app/assets/stylesheets/refinery/site_bar.scss +126 -0
- data/app/assets/stylesheets/refinery/{theme.css.scss → theme.scss} +0 -0
- data/app/controllers/refinery/admin/core_controller.rb +2 -7
- data/app/controllers/refinery/admin/dialogs_controller.rb +4 -3
- data/app/controllers/refinery/admin_controller.rb +0 -1
- data/app/controllers/refinery/fast_controller.rb +0 -4
- data/app/helpers/refinery/admin/visual_editor_helper.rb +13 -0
- data/app/helpers/refinery/admin_helper.rb +4 -0
- data/app/helpers/refinery/custom_assets_helper.rb +2 -2
- data/app/helpers/refinery/image_helper.rb +9 -8
- data/app/helpers/refinery/meta_helper.rb +1 -1
- data/app/helpers/refinery/site_bar_helper.rb +16 -2
- data/app/helpers/refinery/tag_helper.rb +38 -5
- data/app/models/refinery/core/base_model.rb +3 -1
- data/app/views/layouts/refinery/admin.html.erb +12 -10
- data/app/views/layouts/refinery/admin_dialog.html.erb +1 -4
- data/app/views/refinery/_content_page.html.erb +1 -1
- data/app/views/refinery/_google_analytics.html.erb +8 -9
- data/app/views/refinery/_head.html.erb +1 -1
- data/app/views/refinery/_javascripts.html.erb +0 -15
- data/app/views/refinery/_message.html.erb +1 -1
- data/app/views/refinery/_site_bar.html.erb +9 -6
- data/app/views/refinery/admin/_error_messages.html.erb +4 -4
- data/app/views/refinery/admin/_form_actions.html.erb +1 -0
- data/app/views/refinery/admin/_form_advanced_options_menu.html.erb +3 -4
- data/app/views/refinery/admin/_head.html.erb +3 -0
- data/app/views/refinery/admin/_image_picker.html.erb +4 -5
- data/app/views/refinery/admin/_javascripts.html.erb +4 -9
- data/app/views/refinery/admin/_locale_picker.html.erb +9 -2
- data/app/views/refinery/admin/_make_sortable.html.erb +8 -6
- data/app/views/refinery/admin/_menu.html.erb +2 -15
- data/app/views/refinery/admin/_menu_item.html.erb +3 -0
- data/app/views/refinery/admin/_resource_picker.html.erb +12 -22
- data/app/views/refinery/admin/_search.html.erb +1 -1
- data/app/views/refinery/admin/_tabbed_fields.html.erb +2 -2
- data/app/views/refinery/admin/_wysiwyg.html.erb +1 -1
- data/{lib/generators/refinery/cms/templates/app/decorators/controllers/refinery/.gitkeep → app/views/refinery/admin/dialog_success.html.erb} +0 -0
- data/app/views/refinery/admin/dialogs/show.html.erb +1 -19
- data/config/initializers/assets.rb +6 -0
- data/config/locales/ca.yml +84 -0
- data/config/locales/cs.yml +12 -5
- data/config/locales/en.yml +6 -2
- data/config/locales/fr.yml +15 -11
- data/config/locales/hu.yml +3 -1
- data/config/locales/it.yml +5 -1
- data/config/locales/ja.yml +2 -2
- data/config/locales/pt.yml +5 -3
- data/config/locales/ru.yml +7 -0
- data/config/locales/sl.yml +0 -3
- data/config/locales/tr.yml +43 -41
- data/config/routes.rb +1 -4
- data/lib/generators/refinery/cms/cms_generator.rb +68 -26
- data/lib/generators/refinery/cms/templates/app/decorators/{models/refinery/.gitkeep → controllers/refinery/.keep} +0 -0
- data/lib/generators/refinery/{form/templates/.gitkeep → cms/templates/app/decorators/models/refinery/.keep} +0 -0
- data/lib/generators/refinery/cms/templates/config/database.yml.mysql +3 -3
- data/lib/generators/refinery/cms/templates/config/database.yml.postgresql +3 -3
- data/lib/generators/refinery/core/templates/config/initializers/refinery/core.rb.erb +18 -5
- data/lib/generators/refinery/dummy/dummy_generator.rb +3 -1
- data/lib/generators/refinery/dummy/templates/rails/application.js +3 -0
- data/lib/generators/refinery/dummy/templates/rails/application.rb.erb +0 -2
- data/lib/generators/refinery/dummy/templates/rails/blank.png +0 -0
- data/lib/generators/refinery/dummy/templates/rails/routes.rb +1 -1
- data/lib/generators/refinery/engine/engine_generator.rb +3 -2
- data/lib/generators/refinery/engine/templates/Gemfile +9 -4
- data/lib/generators/refinery/engine/templates/Rakefile +3 -4
- data/lib/generators/refinery/engine/templates/app/controllers/refinery/namespace/admin/plural_name_controller.rb.erb +11 -2
- data/lib/generators/refinery/engine/templates/app/controllers/refinery/namespace/plural_name_controller.rb.erb +2 -2
- data/lib/generators/refinery/engine/templates/app/models/refinery/namespace/singular_name.rb.erb +5 -5
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_actions.html.erb +7 -12
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_form.html.erb +8 -8
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_records.html.erb +3 -3
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/_singular_name.html.erb +6 -11
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/admin/plural_name/index.html.erb +1 -1
- data/lib/generators/refinery/engine/templates/app/views/refinery/namespace/plural_name/show.html.erb +4 -4
- data/lib/generators/refinery/engine/templates/db/migrate/1_create_namespace_plural_name.rb.erb +2 -9
- data/lib/generators/refinery/engine/templates/db/seeds.rb.erb +13 -19
- data/lib/generators/refinery/engine/templates/lib/refinery/plural_name/engine.rb.erb +0 -4
- data/lib/generators/refinery/engine/templates/readme.md +3 -3
- data/lib/generators/refinery/engine/templates/refinerycms-extension_plural_name.gemspec +1 -0
- data/lib/generators/refinery/engine/templates/spec/features/refinery/namespace/admin/plural_name_spec.rb.erb +25 -28
- data/lib/generators/refinery/engine/templates/spec/models/refinery/namespace/singular_name_spec.rb.erb +1 -1
- data/lib/generators/refinery/engine/templates/spec/spec_helper.rb +1 -1
- data/lib/refinery.rb +7 -9
- data/lib/refinery/admin/base_controller.rb +42 -32
- data/lib/refinery/application_controller.rb +25 -17
- data/lib/refinery/cli.rb +54 -19
- data/lib/refinery/core.rb +5 -0
- data/lib/refinery/core/authorisation_adapter.rb +11 -0
- data/lib/refinery/core/authorisation_manager.rb +14 -0
- data/lib/refinery/core/configuration.rb +25 -4
- data/lib/refinery/core/default_route.rb +16 -0
- data/lib/refinery/core/engine.rb +44 -25
- data/lib/refinery/core/nil_user.rb +42 -0
- data/lib/refinery/crud.rb +40 -29
- data/lib/refinery/extension_generation.rb +11 -22
- data/lib/refinery/generators/generated_attribute.rb +54 -0
- data/lib/refinery/generators/named_base.rb +16 -0
- data/lib/refinery/menu.rb +3 -2
- data/lib/refinery/menu_item.rb +1 -1
- data/lib/refinery/plugin.rb +27 -43
- data/lib/refinery/plugins.rb +22 -26
- data/lib/refinery/users_manager.rb +8 -0
- data/lib/refinery/version.rb +7 -3
- data/lib/tasks/refinery.rake +7 -0
- data/license.md +1 -1
- data/refinerycms-core.gemspec +11 -8
- data/spec/controllers/refinery/admin/dummy_controller_spec.rb +23 -11
- data/spec/controllers/refinery/sitemap_controller_spec.rb +2 -2
- data/spec/features/refinery/admin/custom_assets_spec.rb +12 -10
- data/spec/features/refinery/admin/dialogs_spec.rb +5 -5
- data/spec/features/refinery/admin/xhr_paging_spec.rb +24 -38
- data/spec/features/refinery/application_layout_spec.rb +3 -3
- data/spec/features/refinery/core_spec.rb +1 -1
- data/spec/features/refinery/site_bar_spec.rb +44 -23
- data/spec/helpers/refinery/admin_helper_spec.rb +15 -0
- data/spec/helpers/refinery/custom_assets_helper_spec.rb +15 -23
- data/spec/helpers/refinery/html_truncation_helper_spec.rb +10 -5
- data/spec/helpers/refinery/meta_helper_spec.rb +3 -3
- data/spec/helpers/refinery/pagination_helper_spec.rb +7 -7
- data/spec/helpers/refinery/tag_helper_spec.rb +4 -4
- data/spec/helpers/refinery/translation_helper_spec.rb +3 -3
- data/spec/lib/generators/refinery/cms/cms_generator_spec.rb +30 -25
- data/spec/lib/generators/refinery/core/core_generator_spec.rb +1 -1
- data/spec/lib/generators/refinery/engine/engine_generator_multiple_resources_spec.rb +7 -8
- data/spec/lib/generators/refinery/engine/engine_generator_sanity_check_spec.rb +15 -15
- data/spec/lib/generators/refinery/engine/engine_generator_spec.rb +9 -9
- data/spec/lib/generators/refinery/engine/engine_generator_with_i18n_spec.rb +1 -1
- data/spec/lib/generators/refinery/engine/engine_generator_without_frontend_spec.rb +1 -1
- data/spec/lib/refinery/application_controller_spec.rb +16 -16
- data/spec/lib/refinery/authorisation_manager_spec.rb +10 -0
- data/spec/lib/refinery/cli_spec.rb +83 -21
- data/spec/lib/refinery/core/configuration_spec.rb +5 -5
- data/spec/lib/refinery/core/nil_user_spec.rb +39 -0
- data/spec/lib/refinery/core_spec.rb +39 -30
- data/spec/lib/refinery/crud_spec.rb +70 -59
- data/spec/lib/refinery/menu_spec.rb +4 -4
- data/spec/lib/refinery/plugin_spec.rb +56 -45
- data/spec/lib/refinery/plugins_spec.rb +39 -87
- data/spec/lib/refinery/users_manager_spec.rb +9 -0
- data/spec/support/refinery.rb +3 -8
- data/vendor/assets/fonts/font-awesome/FontAwesome.otf +0 -0
- data/vendor/assets/fonts/font-awesome/fontawesome-webfont.eot +0 -0
- data/vendor/assets/fonts/font-awesome/fontawesome-webfont.svg +565 -0
- data/vendor/assets/fonts/font-awesome/fontawesome-webfont.ttf +0 -0
- data/vendor/assets/fonts/font-awesome/fontawesome-webfont.woff +0 -0
- data/vendor/assets/fonts/font-awesome/fontawesome-webfont.woff2 +0 -0
- data/vendor/assets/stylesheets/_font-awesome-compass.scss +5 -0
- data/vendor/assets/stylesheets/_font-awesome-sprockets.scss +5 -0
- data/vendor/assets/stylesheets/_font-awesome.scss +17 -0
- data/vendor/assets/stylesheets/font-awesome/_animated.scss +34 -0
- data/vendor/assets/stylesheets/font-awesome/_bordered-pulled.scss +16 -0
- data/vendor/assets/stylesheets/font-awesome/_core.scss +12 -0
- data/vendor/assets/stylesheets/font-awesome/_extras.scss +44 -0
- data/vendor/assets/stylesheets/font-awesome/_fixed-width.scss +6 -0
- data/vendor/assets/stylesheets/font-awesome/_icons.scss +596 -0
- data/vendor/assets/stylesheets/font-awesome/_larger.scss +13 -0
- data/vendor/assets/stylesheets/font-awesome/_list.scss +19 -0
- data/vendor/assets/stylesheets/font-awesome/_mixins.scss +26 -0
- data/vendor/assets/stylesheets/font-awesome/_path.scss +14 -0
- data/vendor/assets/stylesheets/font-awesome/_rotated-flipped.scss +20 -0
- data/vendor/assets/stylesheets/font-awesome/_stacked.scss +20 -0
- data/vendor/assets/stylesheets/font-awesome/_variables.scss +606 -0
- metadata +144 -441
- data/app/assets/images/refinery/carousel-left.png +0 -0
- data/app/assets/images/refinery/carousel-right.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/arrow_redo.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/arrow_undo.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/eye.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/article.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/aside.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/blockquote.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/command.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/details.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/figcaption.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/figure.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/footer.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/h1.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/h2.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/h3.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/h4.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/h5.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/h6.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/header.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/hgroup.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/mark.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/meter.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/nav.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/p.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/pre.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/progress.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/readme.md +0 -1
- data/app/assets/images/wymeditor/skins/refinery/html5/rp.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/rt.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/ruby.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/section.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/summary.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/html5/time.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-blockquote.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-h1.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-h2.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-h3.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-h4.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-h5.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-h6.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-p.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/iframe/lbl-pre.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/link_add.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/link_break.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/page_code.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/page_paste.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/photo_add.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/right.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/style.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/table_add.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_align_center.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_align_justify.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_align_left.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_align_right.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_bold.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_heading_1.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_heading_2.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_heading_3.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_heading_4.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_heading_5.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_heading_6.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_indent.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_indent_remove.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_italic.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_list_bullets.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_list_numbers.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_paragraph.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_strikethrough.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_subscript.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_superscript.png +0 -0
- data/app/assets/images/wymeditor/skins/refinery/text_underline.png +0 -0
- data/app/assets/images/wymeditor/skins/wymeditor_icon.png +0 -0
- data/app/assets/javascripts/refinery/boot_wym.js.erb +0 -285
- data/app/assets/javascripts/refinery/sortable_menu.js.coffee.erb +0 -20
- data/app/assets/javascripts/refinery/wymeditor.js +0 -37
- data/app/assets/javascripts/wymeditor/GPL-license.txt +0 -278
- data/app/assets/javascripts/wymeditor/MIT-license.txt +0 -20
- data/app/assets/javascripts/wymeditor/README +0 -35
- data/app/assets/javascripts/wymeditor/browsers/ie.js.erb +0 -224
- data/app/assets/javascripts/wymeditor/browsers/mozilla.js.erb +0 -292
- data/app/assets/javascripts/wymeditor/browsers/opera.js.erb +0 -123
- data/app/assets/javascripts/wymeditor/browsers/webkit.js.erb +0 -283
- data/app/assets/javascripts/wymeditor/classes.js.erb +0 -1575
- data/app/assets/javascripts/wymeditor/functions.js.erb +0 -222
- data/app/assets/javascripts/wymeditor/lang/bg.js +0 -57
- data/app/assets/javascripts/wymeditor/lang/ca.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/cs.js +0 -58
- data/app/assets/javascripts/wymeditor/lang/da.js +0 -48
- data/app/assets/javascripts/wymeditor/lang/de.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/en.js +0 -57
- data/app/assets/javascripts/wymeditor/lang/es.js +0 -58
- data/app/assets/javascripts/wymeditor/lang/fa.js +0 -46
- data/app/assets/javascripts/wymeditor/lang/fi.js +0 -57
- data/app/assets/javascripts/wymeditor/lang/fr.js +0 -58
- data/app/assets/javascripts/wymeditor/lang/he.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/hu.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/it.js +0 -48
- data/app/assets/javascripts/wymeditor/lang/ja.js +0 -47
- data/app/assets/javascripts/wymeditor/lang/lv.js +0 -47
- data/app/assets/javascripts/wymeditor/lang/nb.js +0 -48
- data/app/assets/javascripts/wymeditor/lang/nl.js +0 -57
- data/app/assets/javascripts/wymeditor/lang/nn.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/pl.js +0 -56
- data/app/assets/javascripts/wymeditor/lang/pt-BR.js +0 -58
- data/app/assets/javascripts/wymeditor/lang/pt.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/rs.js +0 -47
- data/app/assets/javascripts/wymeditor/lang/ru.js +0 -57
- data/app/assets/javascripts/wymeditor/lang/sk.js +0 -56
- data/app/assets/javascripts/wymeditor/lang/sl.js +0 -47
- data/app/assets/javascripts/wymeditor/lang/sv.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/tr.js +0 -45
- data/app/assets/javascripts/wymeditor/lang/vi.js +0 -47
- data/app/assets/javascripts/wymeditor/lang/zh-CN.js +0 -47
- data/app/assets/javascripts/wymeditor/prototypes.js.erb +0 -1103
- data/app/assets/javascripts/wymeditor/setup.js.erb +0 -622
- data/app/assets/javascripts/wymeditor/skins/refinery/skin.js +0 -45
- data/app/assets/javascripts/wymeditor/validators.js.erb +0 -777
- data/app/assets/stylesheets/refinery/refinery.css +0 -15
- data/app/assets/stylesheets/refinery/site_bar.css.scss +0 -92
- data/app/assets/stylesheets/refinery/ui.css.scss +0 -103
- data/app/assets/stylesheets/wymeditor/skins/refinery/skin.css.scss +0 -530
- data/app/assets/stylesheets/wymeditor/skins/refinery/wymiframe.css.scss +0 -156
- data/app/helpers/refinery/admin/core_helper.rb +0 -6
- data/app/helpers/refinery/admin/dialogs_helper.rb +0 -6
- data/app/helpers/refinery/fast_helper.rb +0 -4
- data/app/helpers/refinery/sitemap_helper.rb +0 -4
- data/app/views/refinery/wymiframe.html.erb +0 -14
- data/lib/generators/refinery/form/USAGE +0 -20
- data/lib/generators/refinery/form/form_generator.rb +0 -25
- data/lib/generators/refinery/form/templates/.gitignore +0 -2
- data/lib/generators/refinery/form/templates/app/controllers/refinery/namespace/admin/plural_name_controller.rb.erb +0 -54
- data/lib/generators/refinery/form/templates/app/controllers/refinery/namespace/admin/settings_controller.rb.erb +0 -45
- data/lib/generators/refinery/form/templates/app/controllers/refinery/namespace/plural_name_controller.rb.erb +0 -53
- data/lib/generators/refinery/form/templates/app/mailers/refinery/namespace/mailer.rb.erb +0 -22
- data/lib/generators/refinery/form/templates/app/models/refinery/namespace/setting.rb.erb +0 -34
- data/lib/generators/refinery/form/templates/app/models/refinery/namespace/singular_name.rb.erb +0 -49
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/_records.html.erb +0 -23
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/_singular_name.html.erb +0 -25
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/_submenu.html.erb +0 -29
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/index.html.erb +0 -4
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/show.html.erb +0 -52
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/plural_name/spam.html.erb +0 -27
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/settings/_confirmation_email_form.html.erb +0 -51
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/settings/_notification_recipients_form.html.erb +0 -21
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/admin/settings/edit.html.erb +0 -5
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/mailer/confirmation.html.erb +0 -1
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/mailer/notification.html.erb +0 -17
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/plural_name/new.html.erb +0 -43
- data/lib/generators/refinery/form/templates/app/views/refinery/namespace/plural_name/thank_you.html.erb +0 -1
- data/lib/generators/refinery/form/templates/config/locales/cs.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/da.yml +0 -66
- data/lib/generators/refinery/form/templates/config/locales/de.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/en.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/es.yml +0 -66
- data/lib/generators/refinery/form/templates/config/locales/fr.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/it.yml +0 -66
- data/lib/generators/refinery/form/templates/config/locales/lv.yml +0 -77
- data/lib/generators/refinery/form/templates/config/locales/nb.yml +0 -75
- data/lib/generators/refinery/form/templates/config/locales/nl.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/pt-BR.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/ru.yml +0 -77
- data/lib/generators/refinery/form/templates/config/locales/sk.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/sl.yml +0 -67
- data/lib/generators/refinery/form/templates/config/locales/tr.yml +0 -78
- data/lib/generators/refinery/form/templates/config/locales/zh-CN.yml +0 -78
- data/lib/generators/refinery/form/templates/config/routes.rb.erb +0 -26
- data/lib/generators/refinery/form/templates/db/migrate/1_create_plural_name.rb.erb +0 -39
- data/lib/generators/refinery/form/templates/db/seeds.rb.erb +0 -31
- data/lib/generators/refinery/form/templates/lib/generators/refinery/plural_name_generator.rb.erb +0 -20
- data/lib/generators/refinery/form/templates/lib/refinery/plural_name.rb.erb +0 -18
- data/lib/generators/refinery/form/templates/lib/refinery/plural_name/engine.rb.erb +0 -27
- data/lib/generators/refinery/form/templates/lib/refinerycms-plural_name.rb.erb +0 -1
- data/lib/generators/refinery/form/templates/refinerycms-plural_name.gemspec +0 -16
- data/lib/generators/refinery/form/templates/script/rails +0 -10
- data/lib/refinery/activity.rb +0 -113
- data/lib/refinery/ext/action_view/helpers/form_builder.rb +0 -9
- data/lib/refinery/ext/action_view/helpers/form_helper.rb +0 -20
- data/lib/refinery/ext/action_view/helpers/form_tag_helper.rb +0 -10
- data/spec/controllers/refinery/admin/refinery_core_controller_spec.rb +0 -19
- data/spec/controllers/refinery/fast_controller_spec.rb +0 -12
- data/spec/lib/generators/refinery/form/form_generator_spec.rb +0 -99
- data/spec/lib/refinery/activity_spec.rb +0 -46
- data/spec/support/background_selenium_firefox_driver.rb +0 -14
- data/vendor/assets/javascripts/jquery/jquery.jcarousel.js +0 -900
data/config/locales/hu.yml
CHANGED
@@ -53,7 +53,9 @@ hu:
|
|
53
53
|
results_for_html: "Keresési eredmények a következőhöz: ‘<em>%{query}</em>’"
|
54
54
|
no_results: 'Sajnáljuk, nincs találat'
|
55
55
|
cancel_search: 'Keresés megszakítása'
|
56
|
-
|
56
|
+
input:
|
57
|
+
placeholder: "Keres&8230;"
|
58
|
+
help: "Írd ide amit keresel. Minimális hossz 3 karakter."
|
57
59
|
delete:
|
58
60
|
message: "Biztosan ez akarod távolítani ezt: '%{title}'?"
|
59
61
|
error_messages:
|
data/config/locales/it.yml
CHANGED
@@ -41,6 +41,8 @@ it:
|
|
41
41
|
remove_current: "Rimuovi immagine corrente"
|
42
42
|
change: "Clicca qui per scegliere un'immagine"
|
43
43
|
show: Visualizza
|
44
|
+
locale_picker:
|
45
|
+
language: Lingua
|
44
46
|
resource_picker:
|
45
47
|
download_current: "Scarica il file corrente"
|
46
48
|
opens_in_new_window: Apri in una nuova finestra
|
@@ -53,7 +55,9 @@ it:
|
|
53
55
|
results_for_html: "Risultati della ricerca per ‘<em>%{query}</em>’"
|
54
56
|
no_results: "Spiacenti, nessun risultato trovato"
|
55
57
|
cancel_search: 'Annulla ricerca'
|
56
|
-
|
58
|
+
input:
|
59
|
+
placeholder: "Cerca&8230;"
|
60
|
+
help: "Scrivi qui una stringa di almeno 3 caratteri contenente quello che stai cercando."
|
57
61
|
delete:
|
58
62
|
message: "Sei sicuro di voler rimuovere '%{title}'?"
|
59
63
|
error_messages:
|
data/config/locales/ja.yml
CHANGED
@@ -59,14 +59,14 @@ ja:
|
|
59
59
|
form_advanced_options_menu:
|
60
60
|
advanced_options: その他の設定
|
61
61
|
toggle_advanced_options: メタタグの設定とメニューオプションの設定
|
62
|
-
save_as_draft:
|
62
|
+
save_as_draft: 下書きとして保存する
|
63
63
|
message:
|
64
64
|
close: 閉じる
|
65
65
|
close_this_message: このメッセージを閉じる
|
66
66
|
draft_page_message:
|
67
67
|
not_live: このページはまだ公開されていません。
|
68
68
|
footer:
|
69
|
-
copyright: '
|
69
|
+
copyright: 'Copyright © %{year} %{site_name}'
|
70
70
|
no_script:
|
71
71
|
enable_javascript_html: このページを快適にお使いになるにはJavaScriptを有効にする必要があります。
|
72
72
|
here_are:
|
data/config/locales/pt.yml
CHANGED
@@ -53,7 +53,9 @@ pt:
|
|
53
53
|
results_for_html: "Resultados para ‘<em>%{query}</em>’"
|
54
54
|
no_results: 'Não existem resultados para a sua procura'
|
55
55
|
cancel_search: 'Cancelar procura'
|
56
|
-
|
56
|
+
input:
|
57
|
+
placeholder: "Procurar&8230;"
|
58
|
+
help: "Escreva aqui o que está à procura, o mínimo são 3 caractéres."
|
57
59
|
delete:
|
58
60
|
message: "Tem a certeza que quer remover '%{title}'?"
|
59
61
|
error_messages:
|
@@ -72,11 +74,11 @@ pt:
|
|
72
74
|
copyright: "Copyright © %{year} %{site_name}"
|
73
75
|
no_script:
|
74
76
|
enable_javascript_html: É necessário que tenha o JavaScript ligado.
|
75
|
-
here_are: Aqui estão as
|
77
|
+
here_are: Aqui estão as
|
76
78
|
instructions_enable_javascript_html: instruções para ligar o JavaScript no seu browser.
|
77
79
|
time:
|
78
80
|
formats:
|
79
81
|
short: "%A, %d %B %Y"
|
80
82
|
will_paginate:
|
81
83
|
previous_label: "«"
|
82
|
-
next_label: "»"
|
84
|
+
next_label: "»"
|
data/config/locales/ru.yml
CHANGED
@@ -1,5 +1,8 @@
|
|
1
1
|
ru:
|
2
2
|
refinery:
|
3
|
+
js:
|
4
|
+
admin:
|
5
|
+
confirm_changes: Любые сделанные изменения будут потеряны. Вы уверены, что хотите продолжить без сохранения?
|
3
6
|
plugins:
|
4
7
|
refinery_core:
|
5
8
|
title: Refinery
|
@@ -49,6 +52,10 @@ ru:
|
|
49
52
|
button_text: Поиск
|
50
53
|
results_for_html: "Результаты поиска для ‘<em>%{query}</em>’"
|
51
54
|
no_results: Ничего не найдено
|
55
|
+
cancel_search: Отмена поиска
|
56
|
+
input:
|
57
|
+
placeholder: "Поиск&8230;"
|
58
|
+
help: Введите строку содержащую то, что вы ищете, минимум 3 символа.
|
52
59
|
delete:
|
53
60
|
message: Вы уверены, что хотите удалить '%{title}'?
|
54
61
|
error_messages:
|
data/config/locales/sl.yml
CHANGED
@@ -18,8 +18,6 @@ sl:
|
|
18
18
|
show:
|
19
19
|
save: Shrani
|
20
20
|
cancel: Prekliči
|
21
|
-
message:
|
22
|
-
close: Zapri
|
23
21
|
continue_editing:
|
24
22
|
save_and_continue_editing: "Shrani & nadaljuj z urejanjem"
|
25
23
|
form_actions:
|
@@ -40,7 +38,6 @@ sl:
|
|
40
38
|
download_current: "Prenesi trenutno %{what}"
|
41
39
|
opens_in_new_window: Odpri v novem oknu
|
42
40
|
remove_current: "Odstrani trenutno %{what}"
|
43
|
-
resource: vir
|
44
41
|
search:
|
45
42
|
button_text: Išči
|
46
43
|
results_for_html: "Iskalni rezultati za ‘<em>%{query}</em>’"
|
data/config/locales/tr.yml
CHANGED
@@ -2,78 +2,80 @@ tr:
|
|
2
2
|
refinery:
|
3
3
|
js:
|
4
4
|
admin:
|
5
|
-
confirm_changes:
|
5
|
+
confirm_changes: Yaptığınız değişiklikler kaybolacaktır. Kayıt etmeden devam etmek istediğinize emin misiniz ?
|
6
6
|
plugins:
|
7
7
|
refinery_core:
|
8
8
|
title: Refinery
|
9
|
-
description:
|
9
|
+
description: Çekirdek refinery eklentisi
|
10
10
|
refinery_dialogs:
|
11
|
-
title:
|
11
|
+
title: İletişim
|
12
12
|
description: Refinery diyalog eklentisi
|
13
13
|
welcome:
|
14
|
-
there_are_no_users: "
|
14
|
+
there_are_no_users: "Henüz kayıtlı bir kullanıcı yok. İlk önce sizi kayıt edelim."
|
15
15
|
crudify:
|
16
|
-
created: '%{what}
|
17
|
-
updated: '%{what}
|
18
|
-
destroyed: '%{what}
|
16
|
+
created: '%{what} başarı ile eklendi'
|
17
|
+
updated: '%{what} başarı ile güncellendi'
|
18
|
+
destroyed: '%{what} başarı ile silindi.'
|
19
19
|
site_bar:
|
20
|
-
log_out:
|
21
|
-
switch_to_your_website: Web Siteni
|
22
|
-
switch_to_your_website_editor: Web Site
|
20
|
+
log_out: Çıkış Yap
|
21
|
+
switch_to_your_website: Web Siteni Aç
|
22
|
+
switch_to_your_website_editor: Web Site Düzenleyicisini Aç
|
23
23
|
admin:
|
24
24
|
menu:
|
25
|
-
reorder_menu: Yeniden
|
26
|
-
reorder_menu_done: Yeniden
|
25
|
+
reorder_menu: Yeniden düzenleme menüsü
|
26
|
+
reorder_menu_done: Yeniden düzenleme tamamlandı
|
27
27
|
dialogs:
|
28
28
|
show:
|
29
|
-
save:
|
30
|
-
cancel:
|
29
|
+
save: Kayıt Et
|
30
|
+
cancel: Vazgeç
|
31
31
|
continue_editing:
|
32
|
-
save_and_continue_editing: 'Kaydet &
|
32
|
+
save_and_continue_editing: 'Kaydet & Düzenlemeye Devam Et'
|
33
33
|
form_actions:
|
34
|
-
save:
|
35
|
-
cancel:
|
36
|
-
cancel_lose_changes:
|
34
|
+
save: Kayıt Et
|
35
|
+
cancel: Vazgeç
|
36
|
+
cancel_lose_changes: Eğer vazgeç'e tıklarsanız burada yaptığınız değişiklikler kaybolacaktır.
|
37
37
|
delete: Sil
|
38
38
|
close: Kapat
|
39
39
|
image_picker:
|
40
|
-
none_selected:
|
41
|
-
remove_current: Mevcut
|
42
|
-
change:
|
43
|
-
show:
|
40
|
+
none_selected: Seçilmiş bir fotoğraf bulunmamaktadir. Eklemek için buraya tıklayın
|
41
|
+
remove_current: Mevcut fotoğrafı sil
|
42
|
+
change: Fotoğraf seçmek için tıklayın
|
43
|
+
show: Göster
|
44
44
|
resource_picker:
|
45
|
-
download_current: Mevcut
|
46
|
-
opens_in_new_window: Yeni bir pencerede
|
47
|
-
remove_current: "Mevcut
|
48
|
-
no_resource_selected: 'Herhangi bir dosya
|
45
|
+
download_current: Mevcut dosyayı indir
|
46
|
+
opens_in_new_window: Yeni bir pencerede aç
|
47
|
+
remove_current: "Mevcut dosyayı sil"
|
48
|
+
no_resource_selected: 'Herhangi bir dosya seçilmemiş. Eklemek icin tıklayın'
|
49
49
|
name: Dosya Ekle
|
50
50
|
current: Mevcut Dosya
|
51
51
|
search:
|
52
52
|
button_text: Arama
|
53
|
-
results_for_html: " ‘<em>%{query}</em>’
|
54
|
-
no_results: '
|
55
|
-
cancel_search: '
|
56
|
-
|
53
|
+
results_for_html: " ‘<em>%{query}</em>’ için arama sonucu"
|
54
|
+
no_results: 'Üzgünüm, herhangi bir sonuç bulunamadı'
|
55
|
+
cancel_search: 'Aramayı iptal et'
|
56
|
+
input:
|
57
|
+
placeholder: "Arama&8230;"
|
58
|
+
help: "Buraya aradığınız karakterleri içeren en az 3 tane harf girin."
|
57
59
|
delete:
|
58
|
-
message: " '%{title}' Silmek
|
60
|
+
message: " '%{title}' Silmek istediğinize emin misiniz?"
|
59
61
|
error_messages:
|
60
|
-
problems_in_following_fields:
|
61
|
-
help:
|
62
|
+
problems_in_following_fields: Aşağıdaki alanlarda problem vardır.
|
63
|
+
help: yardım
|
62
64
|
form_advanced_options_menu:
|
63
|
-
advanced_options:
|
64
|
-
toggle_advanced_options:
|
65
|
+
advanced_options: Gelişmiş Seçenekler
|
66
|
+
toggle_advanced_options: Gelişmiş Seçenekleri Aç
|
65
67
|
save_as_draft: Taslak Olarak Kaydet
|
66
68
|
message:
|
67
69
|
close: Kapat
|
68
|
-
close_this_message: Bu
|
70
|
+
close_this_message: Bu Mesajı Kapat
|
69
71
|
draft_page_message:
|
70
|
-
not_live: Bu sayfa halka
|
72
|
+
not_live: Bu sayfa halka açık canlı görüntülemede değildir.
|
71
73
|
footer:
|
72
|
-
copyright: "Telif
|
74
|
+
copyright: "Telif Hakkı © %{year} %{site_name}"
|
73
75
|
no_script:
|
74
|
-
enable_javascript_html: Bu
|
75
|
-
here_are:
|
76
|
-
instructions_enable_javascript_html:
|
76
|
+
enable_javascript_html: Bu sayfanın tüm fonksyonları için JavaScript'in aktif olması gerekmekte
|
77
|
+
here_are: İşte burada
|
78
|
+
instructions_enable_javascript_html: Tarayıcınızın JavaScript'inin nasıl aktif edileceğine dair talimatlar
|
77
79
|
time:
|
78
80
|
formats:
|
79
81
|
short: "%A, %d %B %Y"
|
data/config/routes.rb
CHANGED
@@ -1,14 +1,11 @@
|
|
1
1
|
Refinery::Core::Engine.routes.draw do
|
2
2
|
filter(:refinery_locales) if defined?(RoutingFilter::RefineryLocales) # optionally use i18n.
|
3
|
-
get 'wymiframe(/:id)', :to => 'fast#wymiframe', :as => :wymiframe
|
4
3
|
get "#{Refinery::Core.backend_route}/message", :to => 'fast#message', :as => :message
|
5
4
|
|
6
5
|
namespace :admin, :path => Refinery::Core.backend_route do
|
7
|
-
root :
|
6
|
+
root to: 'core#index'
|
8
7
|
resources :dialogs, :only => [:index, :show]
|
9
8
|
end
|
10
9
|
|
11
|
-
post "/#{Refinery::Core.backend_route}/update_menu_positions", :to => 'admin/core#update_plugin_positions'
|
12
|
-
|
13
10
|
get '/sitemap.xml' => 'sitemap#index', :defaults => { :format => 'xml' }
|
14
11
|
end
|
@@ -10,7 +10,7 @@ module Refinery
|
|
10
10
|
:desc => "Allow Refinery to remove default Rails files in a fresh installation"
|
11
11
|
class_option :heroku, :type => :string, :default => nil, :group => :runtime, :banner => 'APP_NAME',
|
12
12
|
:desc => "Deploy to Heroku after the generator has run."
|
13
|
-
class_option :stack, :type => :string, :default => 'cedar', :group => :runtime,
|
13
|
+
class_option :stack, :type => :string, :default => 'cedar-14', :group => :runtime,
|
14
14
|
:desc => "Specify which Heroku stack you want to use. Requires --heroku option to function."
|
15
15
|
class_option :skip_db, :type => :boolean, :default => false, :aliases => nil, :group => :runtime,
|
16
16
|
:desc => "Skip over any database creation, migration or seeding."
|
@@ -42,14 +42,12 @@ module Refinery
|
|
42
42
|
|
43
43
|
run_additional_generators! if self.options[:fresh_installation]
|
44
44
|
|
45
|
-
|
46
|
-
|
47
|
-
seed_database!
|
45
|
+
prepare_database!
|
48
46
|
|
49
47
|
deploy_to_hosting?
|
50
48
|
end
|
51
49
|
|
52
|
-
|
50
|
+
protected
|
53
51
|
|
54
52
|
def append_asset_pipeline!
|
55
53
|
application_css = 'app/assets/stylesheets/application.css'
|
@@ -77,20 +75,33 @@ end} end
|
|
77
75
|
end
|
78
76
|
|
79
77
|
def append_heroku_gems!
|
80
|
-
append_file 'Gemfile', %
|
78
|
+
append_file 'Gemfile', %Q{
|
79
|
+
# The Ruby version is specified here so that Heroku uses the right version.
|
80
|
+
ruby #{ENV['RUBY_VERSION'].inspect}
|
81
|
+
|
81
82
|
# The Heroku gem allows you to interface with Heroku's API
|
82
83
|
gem 'heroku'
|
83
84
|
|
84
|
-
|
85
|
-
|
85
|
+
group :production do
|
86
|
+
# Dragonfly's S3 Data Store extension allows you to use S3 assets (added for Heroku)
|
87
|
+
gem 'dragonfly-s3_data_store'
|
88
|
+
|
89
|
+
# Gems that are recommended for using Heroku:
|
90
|
+
gem 'rails_12factor'
|
91
|
+
gem 'puma'
|
86
92
|
}
|
87
93
|
# If postgres is not the database in use, Heroku still needs it.
|
88
94
|
if destination_path.join('Gemfile').file? && destination_path.join('Gemfile').read !~ %r{gem ['"]pg['"]}
|
89
95
|
append_file 'Gemfile', %q{
|
90
|
-
# Postgres support (added for Heroku)
|
91
|
-
gem 'pg'
|
96
|
+
# Postgres support (added for Heroku)
|
97
|
+
gem 'pg'
|
92
98
|
}
|
93
99
|
end
|
100
|
+
|
101
|
+
append_file 'Gemfile', %q{
|
102
|
+
end
|
103
|
+
|
104
|
+
} # close the production group that was opened for dragonfly, and pg.
|
94
105
|
end
|
95
106
|
|
96
107
|
def bundle!
|
@@ -99,7 +110,7 @@ gem 'pg'
|
|
99
110
|
|
100
111
|
def copy_files!
|
101
112
|
# The extension installer only installs database templates.
|
102
|
-
Pathname.glob(self.class.source_root.join('**', '*')).reject{|f|
|
113
|
+
Pathname.glob(self.class.source_root.join('**', '*')).reject{ |f|
|
103
114
|
f.directory? or f.to_s =~ /\/db\//
|
104
115
|
}.sort.each do |path|
|
105
116
|
copy_file path, path.to_s.gsub(self.class.source_root.to_s, destination_path.to_s)
|
@@ -109,20 +120,47 @@ gem 'pg'
|
|
109
120
|
def create_decorators!
|
110
121
|
# Create decorator directories
|
111
122
|
%w[controllers models].each do |decorator_namespace|
|
112
|
-
src_file_path = "app/decorators/#{decorator_namespace}/refinery/.
|
123
|
+
src_file_path = "app/decorators/#{decorator_namespace}/refinery/.keep"
|
113
124
|
copy_file self.class.source_root.join(src_file_path), destination_path.join(src_file_path)
|
114
125
|
end
|
115
126
|
end
|
116
127
|
|
128
|
+
def create_heroku_procfile!
|
129
|
+
create_file "Procfile" do
|
130
|
+
"web: bundle exec puma -C config/puma.rb"
|
131
|
+
end unless destination_path.join('Procfile').file?
|
132
|
+
|
133
|
+
create_file "config/puma.rb" do
|
134
|
+
%{threads Integer(ENV['MIN_THREADS'] || 1), Integer(ENV['MAX_THREADS'] || 16)
|
135
|
+
|
136
|
+
workers Integer(ENV['PUMA_WORKERS'] || 3)
|
137
|
+
|
138
|
+
rackup DefaultRackup
|
139
|
+
port ENV['PORT'] || 3000
|
140
|
+
environment ENV['RACK_ENV'] || 'development'
|
141
|
+
preload_app!
|
142
|
+
|
143
|
+
on_worker_boot do
|
144
|
+
# worker specific setup
|
145
|
+
ActiveSupport.on_load(:active_record) do
|
146
|
+
ActiveRecord::Base.establish_connection
|
147
|
+
end
|
148
|
+
end
|
149
|
+
}
|
150
|
+
end unless destination_path.join('config', 'puma.rb').file?
|
151
|
+
end
|
152
|
+
|
117
153
|
def deploy_to_hosting?
|
118
154
|
if heroku?
|
119
155
|
append_heroku_gems!
|
120
156
|
|
121
|
-
bundle!
|
122
|
-
|
123
157
|
# Sanity check the heroku application name and save whatever messages are produced.
|
124
158
|
message = sanity_check_heroku_application_name!
|
125
159
|
|
160
|
+
create_heroku_procfile!
|
161
|
+
|
162
|
+
bundle!
|
163
|
+
|
126
164
|
# Supply the deploy process with the previous messages to make them visible.
|
127
165
|
deploy_to_hosting_heroku!(message)
|
128
166
|
end
|
@@ -144,7 +182,10 @@ gem 'pg'
|
|
144
182
|
run "git push heroku master"
|
145
183
|
|
146
184
|
say_status "Setting up the Heroku database..", nil
|
147
|
-
run "heroku#{' run' if options[:stack] == 'cedar'} rake db:migrate"
|
185
|
+
run "heroku#{' run' if options[:stack] == 'cedar-14'} rake db:migrate"
|
186
|
+
|
187
|
+
say_status "Seeding the Heroku database..", nil
|
188
|
+
run "heroku#{' run' if options[:stack] == 'cedar-14'} rake db:seed"
|
148
189
|
|
149
190
|
say_status "Restarting servers...", nil
|
150
191
|
run "heroku restart"
|
@@ -157,7 +198,7 @@ gem 'pg'
|
|
157
198
|
|
158
199
|
def ensure_environments_are_sane!
|
159
200
|
# Massage environment files
|
160
|
-
%w(development test production).map{|e| "config/environments/#{e}.rb"}.each do |env|
|
201
|
+
%w(development test production).map{ |e| "config/environments/#{e}.rb"}.each do |env|
|
161
202
|
next unless destination_path.join(env).file?
|
162
203
|
|
163
204
|
# Refinery does not necessarily expect action_mailer to be available as
|
@@ -204,10 +245,14 @@ gem 'pg'
|
|
204
245
|
end
|
205
246
|
end
|
206
247
|
|
207
|
-
def
|
248
|
+
def prepare_database!
|
208
249
|
unless self.options[:skip_migrations]
|
209
|
-
|
210
|
-
|
250
|
+
command = %w[railties:install:migrations]
|
251
|
+
unless self.options[:skip_db]
|
252
|
+
command |= %w[db:create db:migrate]
|
253
|
+
command |= %w[db:seed] unless self.options[:skip_migrations]
|
254
|
+
end
|
255
|
+
rake command.join(' ')
|
211
256
|
end
|
212
257
|
end
|
213
258
|
|
@@ -217,14 +262,15 @@ gem 'pg'
|
|
217
262
|
mount = %Q{
|
218
263
|
# This line mounts Refinery's routes at the root of your application.
|
219
264
|
# This means, any requests to the root URL of your application will go to Refinery::PagesController#home.
|
220
|
-
# If you would like to change where this extension is mounted, simply change the
|
265
|
+
# If you would like to change where this extension is mounted, simply change the
|
266
|
+
# configuration option `mounted_path` to something different in config/initializers/refinery/core.rb
|
221
267
|
#
|
222
268
|
# We ask that you don't use the :as option here, as Refinery relies on it being the default of "refinery"
|
223
|
-
mount Refinery::Core::Engine, :
|
269
|
+
mount Refinery::Core::Engine, at: Refinery::Core.mounted_path
|
224
270
|
|
225
271
|
}
|
226
272
|
|
227
|
-
inject_into_file 'config/routes.rb', mount, :
|
273
|
+
inject_into_file 'config/routes.rb', mount, after: ".routes.draw do"
|
228
274
|
end
|
229
275
|
end
|
230
276
|
|
@@ -262,10 +308,6 @@ gem 'pg'
|
|
262
308
|
options[:heroku] = '' if options[:heroku] == 'heroku'
|
263
309
|
end
|
264
310
|
|
265
|
-
def seed_database!
|
266
|
-
rake 'db:seed' unless self.options[:skip_db] || self.options[:skip_migrations]
|
267
|
-
end
|
268
|
-
|
269
311
|
def start_pretending?
|
270
312
|
# Only pretend to do the next actions if this is Refinery to stay DRY
|
271
313
|
if destination_path == Refinery.root
|
File without changes
|
File without changes
|
@@ -3,18 +3,18 @@ development: &development
|
|
3
3
|
host: localhost
|
4
4
|
username: root
|
5
5
|
password:
|
6
|
-
database:
|
6
|
+
database: <%= Rails.application.engine_name.gsub(/_application/,'').downcase %>_development
|
7
7
|
|
8
8
|
test: &test
|
9
9
|
adapter: mysql2
|
10
10
|
host: localhost
|
11
11
|
username: root
|
12
12
|
password:
|
13
|
-
database:
|
13
|
+
database: <%= Rails.application.engine_name.gsub(/_application/,'').downcase %>_test
|
14
14
|
|
15
15
|
production: &production
|
16
16
|
adapter: mysql2
|
17
17
|
host: localhost
|
18
|
-
database:
|
18
|
+
database: <%= Rails.application.engine_name.gsub(/_application/,'').downcase %>_production
|
19
19
|
username: your_production_database_login
|
20
20
|
password: your_production_database_password
|