activeadmin 0.2.2 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of activeadmin might be problematic. Click here for more details.

Files changed (277) hide show
  1. data/.gitignore +34 -0
  2. data/.travis.yml +4 -0
  3. data/.yardopts +8 -0
  4. data/CHANGELOG.md +177 -0
  5. data/Gemfile +21 -32
  6. data/Guardfile +8 -0
  7. data/README.rdoc +75 -14
  8. data/Rakefile +7 -100
  9. data/activeadmin.gemspec +21 -353
  10. data/{lib/generators/active_admin/install/templates/images → app/assets/images/active_admin}/admin_notes_icon.png +0 -0
  11. data/app/assets/images/active_admin/datepicker/datepicker-header-bg.png +0 -0
  12. data/app/assets/images/active_admin/datepicker/datepicker-input-icon.png +0 -0
  13. data/app/assets/images/active_admin/datepicker/datepicker-next-link-icon.png +0 -0
  14. data/app/assets/images/active_admin/datepicker/datepicker-nipple.png +0 -0
  15. data/app/assets/images/active_admin/datepicker/datepicker-prev-link-icon.png +0 -0
  16. data/{lib/generators/active_admin/install/templates/images → app/assets/images/active_admin}/loading.gif +0 -0
  17. data/{lib/generators/active_admin/install/templates/images → app/assets/images/active_admin}/nested_menu_arrow.gif +0 -0
  18. data/{lib/generators/active_admin/install/templates/images → app/assets/images/active_admin}/nested_menu_arrow_dark.gif +0 -0
  19. data/{lib/generators/active_admin/install/templates/images → app/assets/images/active_admin}/orderable.png +0 -0
  20. data/app/assets/javascripts/active_admin/base.js +12 -0
  21. data/{lib/generators/active_admin/install/templates/active_admin_vendor.js → app/assets/javascripts/active_admin/vendor.js} +0 -0
  22. data/{lib/active_admin/stylesheets/active_admin.scss → app/assets/stylesheets/active_admin/_base.css.scss} +58 -82
  23. data/{lib/active_admin/stylesheets/active_admin/_forms.scss → app/assets/stylesheets/active_admin/_forms.css.scss} +94 -5
  24. data/{lib/active_admin/stylesheets/active_admin/_header.scss → app/assets/stylesheets/active_admin/_header.css.scss} +13 -11
  25. data/app/assets/stylesheets/active_admin/_mixins.css.scss +1 -0
  26. data/{lib/active_admin/stylesheets/active_admin/_typography.scss → app/assets/stylesheets/active_admin/_typography.css.scss} +0 -0
  27. data/{lib/active_admin/stylesheets/active_admin/_comments.scss → app/assets/stylesheets/active_admin/components/_comments.css.scss} +0 -0
  28. data/app/assets/stylesheets/active_admin/components/_date_picker.css.scss +123 -0
  29. data/app/assets/stylesheets/active_admin/components/_flash_messages.css.scss +38 -0
  30. data/{lib/active_admin/stylesheets/active_admin/mixins/_all.scss → app/assets/stylesheets/active_admin/mixins/_all.css.scss} +0 -0
  31. data/{lib/active_admin/stylesheets/active_admin/mixins/_buttons.scss → app/assets/stylesheets/active_admin/mixins/_buttons.css.scss} +0 -0
  32. data/{lib/active_admin/stylesheets/active_admin/mixins/_gradients.scss → app/assets/stylesheets/active_admin/mixins/_gradients.css.scss} +8 -0
  33. data/{lib/active_admin/stylesheets/active_admin/mixins/_icons.scss → app/assets/stylesheets/active_admin/mixins/_icons.css.scss} +0 -0
  34. data/{lib/active_admin/stylesheets/active_admin/mixins/_reset.scss → app/assets/stylesheets/active_admin/mixins/_reset.css.scss} +0 -0
  35. data/{lib/active_admin/stylesheets/active_admin/mixins/_rounded.scss → app/assets/stylesheets/active_admin/mixins/_rounded.css.scss} +0 -0
  36. data/{lib/active_admin/stylesheets/active_admin/mixins/_sections.scss → app/assets/stylesheets/active_admin/mixins/_sections.css.scss} +9 -2
  37. data/{lib/active_admin/stylesheets/active_admin/mixins/_shadows.scss → app/assets/stylesheets/active_admin/mixins/_shadows.css.scss} +1 -1
  38. data/{lib/active_admin/stylesheets/active_admin/mixins/_variables.scss → app/assets/stylesheets/active_admin/mixins/_variables.css.scss} +12 -3
  39. data/{lib/active_admin/views/templates/active_admin_dashboard → app/views/active_admin/dashboard}/index.html.arb +0 -0
  40. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/mailer/reset_password_instructions.html.erb +0 -0
  41. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/mailer/unlock_instructions.html.erb +0 -0
  42. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/passwords/edit.html.erb +0 -0
  43. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/passwords/new.html.erb +0 -0
  44. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/sessions/new.html.erb +1 -1
  45. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/shared/_links.erb +0 -0
  46. data/{lib/active_admin/views/templates → app/views}/active_admin/devise/unlocks/new.html.erb +0 -0
  47. data/{lib/active_admin/views/templates/active_admin_default → app/views/active_admin/resource}/edit.html.arb +0 -0
  48. data/app/views/active_admin/resource/index.csv.erb +20 -0
  49. data/{lib/active_admin/views/templates/active_admin_default → app/views/active_admin/resource}/index.html.arb +0 -0
  50. data/{lib/active_admin/views/templates/active_admin_default → app/views/active_admin/resource}/new.html.arb +0 -0
  51. data/{lib/active_admin/views/templates/active_admin_default → app/views/active_admin/resource}/show.html.arb +0 -0
  52. data/app/views/layouts/active_admin.html.arb +1 -0
  53. data/{lib/active_admin/views/templates → app/views}/layouts/active_admin_logged_out.html.erb +8 -4
  54. data/docs/0-installation.md +50 -0
  55. data/docs/1-general-configuration.md +43 -0
  56. data/docs/2-resource-customization.md +35 -0
  57. data/docs/3-index-pages.md +55 -0
  58. data/docs/3-index-pages/index-as-block.md +16 -0
  59. data/docs/3-index-pages/index-as-blog.md +61 -0
  60. data/docs/3-index-pages/index-as-grid.md +21 -0
  61. data/docs/3-index-pages/index-as-table.md +90 -0
  62. data/docs/4-csv-format.md +14 -0
  63. data/docs/5-forms.md +39 -0
  64. data/docs/6-show-screens.md +22 -0
  65. data/docs/7-sidebars.md +35 -0
  66. data/docs/8-custom-actions.md +123 -0
  67. data/features/comments/commenting.feature +31 -4
  68. data/features/edit_page.feature +30 -1
  69. data/features/index/filters.feature +35 -0
  70. data/features/index/format_as_csv.feature +46 -0
  71. data/features/index/formats.feature +2 -0
  72. data/features/index/index_as_block.feature +1 -1
  73. data/features/index/index_as_grid.feature +1 -1
  74. data/features/index/index_as_table.feature +2 -0
  75. data/features/index/index_blank_slate.feature +56 -0
  76. data/features/index/pagination.feature +0 -6
  77. data/features/registering_assets.feature +2 -2
  78. data/features/sidebar_sections.feature +7 -8
  79. data/features/specifying_actions.feature +72 -1
  80. data/features/step_definitions/action_item_steps.rb +2 -2
  81. data/features/step_definitions/additional_web_steps.rb +26 -16
  82. data/features/step_definitions/attribute_steps.rb +5 -7
  83. data/features/step_definitions/configuration_steps.rb +9 -9
  84. data/features/step_definitions/factory_steps.rb +4 -3
  85. data/features/step_definitions/format_steps.rb +29 -1
  86. data/features/step_definitions/layout_steps.rb +3 -0
  87. data/features/step_definitions/menu_steps.rb +2 -2
  88. data/features/step_definitions/sidebar_steps.rb +1 -5
  89. data/features/step_definitions/user_steps.rb +8 -2
  90. data/features/step_definitions/web_steps.rb +82 -90
  91. data/features/sti_resource.feature +12 -0
  92. data/features/support/env.rb +12 -10
  93. data/features/support/paths.rb +2 -0
  94. data/features/support/selectors.rb +45 -0
  95. data/lib/active_admin.rb +33 -263
  96. data/lib/active_admin/application.rb +228 -0
  97. data/lib/active_admin/arbre.rb +10 -10
  98. data/lib/active_admin/arbre/{html.rb → builder.rb} +29 -2
  99. data/lib/active_admin/arbre/context.rb +8 -0
  100. data/lib/active_admin/arbre/{attributes.rb → html/attributes.rb} +0 -0
  101. data/lib/active_admin/arbre/{class_list.rb → html/class_list.rb} +0 -0
  102. data/lib/active_admin/arbre/{collection.rb → html/collection.rb} +0 -0
  103. data/lib/active_admin/arbre/{document.rb → html/document.rb} +0 -0
  104. data/lib/active_admin/arbre/{element.rb → html/element.rb} +6 -6
  105. data/lib/active_admin/arbre/{html5_elements.rb → html/html5_elements.rb} +0 -0
  106. data/lib/active_admin/arbre/{tag.rb → html/tag.rb} +0 -0
  107. data/lib/active_admin/arbre/{text_node.rb → html/text_node.rb} +0 -0
  108. data/lib/active_admin/asset_registration.rb +1 -1
  109. data/lib/active_admin/callbacks.rb +5 -3
  110. data/lib/active_admin/comments.rb +3 -3
  111. data/lib/active_admin/comments/comment.rb +6 -0
  112. data/lib/active_admin/comments/configuration.rb +8 -6
  113. data/lib/active_admin/comments/namespace_helper.rb +1 -1
  114. data/lib/active_admin/comments/views/active_admin_comments.rb +1 -1
  115. data/lib/active_admin/csv_builder.rb +45 -0
  116. data/lib/active_admin/dashboards.rb +1 -1
  117. data/lib/active_admin/dashboards/dashboard_controller.rb +3 -10
  118. data/lib/active_admin/dependency_checker.rb +28 -0
  119. data/lib/active_admin/deprecation.rb +36 -0
  120. data/lib/active_admin/devise.rb +14 -3
  121. data/lib/active_admin/dsl.rb +26 -4
  122. data/lib/active_admin/engine.rb +4 -0
  123. data/lib/active_admin/form_builder.rb +18 -9
  124. data/lib/active_admin/helpers/scope_chain.rb +23 -0
  125. data/lib/active_admin/helpers/settings.rb +70 -0
  126. data/lib/active_admin/locales/cs.yml +34 -0
  127. data/lib/active_admin/locales/da.yml +28 -0
  128. data/lib/active_admin/locales/en.yml +40 -0
  129. data/lib/active_admin/locales/es.yml +40 -0
  130. data/lib/active_admin/locales/fr.yml +40 -0
  131. data/lib/active_admin/locales/it.yml +39 -0
  132. data/lib/active_admin/locales/pl.yml +34 -0
  133. data/lib/active_admin/locales/pt-BR.yml +41 -0
  134. data/lib/active_admin/locales/ru.yml +40 -0
  135. data/lib/active_admin/locales/zh_cn.yml +40 -0
  136. data/lib/active_admin/menu_item.rb +6 -0
  137. data/lib/active_admin/namespace.rb +14 -5
  138. data/lib/active_admin/reloader.rb +30 -0
  139. data/lib/active_admin/renderer.rb +1 -1
  140. data/lib/active_admin/resource.rb +45 -88
  141. data/lib/active_admin/resource/action_items.rb +88 -0
  142. data/lib/active_admin/resource/menu.rb +45 -0
  143. data/lib/active_admin/resource/naming.rb +46 -0
  144. data/lib/active_admin/resource/scopes.rb +33 -0
  145. data/lib/active_admin/resource/sidebars.rb +36 -0
  146. data/lib/active_admin/resource_controller.rb +32 -37
  147. data/lib/active_admin/resource_controller/action_builder.rb +1 -1
  148. data/lib/active_admin/resource_controller/actions.rb +66 -40
  149. data/lib/active_admin/resource_controller/callbacks.rb +1 -1
  150. data/lib/active_admin/resource_controller/collection.rb +9 -14
  151. data/lib/active_admin/resource_controller/filters.rb +1 -1
  152. data/lib/active_admin/resource_controller/form.rb +1 -1
  153. data/lib/active_admin/resource_controller/menu.rb +1 -1
  154. data/lib/active_admin/resource_controller/page_configurations.rb +2 -2
  155. data/lib/active_admin/resource_controller/scoping.rb +1 -1
  156. data/lib/active_admin/resource_controller/sidebars.rb +1 -21
  157. data/lib/active_admin/router.rb +85 -0
  158. data/lib/active_admin/sass/active_admin.scss +3 -0
  159. data/lib/active_admin/sass/css_loader.rb +16 -0
  160. data/lib/active_admin/sass/helpers.rb +45 -0
  161. data/lib/active_admin/scope.rb +16 -2
  162. data/lib/active_admin/sidebar_section.rb +41 -0
  163. data/lib/active_admin/stylesheets/active_admin/mixins/_utilities.scss +0 -0
  164. data/lib/active_admin/version.rb +1 -1
  165. data/lib/active_admin/view_factory.rb +5 -3
  166. data/lib/active_admin/view_helpers.rb +1 -2
  167. data/lib/active_admin/view_helpers/active_admin_application_helper.rb +12 -0
  168. data/lib/active_admin/view_helpers/auto_link_helper.rb +2 -1
  169. data/lib/active_admin/view_helpers/display_helper.rb +1 -1
  170. data/lib/active_admin/view_helpers/filter_form_helper.rb +26 -14
  171. data/lib/active_admin/view_helpers/form_helper.rb +1 -0
  172. data/lib/active_admin/view_helpers/view_factory_helper.rb +1 -1
  173. data/lib/active_admin/views/components/attributes_table.rb +2 -2
  174. data/lib/active_admin/views/components/blank_slate.rb +17 -0
  175. data/lib/active_admin/views/components/columns.rb +1 -3
  176. data/lib/active_admin/views/components/paginated_collection.rb +26 -8
  177. data/lib/active_admin/views/components/scopes.rb +13 -8
  178. data/lib/active_admin/views/components/sidebar_section.rb +1 -3
  179. data/lib/active_admin/views/components/status_tag.rb +55 -0
  180. data/lib/active_admin/views/components/table_for.rb +25 -6
  181. data/lib/active_admin/views/header_renderer.rb +20 -4
  182. data/lib/active_admin/views/index_as_block.rb +12 -7
  183. data/lib/active_admin/views/index_as_blog.rb +61 -21
  184. data/lib/active_admin/views/index_as_grid.rb +22 -1
  185. data/lib/active_admin/views/index_as_table.rb +97 -6
  186. data/lib/active_admin/views/pages/base.rb +20 -9
  187. data/lib/active_admin/views/pages/dashboard.rb +7 -4
  188. data/lib/active_admin/views/pages/edit.rb +3 -2
  189. data/lib/active_admin/views/pages/index.rb +30 -5
  190. data/lib/active_admin/views/pages/layout.rb +26 -0
  191. data/lib/active_admin/views/pages/new.rb +3 -2
  192. data/lib/active_admin/views/pages/show.rb +1 -1
  193. data/lib/active_admin/views/tabbed_navigation.rb +94 -0
  194. data/lib/generators/active_admin/assets/assets_generator.rb +21 -0
  195. data/lib/generators/active_admin/assets/templates/3.0/active_admin.js +427 -0
  196. data/lib/generators/active_admin/assets/templates/3.1/active_admin.css.scss +6 -0
  197. data/lib/generators/active_admin/assets/templates/3.1/active_admin.js +1 -0
  198. data/lib/generators/active_admin/assets/templates/dashboards.rb +36 -0
  199. data/lib/generators/active_admin/install/install_generator.rb +2 -4
  200. data/lib/generators/active_admin/install/templates/active_admin.rb.erb +26 -4
  201. data/lib/generators/active_admin/install/templates/dashboards.rb +4 -2
  202. data/lib/generators/active_admin/install/templates/migrations/2_move_admin_notes_to_comments.rb +2 -2
  203. data/script/local +44 -0
  204. data/script/use_rails +46 -0
  205. data/spec/integration/belongs_to_spec.rb +1 -1
  206. data/spec/integration/default_namespace.rb +77 -0
  207. data/spec/integration/javascript_spec.rb +20 -0
  208. data/spec/integration/stylesheets_spec.rb +41 -0
  209. data/spec/spec_helper.rb +21 -11
  210. data/spec/support/detect_rails_version.rb +10 -0
  211. data/spec/support/integration_example_group.rb +1 -1
  212. data/spec/support/jslint.yml +80 -0
  213. data/spec/support/rails_template.rb +1 -1
  214. data/spec/support/rails_template_with_data.rb +2 -1
  215. data/spec/support/templates/cucumber.rb +0 -4
  216. data/spec/unit/active_admin_spec.rb +8 -44
  217. data/spec/unit/application_spec.rb +78 -0
  218. data/spec/unit/arbre/context_spec.rb +22 -0
  219. data/spec/unit/arbre/html/element_finder_methods_spec.rb +2 -2
  220. data/spec/unit/arbre/html/element_spec.rb +2 -3
  221. data/spec/unit/arbre/html/tag_attributes_spec.rb +2 -2
  222. data/spec/unit/arbre/html/tag_spec.rb +2 -2
  223. data/spec/unit/arbre/html_spec.rb +2 -3
  224. data/spec/unit/auto_link_spec.rb +2 -1
  225. data/spec/unit/belongs_to_spec.rb +2 -1
  226. data/spec/unit/comments_spec.rb +43 -39
  227. data/spec/unit/controller_filters_spec.rb +11 -3
  228. data/spec/unit/csv_builder_spec.rb +83 -0
  229. data/spec/unit/devise_spec.rb +66 -0
  230. data/spec/unit/display_name_spec.rb +2 -2
  231. data/spec/unit/filter_form_builder_spec.rb +6 -3
  232. data/spec/unit/form_builder_spec.rb +20 -2
  233. data/spec/unit/generators/install_rails_3_1_spec.rb +16 -0
  234. data/spec/unit/helpers/scope_chain_spec.rb +36 -0
  235. data/spec/unit/helpers/settings_spec.rb +30 -0
  236. data/spec/unit/menu_item_spec.rb +6 -0
  237. data/spec/unit/namespace_spec.rb +68 -19
  238. data/spec/unit/rails_spec.rb +43 -0
  239. data/spec/unit/registration_spec.rb +18 -27
  240. data/spec/unit/reloader_spec.rb +28 -0
  241. data/spec/unit/resource/action_items_spec.rb +62 -0
  242. data/spec/unit/resource/menu_spec.rb +80 -0
  243. data/spec/unit/resource/naming_spec.rb +64 -0
  244. data/spec/unit/resource/scopes_spec.rb +30 -0
  245. data/spec/unit/resource/sidebars_spec.rb +50 -0
  246. data/spec/unit/resource_controller/collection_spec.rb +1 -1
  247. data/spec/unit/resource_controller_spec.rb +29 -24
  248. data/spec/unit/resource_spec.rb +78 -94
  249. data/spec/unit/sass/helpers_spec.rb +47 -0
  250. data/spec/unit/scope_spec.rb +11 -1
  251. data/spec/unit/view_factory_spec.rb +4 -1
  252. data/spec/unit/{components → views/components}/attributes_table_spec.rb +2 -2
  253. data/spec/unit/views/components/blank_slate_spec.rb +15 -0
  254. data/spec/unit/{components → views/components}/columns_spec.rb +2 -2
  255. data/spec/unit/{components → views/components}/panel_spec.rb +1 -3
  256. data/spec/unit/{components → views/components}/sidebar_section_spec.rb +3 -3
  257. data/spec/unit/views/components/status_tag_spec.rb +79 -0
  258. data/spec/unit/{components → views/components}/table_for_spec.rb +2 -1
  259. data/spec/unit/views/pages/layout_spec.rb +22 -0
  260. data/spec/unit/views/tabbed_navigation_spec.rb +125 -0
  261. data/tasks/docs.rake +39 -0
  262. data/tasks/test.rake +55 -0
  263. data/tasks/yard.rake +6 -0
  264. metadata +310 -189
  265. data/CHANGELOG.rdoc +0 -76
  266. data/lib/active_admin/action_items.rb +0 -37
  267. data/lib/active_admin/sidebar.rb +0 -39
  268. data/lib/active_admin/stylesheets/active_admin/_flash_messages.scss +0 -13
  269. data/lib/active_admin/view_helpers/status_tag_helper.rb +0 -13
  270. data/lib/active_admin/view_helpers/table_helper.rb +0 -12
  271. data/lib/active_admin/views/tabs_renderer.rb +0 -52
  272. data/lib/active_admin/views/templates/active_admin_default/index.csv.erb +0 -2
  273. data/lib/active_admin/views/templates/layouts/active_admin.html.erb +0 -39
  274. data/lib/generators/active_admin/install/templates/active_admin.js +0 -51
  275. data/spec/controllers/index_as_csv_spec.rb +0 -35
  276. data/spec/unit/action_items_spec.rb +0 -27
  277. data/spec/unit/tabs_renderer_spec.rb +0 -56
data/Rakefile CHANGED
@@ -1,111 +1,18 @@
1
- require 'rubygems'
2
1
  require "bundler"
3
2
  Bundler.setup
3
+ Bundler::GemHelper.install_tasks
4
4
 
5
5
  require 'rake'
6
6
 
7
7
  def cmd(command)
8
8
  puts command
9
- system command
9
+ raise unless system command
10
10
  end
11
11
 
12
- desc "Install all supported versions of rails"
13
- task :install_all_rails do
14
- (0..7).to_a.each do |v|
15
- system "rm Gemfile.lock"
16
- puts "Installing for RAILS=3.0.#{v}"
17
- cmd "RAILS=3.0.#{v} bundle install"
18
- end
19
- end
20
-
21
- desc "Creates a test rails app for the specs to run against"
22
- task :setup do
23
- require 'rails/version'
24
- system("mkdir spec/rails") unless File.exists?("spec/rails")
25
- system "bundle exec rails new spec/rails/rails-#{Rails::VERSION::STRING} -m spec/support/rails_template.rb"
26
- end
27
-
28
- namespace :local do
29
- desc "Creates a local rails app to play with in development"
30
- task :setup do
31
- unless File.exists? "test-rails-app"
32
- system "bundle exec rails new test-rails-app -m spec/support/rails_template_with_data.rb"
33
- end
34
- end
35
-
36
- desc "Start a local rails app to play"
37
- task :server => :setup do
38
- exec "cd test-rails-app && GEMFILE=../Gemfile bundle exec rails s"
39
- end
40
-
41
- desc "Load the local rails console"
42
- task :console => :setup do
43
- exec "cd test-rails-app && GEMFILE=../Gemfile bundle exec rails c"
44
- end
45
- end
46
-
47
- require "rspec/core/rake_task"
48
- RSpec::Core::RakeTask.new(:spec)
49
-
50
- RSpec::Core::RakeTask.new(:rcov) do |spec|
51
- spec.rcov = true
52
- end
53
-
54
- task :default => :spec
12
+ require File.expand_path('../spec/support/detect_rails_version', __FILE__)
55
13
 
56
- namespace :spec do
57
- desc "Run specs for all versions of rails"
58
- task :all do
59
- (0..6).to_a.each do |v|
60
- puts "Running for Rails 3.0.#{v}"
61
- cmd "rm Gemfile.lock" if File.exists?("Gemfile.lock")
62
- cmd "/usr/bin/env RAILS=3.0.#{v} bundle install"
63
- cmd "/usr/bin/env RAILS=3.0.#{v} rake spec"
64
- end
65
- end
66
- end
67
-
68
- require 'cucumber/rake/task'
69
-
70
- namespace :cucumber do
71
- Cucumber::Rake::Task.new(:all) do |t|
72
- t.profile = 'default'
73
- end
74
-
75
- Cucumber::Rake::Task.new(:wip) do |t|
76
- t.profile = 'wip'
77
- end
78
- end
79
-
80
- task :cucumber => "cucumber:all"
81
-
82
- require 'rake/rdoctask'
83
- Rake::RDocTask.new do |rdoc|
84
- version = File.exist?('VERSION') ? File.read('VERSION') : ""
14
+ # Import all our rake tasks
15
+ FileList['tasks/**/*.rake'].each { |task| import task }
85
16
 
86
- rdoc.rdoc_dir = 'rdoc'
87
- rdoc.title = "active_admin #{version}"
88
- rdoc.rdoc_files.include('README*')
89
- rdoc.rdoc_files.include('lib/**/*.rb')
90
- end
91
-
92
- begin
93
- require 'jeweler'
94
- Jeweler::Tasks.new do |gem|
95
- gem.name = "activeadmin"
96
- gem.summary = "The administration framework for Ruby on Rails."
97
- gem.description = "The administration framework for Ruby on Rails."
98
- gem.email = "gregdbell@gmail.com"
99
- gem.homepage = "http://github.com/gregbell/active_admin"
100
- gem.authors = ["Greg Bell"]
101
-
102
- gem.files.exclude 'spec/rails'
103
- gem.test_files.exclude 'spec/rails'
104
-
105
- require File.join(File.dirname(File.expand_path(__FILE__)), 'lib', 'active_admin', 'version')
106
- gem.version = ActiveAdmin::VERSION
107
- end
108
- Jeweler::GemcutterTasks.new
109
- rescue LoadError
110
- puts "Jeweler not available. Install it with: gem install jeweler"
111
- end
17
+ # Run the specs & cukes
18
+ task :default => :test
@@ -1,360 +1,28 @@
1
- # Generated by jeweler
2
- # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
1
  # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "active_admin/version"
5
4
 
6
5
  Gem::Specification.new do |s|
7
- s.name = %q{activeadmin}
8
- s.version = "0.2.2"
6
+ s.name = %q{activeadmin}
7
+ s.version = ActiveAdmin::VERSION
8
+ s.platform = Gem::Platform::RUBY
9
+ s.homepage = %q{http://activeadmin.info}
10
+ s.authors = ["Greg Bell"]
11
+ s.email = ["gregdbell@gmail.com"]
12
+ s.description = %q{The administration framework for Ruby on Rails.}
13
+ s.summary = %q{The administration framework for Ruby on Rails.}
9
14
 
10
- s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
- s.authors = ["Greg Bell"]
12
- s.date = %q{2011-05-27}
13
- s.description = %q{The administration framework for Ruby on Rails.}
14
- s.email = %q{gregdbell@gmail.com}
15
- s.extra_rdoc_files = [
16
- "LICENSE",
17
- "README.rdoc"
18
- ]
19
- s.files = [
20
- ".document",
21
- "CHANGELOG.rdoc",
22
- "Gemfile",
23
- "LICENSE",
24
- "README.rdoc",
25
- "Rakefile",
26
- "activeadmin.gemspec",
27
- "cucumber.yml",
28
- "features/comments/commenting.feature",
29
- "features/comments/viewing_index.feature",
30
- "features/dashboard.feature",
31
- "features/edit_page.feature",
32
- "features/first_boot.feature",
33
- "features/global_navigation.feature",
34
- "features/index/formats.feature",
35
- "features/index/index_as_block.feature",
36
- "features/index/index_as_blog.feature",
37
- "features/index/index_as_grid.feature",
38
- "features/index/index_as_table.feature",
39
- "features/index/index_scopes.feature",
40
- "features/index/pagination.feature",
41
- "features/menu.feature",
42
- "features/new_page.feature",
43
- "features/registering_assets.feature",
44
- "features/registering_resources.feature",
45
- "features/show/default_content.feature",
46
- "features/show/page_title.feature",
47
- "features/sidebar_sections.feature",
48
- "features/specifying_actions.feature",
49
- "features/step_definitions/action_item_steps.rb",
50
- "features/step_definitions/additional_web_steps.rb",
51
- "features/step_definitions/asset_steps.rb",
52
- "features/step_definitions/attribute_steps.rb",
53
- "features/step_definitions/comment_steps.rb",
54
- "features/step_definitions/configuration_steps.rb",
55
- "features/step_definitions/dashboard_steps.rb",
56
- "features/step_definitions/factory_steps.rb",
57
- "features/step_definitions/flash_steps.rb",
58
- "features/step_definitions/format_steps.rb",
59
- "features/step_definitions/index_scope_steps.rb",
60
- "features/step_definitions/menu_steps.rb",
61
- "features/step_definitions/pagination_steps.rb",
62
- "features/step_definitions/sidebar_steps.rb",
63
- "features/step_definitions/tab_steps.rb",
64
- "features/step_definitions/user_steps.rb",
65
- "features/step_definitions/web_steps.rb",
66
- "features/sti_resource.feature",
67
- "features/support/env.rb",
68
- "features/support/paths.rb",
69
- "features/users/logging_in.feature",
70
- "features/users/logging_out.feature",
71
- "lib/active_admin.rb",
72
- "lib/active_admin/abstract_view_factory.rb",
73
- "lib/active_admin/action_items.rb",
74
- "lib/active_admin/arbre.rb",
75
- "lib/active_admin/arbre/attributes.rb",
76
- "lib/active_admin/arbre/class_list.rb",
77
- "lib/active_admin/arbre/collection.rb",
78
- "lib/active_admin/arbre/context.rb",
79
- "lib/active_admin/arbre/core_extensions.rb",
80
- "lib/active_admin/arbre/document.rb",
81
- "lib/active_admin/arbre/element.rb",
82
- "lib/active_admin/arbre/html.rb",
83
- "lib/active_admin/arbre/html5_elements.rb",
84
- "lib/active_admin/arbre/tag.rb",
85
- "lib/active_admin/arbre/text_node.rb",
86
- "lib/active_admin/asset_registration.rb",
87
- "lib/active_admin/callbacks.rb",
88
- "lib/active_admin/comments.rb",
89
- "lib/active_admin/comments/comment.rb",
90
- "lib/active_admin/comments/configuration.rb",
91
- "lib/active_admin/comments/namespace_helper.rb",
92
- "lib/active_admin/comments/resource_helper.rb",
93
- "lib/active_admin/comments/show_page_helper.rb",
94
- "lib/active_admin/comments/views.rb",
95
- "lib/active_admin/comments/views/active_admin_comment.rb",
96
- "lib/active_admin/comments/views/active_admin_comments.rb",
97
- "lib/active_admin/component.rb",
98
- "lib/active_admin/controller_action.rb",
99
- "lib/active_admin/dashboards.rb",
100
- "lib/active_admin/dashboards/dashboard_controller.rb",
101
- "lib/active_admin/dashboards/section.rb",
102
- "lib/active_admin/devise.rb",
103
- "lib/active_admin/dsl.rb",
104
- "lib/active_admin/event.rb",
105
- "lib/active_admin/form_builder.rb",
106
- "lib/active_admin/helpers/optional_display.rb",
107
- "lib/active_admin/iconic.rb",
108
- "lib/active_admin/iconic/icons.rb",
109
- "lib/active_admin/menu.rb",
110
- "lib/active_admin/menu_item.rb",
111
- "lib/active_admin/namespace.rb",
112
- "lib/active_admin/page_config.rb",
113
- "lib/active_admin/renderer.rb",
114
- "lib/active_admin/resource.rb",
115
- "lib/active_admin/resource/belongs_to.rb",
116
- "lib/active_admin/resource_controller.rb",
117
- "lib/active_admin/resource_controller/action_builder.rb",
118
- "lib/active_admin/resource_controller/actions.rb",
119
- "lib/active_admin/resource_controller/callbacks.rb",
120
- "lib/active_admin/resource_controller/collection.rb",
121
- "lib/active_admin/resource_controller/filters.rb",
122
- "lib/active_admin/resource_controller/form.rb",
123
- "lib/active_admin/resource_controller/menu.rb",
124
- "lib/active_admin/resource_controller/page_configurations.rb",
125
- "lib/active_admin/resource_controller/scoping.rb",
126
- "lib/active_admin/resource_controller/sidebars.rb",
127
- "lib/active_admin/scope.rb",
128
- "lib/active_admin/sidebar.rb",
129
- "lib/active_admin/stylesheets/active_admin.scss",
130
- "lib/active_admin/stylesheets/active_admin/_comments.scss",
131
- "lib/active_admin/stylesheets/active_admin/_flash_messages.scss",
132
- "lib/active_admin/stylesheets/active_admin/_forms.scss",
133
- "lib/active_admin/stylesheets/active_admin/_header.scss",
134
- "lib/active_admin/stylesheets/active_admin/_typography.scss",
135
- "lib/active_admin/stylesheets/active_admin/mixins/_all.scss",
136
- "lib/active_admin/stylesheets/active_admin/mixins/_buttons.scss",
137
- "lib/active_admin/stylesheets/active_admin/mixins/_gradients.scss",
138
- "lib/active_admin/stylesheets/active_admin/mixins/_icons.scss",
139
- "lib/active_admin/stylesheets/active_admin/mixins/_reset.scss",
140
- "lib/active_admin/stylesheets/active_admin/mixins/_rounded.scss",
141
- "lib/active_admin/stylesheets/active_admin/mixins/_sections.scss",
142
- "lib/active_admin/stylesheets/active_admin/mixins/_shadows.scss",
143
- "lib/active_admin/stylesheets/active_admin/mixins/_variables.scss",
144
- "lib/active_admin/version.rb",
145
- "lib/active_admin/view_factory.rb",
146
- "lib/active_admin/view_helpers.rb",
147
- "lib/active_admin/view_helpers/assigns_with_indifferent_access_helper.rb",
148
- "lib/active_admin/view_helpers/auto_link_helper.rb",
149
- "lib/active_admin/view_helpers/breadcrumb_helper.rb",
150
- "lib/active_admin/view_helpers/display_helper.rb",
151
- "lib/active_admin/view_helpers/filter_form_helper.rb",
152
- "lib/active_admin/view_helpers/form_helper.rb",
153
- "lib/active_admin/view_helpers/icon_helper.rb",
154
- "lib/active_admin/view_helpers/method_or_proc_helper.rb",
155
- "lib/active_admin/view_helpers/renderer_helper.rb",
156
- "lib/active_admin/view_helpers/sidebar_helper.rb",
157
- "lib/active_admin/view_helpers/status_tag_helper.rb",
158
- "lib/active_admin/view_helpers/table_helper.rb",
159
- "lib/active_admin/view_helpers/title_helper.rb",
160
- "lib/active_admin/view_helpers/view_factory_helper.rb",
161
- "lib/active_admin/views.rb",
162
- "lib/active_admin/views/action_items.rb",
163
- "lib/active_admin/views/components/attributes_table.rb",
164
- "lib/active_admin/views/components/columns.rb",
165
- "lib/active_admin/views/components/paginated_collection.rb",
166
- "lib/active_admin/views/components/panel.rb",
167
- "lib/active_admin/views/components/scopes.rb",
168
- "lib/active_admin/views/components/sidebar_section.rb",
169
- "lib/active_admin/views/components/table_for.rb",
170
- "lib/active_admin/views/dashboard_section_renderer.rb",
171
- "lib/active_admin/views/header_renderer.rb",
172
- "lib/active_admin/views/index_as_block.rb",
173
- "lib/active_admin/views/index_as_blog.rb",
174
- "lib/active_admin/views/index_as_grid.rb",
175
- "lib/active_admin/views/index_as_table.rb",
176
- "lib/active_admin/views/pages/base.rb",
177
- "lib/active_admin/views/pages/dashboard.rb",
178
- "lib/active_admin/views/pages/edit.rb",
179
- "lib/active_admin/views/pages/index.rb",
180
- "lib/active_admin/views/pages/new.rb",
181
- "lib/active_admin/views/pages/show.rb",
182
- "lib/active_admin/views/tabs_renderer.rb",
183
- "lib/active_admin/views/templates/active_admin/devise/mailer/reset_password_instructions.html.erb",
184
- "lib/active_admin/views/templates/active_admin/devise/mailer/unlock_instructions.html.erb",
185
- "lib/active_admin/views/templates/active_admin/devise/passwords/edit.html.erb",
186
- "lib/active_admin/views/templates/active_admin/devise/passwords/new.html.erb",
187
- "lib/active_admin/views/templates/active_admin/devise/sessions/new.html.erb",
188
- "lib/active_admin/views/templates/active_admin/devise/shared/_links.erb",
189
- "lib/active_admin/views/templates/active_admin/devise/unlocks/new.html.erb",
190
- "lib/active_admin/views/templates/active_admin_dashboard/index.html.arb",
191
- "lib/active_admin/views/templates/active_admin_default/edit.html.arb",
192
- "lib/active_admin/views/templates/active_admin_default/index.csv.erb",
193
- "lib/active_admin/views/templates/active_admin_default/index.html.arb",
194
- "lib/active_admin/views/templates/active_admin_default/new.html.arb",
195
- "lib/active_admin/views/templates/active_admin_default/show.html.arb",
196
- "lib/active_admin/views/templates/layouts/active_admin.html.erb",
197
- "lib/active_admin/views/templates/layouts/active_admin_logged_out.html.erb",
198
- "lib/activeadmin.rb",
199
- "lib/generators/active_admin/devise/devise_generator.rb",
200
- "lib/generators/active_admin/install/install_generator.rb",
201
- "lib/generators/active_admin/install/templates/active_admin.js",
202
- "lib/generators/active_admin/install/templates/active_admin.rb.erb",
203
- "lib/generators/active_admin/install/templates/active_admin_vendor.js",
204
- "lib/generators/active_admin/install/templates/dashboards.rb",
205
- "lib/generators/active_admin/install/templates/images/admin_notes_icon.png",
206
- "lib/generators/active_admin/install/templates/images/loading.gif",
207
- "lib/generators/active_admin/install/templates/images/nested_menu_arrow.gif",
208
- "lib/generators/active_admin/install/templates/images/nested_menu_arrow_dark.gif",
209
- "lib/generators/active_admin/install/templates/images/orderable.png",
210
- "lib/generators/active_admin/install/templates/migrations/1_create_admin_notes.rb",
211
- "lib/generators/active_admin/install/templates/migrations/2_move_admin_notes_to_comments.rb",
212
- "lib/generators/active_admin/resource/resource_generator.rb",
213
- "lib/generators/active_admin/resource/templates/admin.rb",
214
- "spec/controllers/index_as_csv_spec.rb",
215
- "spec/integration/belongs_to_spec.rb",
216
- "spec/spec_helper.rb",
217
- "spec/support/integration_example_group.rb",
218
- "spec/support/rails_template.rb",
219
- "spec/support/rails_template_with_data.rb",
220
- "spec/support/templates/cucumber.rb",
221
- "spec/unit/abstract_view_factory_spec.rb",
222
- "spec/unit/action_builder_spec.rb",
223
- "spec/unit/action_items_spec.rb",
224
- "spec/unit/active_admin_spec.rb",
225
- "spec/unit/arbre/html/element_finder_methods_spec.rb",
226
- "spec/unit/arbre/html/element_spec.rb",
227
- "spec/unit/arbre/html/tag_attributes_spec.rb",
228
- "spec/unit/arbre/html/tag_spec.rb",
229
- "spec/unit/arbre/html_spec.rb",
230
- "spec/unit/asset_registration_spec.rb",
231
- "spec/unit/auto_link_spec.rb",
232
- "spec/unit/belongs_to_spec.rb",
233
- "spec/unit/breadcrumbs_spec.rb",
234
- "spec/unit/comments_spec.rb",
235
- "spec/unit/component_spec.rb",
236
- "spec/unit/components/attributes_table_spec.rb",
237
- "spec/unit/components/columns_spec.rb",
238
- "spec/unit/components/panel_spec.rb",
239
- "spec/unit/components/sidebar_section_spec.rb",
240
- "spec/unit/components/table_for_spec.rb",
241
- "spec/unit/controller_filters_spec.rb",
242
- "spec/unit/dashboard_controller_spec.rb",
243
- "spec/unit/dashboard_section_spec.rb",
244
- "spec/unit/dashboards_spec.rb",
245
- "spec/unit/display_name_spec.rb",
246
- "spec/unit/event_spec.rb",
247
- "spec/unit/filter_form_builder_spec.rb",
248
- "spec/unit/form_builder_spec.rb",
249
- "spec/unit/menu_item_spec.rb",
250
- "spec/unit/menu_spec.rb",
251
- "spec/unit/namespace_spec.rb",
252
- "spec/unit/pretty_format_spec.rb",
253
- "spec/unit/registration_spec.rb",
254
- "spec/unit/renderer_spec.rb",
255
- "spec/unit/resource_controller/collection_spec.rb",
256
- "spec/unit/resource_controller_spec.rb",
257
- "spec/unit/resource_spec.rb",
258
- "spec/unit/routing_spec.rb",
259
- "spec/unit/scope_spec.rb",
260
- "spec/unit/tabs_renderer_spec.rb",
261
- "spec/unit/view_factory_spec.rb"
262
- ]
263
- s.homepage = %q{http://github.com/gregbell/active_admin}
15
+ s.files = `git ls-files`.split("\n").sort
16
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
17
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
264
18
  s.require_paths = ["lib"]
265
- s.rubygems_version = %q{1.7.2}
266
- s.summary = %q{The administration framework for Ruby on Rails.}
267
- s.test_files = [
268
- "spec/controllers/index_as_csv_spec.rb",
269
- "spec/integration/belongs_to_spec.rb",
270
- "spec/spec_helper.rb",
271
- "spec/support/integration_example_group.rb",
272
- "spec/support/rails_template.rb",
273
- "spec/support/rails_template_with_data.rb",
274
- "spec/support/templates/cucumber.rb",
275
- "spec/unit/abstract_view_factory_spec.rb",
276
- "spec/unit/action_builder_spec.rb",
277
- "spec/unit/action_items_spec.rb",
278
- "spec/unit/active_admin_spec.rb",
279
- "spec/unit/arbre/html/element_finder_methods_spec.rb",
280
- "spec/unit/arbre/html/element_spec.rb",
281
- "spec/unit/arbre/html/tag_attributes_spec.rb",
282
- "spec/unit/arbre/html/tag_spec.rb",
283
- "spec/unit/arbre/html_spec.rb",
284
- "spec/unit/asset_registration_spec.rb",
285
- "spec/unit/auto_link_spec.rb",
286
- "spec/unit/belongs_to_spec.rb",
287
- "spec/unit/breadcrumbs_spec.rb",
288
- "spec/unit/comments_spec.rb",
289
- "spec/unit/component_spec.rb",
290
- "spec/unit/components/attributes_table_spec.rb",
291
- "spec/unit/components/columns_spec.rb",
292
- "spec/unit/components/panel_spec.rb",
293
- "spec/unit/components/sidebar_section_spec.rb",
294
- "spec/unit/components/table_for_spec.rb",
295
- "spec/unit/controller_filters_spec.rb",
296
- "spec/unit/dashboard_controller_spec.rb",
297
- "spec/unit/dashboard_section_spec.rb",
298
- "spec/unit/dashboards_spec.rb",
299
- "spec/unit/display_name_spec.rb",
300
- "spec/unit/event_spec.rb",
301
- "spec/unit/filter_form_builder_spec.rb",
302
- "spec/unit/form_builder_spec.rb",
303
- "spec/unit/menu_item_spec.rb",
304
- "spec/unit/menu_spec.rb",
305
- "spec/unit/namespace_spec.rb",
306
- "spec/unit/pretty_format_spec.rb",
307
- "spec/unit/registration_spec.rb",
308
- "spec/unit/renderer_spec.rb",
309
- "spec/unit/resource_controller/collection_spec.rb",
310
- "spec/unit/resource_controller_spec.rb",
311
- "spec/unit/resource_spec.rb",
312
- "spec/unit/routing_spec.rb",
313
- "spec/unit/scope_spec.rb",
314
- "spec/unit/tabs_renderer_spec.rb",
315
- "spec/unit/view_factory_spec.rb"
316
- ]
317
19
 
318
- if s.respond_to? :specification_version then
319
- s.specification_version = 3
320
-
321
- if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
322
- s.add_runtime_dependency(%q<rails>, [">= 3.0.0"])
323
- s.add_runtime_dependency(%q<meta_search>, [">= 0.9.2"])
324
- s.add_runtime_dependency(%q<devise>, [">= 1.1.2"])
325
- s.add_runtime_dependency(%q<formtastic>, [">= 1.1.0"])
326
- s.add_runtime_dependency(%q<will_paginate>, [">= 3.0.pre2"])
327
- s.add_runtime_dependency(%q<inherited_views>, [">= 0"])
328
- s.add_runtime_dependency(%q<sass>, [">= 3.1.0"])
329
- s.add_development_dependency(%q<sqlite3-ruby>, [">= 0"])
330
- s.add_development_dependency(%q<jeweler>, ["= 1.5.2"])
331
- s.add_development_dependency(%q<rake>, ["= 0.8.7"])
332
- s.add_development_dependency(%q<haml>, ["~> 3.1.1"])
333
- else
334
- s.add_dependency(%q<rails>, [">= 3.0.0"])
335
- s.add_dependency(%q<meta_search>, [">= 0.9.2"])
336
- s.add_dependency(%q<devise>, [">= 1.1.2"])
337
- s.add_dependency(%q<formtastic>, [">= 1.1.0"])
338
- s.add_dependency(%q<will_paginate>, [">= 3.0.pre2"])
339
- s.add_dependency(%q<inherited_views>, [">= 0"])
340
- s.add_dependency(%q<sass>, [">= 3.1.0"])
341
- s.add_dependency(%q<sqlite3-ruby>, [">= 0"])
342
- s.add_dependency(%q<jeweler>, ["= 1.5.2"])
343
- s.add_dependency(%q<rake>, ["= 0.8.7"])
344
- s.add_dependency(%q<haml>, ["~> 3.1.1"])
345
- end
346
- else
347
- s.add_dependency(%q<rails>, [">= 3.0.0"])
348
- s.add_dependency(%q<meta_search>, [">= 0.9.2"])
349
- s.add_dependency(%q<devise>, [">= 1.1.2"])
350
- s.add_dependency(%q<formtastic>, [">= 1.1.0"])
351
- s.add_dependency(%q<will_paginate>, [">= 3.0.pre2"])
352
- s.add_dependency(%q<inherited_views>, [">= 0"])
353
- s.add_dependency(%q<sass>, [">= 3.1.0"])
354
- s.add_dependency(%q<sqlite3-ruby>, [">= 0"])
355
- s.add_dependency(%q<jeweler>, ["= 1.5.2"])
356
- s.add_dependency(%q<rake>, ["= 0.8.7"])
357
- s.add_dependency(%q<haml>, ["~> 3.1.1"])
358
- end
20
+ s.add_dependency("rails", ">= 3.0.0")
21
+ s.add_dependency("meta_search", ">= 0.9.2")
22
+ s.add_dependency("devise", ">= 1.1.2")
23
+ s.add_dependency("formtastic", ">= 1.1.0")
24
+ s.add_dependency("inherited_resources", ">= 0")
25
+ s.add_dependency("kaminari", ">= 0.12.4")
26
+ s.add_dependency("sass", ">= 3.1.0")
27
+ s.add_dependency("fastercsv", ">= 0")
359
28
  end
360
-