hyrax 5.0.0.rc2 → 5.0.0.rc3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (307) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +14 -0
  3. data/.dassie/app/listeners/hyrax_listener.rb +81 -0
  4. data/.dassie/config/environments/test.rb +0 -5
  5. data/.dassie/config/initializers/hyrax.rb +5 -0
  6. data/.dassie/config/initializers/publisher.rb +3 -0
  7. data/.dassie/config/initializers/riiif.rb +77 -0
  8. data/.gitignore +4 -0
  9. data/.koppie/.env +2 -2
  10. data/.koppie/app/forms/collection_resource_form.rb +1 -0
  11. data/.koppie/app/indexers/collection_resource_indexer.rb +1 -0
  12. data/.koppie/app/listeners/hyrax_listener.rb +81 -0
  13. data/.koppie/app/models/collection.rb +1 -1
  14. data/.koppie/app/models/collection_resource.rb +1 -0
  15. data/.koppie/config/analytics.yml +5 -5
  16. data/.koppie/config/initializers/publisher.rb +3 -0
  17. data/.koppie/config/initializers/riiif.rb +78 -0
  18. data/.koppie/config/metadata/collection_resource.yaml +8 -166
  19. data/.koppie/config/metadata/sample_metadata.yaml +4 -0
  20. data/CONTAINERS.md +39 -2
  21. data/Dockerfile +14 -11
  22. data/Gemfile +8 -7
  23. data/README.md +2 -0
  24. data/app/actors/hyrax/actors/base_actor.rb +6 -3
  25. data/app/actors/hyrax/actors/file_actor.rb +1 -1
  26. data/app/actors/hyrax/actors/lease_actor.rb +3 -6
  27. data/app/assets/javascripts/hyrax/save_work/uploaded_files.es6 +10 -2
  28. data/app/assets/stylesheets/hyrax/sidebar.scss +6 -1
  29. data/app/controllers/concerns/hyrax/collections_controller_behavior.rb +1 -1
  30. data/app/controllers/concerns/hyrax/local_file_downloads_controller_behavior.rb +12 -19
  31. data/app/controllers/concerns/hyrax/stream_file_downloads_controller_behavior.rb +54 -0
  32. data/app/controllers/concerns/hyrax/valkyrie_downloads_controller_behavior.rb +38 -9
  33. data/app/controllers/concerns/hyrax/works_controller_behavior.rb +19 -14
  34. data/app/controllers/hyrax/admin/admin_sets_controller.rb +2 -2
  35. data/app/controllers/hyrax/admin/analytics/work_reports_controller.rb +5 -5
  36. data/app/controllers/hyrax/dashboard/collections_controller.rb +2 -2
  37. data/app/controllers/hyrax/downloads_controller.rb +1 -0
  38. data/app/controllers/hyrax/file_sets_controller.rb +3 -2
  39. data/app/controllers/hyrax/my/collections_controller.rb +1 -1
  40. data/app/forms/concerns/hyrax/basic_metadata_form_fields_behavior.rb +1 -0
  41. data/app/forms/concerns/hyrax/contained_in_works_behavior.rb +24 -0
  42. data/app/forms/concerns/hyrax/deposit_agreement_behavior.rb +12 -0
  43. data/app/forms/concerns/hyrax/leaseability_behavior.rb +49 -0
  44. data/app/forms/concerns/hyrax/permission_behavior.rb +20 -0
  45. data/app/forms/hyrax/forms/administrative_set_form.rb +1 -5
  46. data/app/forms/hyrax/forms/collection_form.rb +19 -0
  47. data/app/forms/hyrax/forms/file_set_form.rb +5 -0
  48. data/app/forms/hyrax/forms/pcdm_collection_form.rb +1 -5
  49. data/app/forms/hyrax/forms/pcdm_object_form.rb +13 -22
  50. data/app/forms/hyrax/forms/resource_batch_edit_form.rb +7 -2
  51. data/app/forms/hyrax/forms/resource_form.rb +30 -100
  52. data/app/forms/hyrax/forms.rb +52 -0
  53. data/app/helpers/hyrax/hyrax_helper_behavior.rb +2 -0
  54. data/app/indexers/{hyrax → concerns/hyrax}/location_indexer.rb +1 -5
  55. data/app/indexers/{hyrax → concerns/hyrax}/permission_indexer.rb +2 -2
  56. data/app/indexers/{hyrax → concerns/hyrax}/visibility_indexer.rb +1 -1
  57. data/app/indexers/hyrax/administrative_set_indexer.rb +5 -17
  58. data/app/indexers/hyrax/indexers/administrative_set_indexer.rb +25 -0
  59. data/app/indexers/hyrax/indexers/file_set_indexer.rb +144 -0
  60. data/app/indexers/hyrax/indexers/pcdm_collection_indexer.rb +27 -0
  61. data/app/indexers/hyrax/indexers/pcdm_object_indexer.rb +72 -0
  62. data/app/indexers/hyrax/indexers/resource_indexer.rb +86 -0
  63. data/app/indexers/hyrax/indexers.rb +54 -0
  64. data/app/indexers/hyrax/pcdm_collection_indexer.rb +5 -18
  65. data/app/indexers/hyrax/valkyrie_collection_indexer.rb +6 -4
  66. data/app/indexers/hyrax/valkyrie_file_set_indexer.rb +5 -136
  67. data/app/indexers/hyrax/valkyrie_indexer.rb +8 -112
  68. data/app/indexers/hyrax/valkyrie_work_indexer.rb +5 -64
  69. data/app/indexers/hyrax/work_indexer.rb +1 -0
  70. data/app/jobs/create_work_job.rb +1 -0
  71. data/app/models/admin_set.rb +20 -1
  72. data/app/models/collection.rb +5 -0
  73. data/app/models/concerns/hyrax/ability/admin_set_ability.rb +13 -28
  74. data/app/models/concerns/hyrax/ability/collection_ability.rb +26 -28
  75. data/app/models/concerns/hyrax/ability/resource_ability.rb +19 -0
  76. data/app/models/concerns/hyrax/ability.rb +11 -9
  77. data/app/models/concerns/hyrax/collection_behavior.rb +8 -0
  78. data/app/models/concerns/hyrax/solr_document_behavior.rb +15 -5
  79. data/app/models/concerns/hyrax/work_behavior.rb +4 -0
  80. data/app/models/featured_work.rb +12 -4
  81. data/app/models/file_set.rb +5 -0
  82. data/app/models/hyrax/administrative_set.rb +1 -1
  83. data/app/models/hyrax/change_set.rb +2 -2
  84. data/app/models/hyrax/file_metadata.rb +34 -7
  85. data/app/models/hyrax/file_set.rb +2 -2
  86. data/app/models/hyrax/group.rb +9 -38
  87. data/app/models/hyrax/group_behavior.rb +58 -0
  88. data/app/models/hyrax/model_registry.rb +111 -0
  89. data/app/models/hyrax/pcdm_collection.rb +1 -7
  90. data/app/models/hyrax/resource.rb +66 -8
  91. data/app/models/hyrax/statistic.rb +1 -1
  92. data/app/models/hyrax/work.rb +1 -7
  93. data/app/presenters/hyrax/collapsable_section_presenter.rb +7 -3
  94. data/app/presenters/hyrax/file_set_presenter.rb +8 -6
  95. data/app/presenters/hyrax/lease_presenter.rb +4 -0
  96. data/app/presenters/hyrax/menu_presenter.rb +14 -2
  97. data/app/presenters/hyrax/pcdm_member_presenter_factory.rb +1 -1
  98. data/app/presenters/hyrax/version_list_presenter.rb +6 -4
  99. data/app/search_builders/hyrax/admin_set_search_builder.rb +1 -1
  100. data/app/search_builders/hyrax/catalog_search_builder.rb +2 -2
  101. data/app/search_builders/hyrax/dashboard/collections_search_builder.rb +5 -3
  102. data/app/search_builders/hyrax/exposed_models_relation.rb +1 -1
  103. data/app/search_builders/hyrax/file_set_search_builder.rb +1 -1
  104. data/app/search_builders/hyrax/filter_by_type.rb +3 -2
  105. data/app/search_builders/hyrax/member_with_files_search_builder.rb +1 -1
  106. data/app/search_builders/hyrax/my/collections_search_builder.rb +2 -2
  107. data/app/search_builders/hyrax/my/find_works_search_builder.rb +8 -3
  108. data/app/services/hyrax/access_control_list.rb +21 -4
  109. data/app/services/hyrax/action/create_valkyrie_work.rb +80 -0
  110. data/app/services/hyrax/admin_set_create_service.rb +7 -3
  111. data/app/services/hyrax/admin_set_service.rb +2 -2
  112. data/app/services/hyrax/collections/collection_member_search_service.rb +2 -0
  113. data/app/services/hyrax/collections/permissions_service.rb +27 -9
  114. data/app/services/hyrax/custom_queries/find_collections_by_type.rb +1 -1
  115. data/app/services/hyrax/custom_queries/find_file_metadata.rb +1 -1
  116. data/app/services/hyrax/custom_queries/navigators/find_files.rb +1 -1
  117. data/app/services/hyrax/custom_queries/navigators/parent_work_navigator.rb +1 -1
  118. data/app/services/hyrax/edit_permissions_service.rb +1 -1
  119. data/app/services/hyrax/embargo_manager.rb +1 -1
  120. data/app/services/hyrax/file_set_file_service.rb +21 -10
  121. data/app/services/hyrax/form_factory.rb +1 -1
  122. data/app/services/hyrax/lease_manager.rb +39 -16
  123. data/app/services/hyrax/lease_service.rb +12 -6
  124. data/app/services/hyrax/listeners/acl_index_listener.rb +1 -1
  125. data/app/services/hyrax/listeners/active_fedora_acl_index_listener.rb +1 -1
  126. data/app/services/hyrax/listeners/member_cleanup_listener.rb +15 -1
  127. data/app/services/hyrax/listeners/object_lifecycle_listener.rb +5 -1
  128. data/app/services/hyrax/listeners/trophy_cleanup_listener.rb +2 -1
  129. data/app/services/hyrax/listeners/workflow_listener.rb +13 -0
  130. data/app/services/hyrax/listeners.rb +2 -1
  131. data/app/services/hyrax/location_service.rb +3 -0
  132. data/app/services/hyrax/multiple_membership_checker.rb +1 -1
  133. data/app/services/hyrax/simple_schema_loader.rb +1 -1
  134. data/app/services/hyrax/solr_service.rb +19 -5
  135. data/app/services/hyrax/statistics/collections/over_time.rb +1 -1
  136. data/app/services/hyrax/statistics/query_service.rb +6 -0
  137. data/app/services/hyrax/valkyrie_persist_derivatives.rb +11 -4
  138. data/app/services/hyrax/valkyrie_upload.rb +1 -1
  139. data/app/services/hyrax/work_uploads_handler.rb +5 -4
  140. data/app/views/_user_util_links.html.erb +1 -1
  141. data/app/views/collections/edit_fields/_based_near.html.erb +11 -7
  142. data/app/views/hyrax/admin/admin_sets/_form_participants.html.erb +67 -67
  143. data/app/views/hyrax/admin/admin_sets/edit.html.erb +1 -1
  144. data/app/views/hyrax/admin/collection_types/_form_participants.html.erb +3 -1
  145. data/app/views/hyrax/base/_attribute_rows.html.erb +1 -0
  146. data/app/views/hyrax/base/_base_form_files_prepend.html.erb +4 -0
  147. data/app/views/hyrax/base/_form_files.html.erb +65 -64
  148. data/app/views/hyrax/base/show.html.erb +2 -3
  149. data/app/views/hyrax/collections/show.html.erb +7 -9
  150. data/app/views/hyrax/dashboard/_sidebar.html.erb +4 -3
  151. data/app/views/hyrax/dashboard/collections/_form_share_table.html.erb +2 -2
  152. data/app/views/hyrax/file_sets/media_display/_audio.html.erb +1 -1
  153. data/app/views/hyrax/file_sets/media_display/_video.html.erb +1 -1
  154. data/app/views/hyrax/my/facet.html.erb +1 -1
  155. data/app/views/layouts/_head_tag_content.html.erb +1 -0
  156. data/app/views/shared/_footer.html.erb +1 -1
  157. data/chart/hyrax/Chart.yaml +3 -3
  158. data/chart/hyrax/values.yaml +9 -1
  159. data/config/initializers/listeners.rb +1 -1
  160. data/config/locales/hyrax.de.yml +5 -0
  161. data/config/locales/hyrax.en.yml +10 -0
  162. data/config/locales/hyrax.es.yml +5 -0
  163. data/config/locales/hyrax.fr.yml +5 -0
  164. data/config/locales/hyrax.it.yml +5 -0
  165. data/config/locales/hyrax.pt-BR.yml +5 -0
  166. data/config/locales/hyrax.zh.yml +5 -0
  167. data/config/metadata/basic_metadata.yaml +1 -0
  168. data/config/metadata/core_metadata.yaml +2 -0
  169. data/config/metadata/file_set_metadata.yaml +2 -0
  170. data/docker-compose-koppie.yml +3 -3
  171. data/docker-compose-sirenia.yml +3 -3
  172. data/documentation/developing-your-hyrax-based-app.md +77 -60
  173. data/hyrax.gemspec +9 -2
  174. data/lib/generators/hyrax/collection_resource/templates/collection_indexer.rb.erb +1 -1
  175. data/lib/generators/hyrax/config_generator.rb +12 -0
  176. data/lib/generators/hyrax/install_generator.rb +37 -7
  177. data/lib/generators/hyrax/listeners_generator.rb +18 -0
  178. data/lib/generators/hyrax/models_generator.rb +1 -10
  179. data/lib/generators/hyrax/riiif_generator.rb +6 -4
  180. data/lib/generators/hyrax/templates/.env +9 -0
  181. data/lib/generators/hyrax/templates/.lando.yml +50 -0
  182. data/lib/generators/hyrax/templates/app/listeners/hyrax_listener.rb +81 -0
  183. data/lib/generators/hyrax/templates/app/models/file_set.rb +1 -2
  184. data/lib/generators/hyrax/templates/config/initializers/1_valkyrie.rb +102 -0
  185. data/lib/generators/hyrax/templates/config/initializers/file_services.rb +6 -0
  186. data/lib/generators/hyrax/templates/config/initializers/hyrax.rb +41 -5
  187. data/lib/generators/hyrax/templates/config/initializers/publisher.rb +3 -0
  188. data/lib/generators/hyrax/templates/config/initializers/riiif.rb +77 -0
  189. data/lib/generators/hyrax/templates/config/locales/hyrax.de.yml +1 -1
  190. data/lib/generators/hyrax/templates/config/locales/hyrax.en.yml +1 -1
  191. data/lib/generators/hyrax/templates/config/locales/hyrax.es.yml +1 -1
  192. data/lib/generators/hyrax/templates/config/locales/hyrax.fr.yml +1 -1
  193. data/lib/generators/hyrax/templates/config/locales/hyrax.it.yml +1 -1
  194. data/lib/generators/hyrax/templates/config/locales/hyrax.pt-BR.yml +1 -1
  195. data/lib/generators/hyrax/templates/config/locales/hyrax.zh.yml +1 -1
  196. data/lib/generators/hyrax/templates/config/redis.yml +3 -6
  197. data/lib/generators/hyrax/templates/config/valkyrie_index.yml +4 -9
  198. data/lib/generators/hyrax/work_resource/templates/indexer.rb.erb +1 -1
  199. data/lib/hyrax/configuration.rb +95 -7
  200. data/lib/hyrax/indexer.rb +1 -1
  201. data/lib/hyrax/publisher.rb +5 -2
  202. data/lib/hyrax/resource_sync/change_list_writer.rb +1 -1
  203. data/lib/hyrax/resource_sync/resource_list_writer.rb +1 -1
  204. data/lib/hyrax/specs/capybara.rb +1 -0
  205. data/lib/hyrax/specs/shared_specs/hydra_works.rb +78 -20
  206. data/lib/hyrax/specs/shared_specs/indexers.rb +1 -1
  207. data/lib/hyrax/transactions/admin_set_destroy.rb +2 -1
  208. data/lib/hyrax/transactions/container.rb +5 -0
  209. data/lib/hyrax/transactions/steps/add_to_parent.rb +1 -0
  210. data/lib/hyrax/transactions/steps/check_for_default_admin_set.rb +32 -0
  211. data/lib/hyrax/transactions/steps/check_for_empty_admin_set.rb +1 -1
  212. data/lib/hyrax/transactions/steps/save.rb +2 -1
  213. data/lib/hyrax/transactions/steps/set_user_as_creator.rb +1 -1
  214. data/lib/hyrax/transactions/steps/update_work_members.rb +2 -0
  215. data/lib/hyrax/version.rb +1 -1
  216. data/lib/hyrax.rb +1 -0
  217. data/lib/tasks/embargo_lease.rake +1 -0
  218. data/lib/valkyrie/indexing/solr/indexing_adapter.rb +21 -7
  219. data/lib/wings/active_fedora_converter/default_work.rb +4 -5
  220. data/lib/wings/active_fedora_converter/file_metadata_node.rb +1 -1
  221. data/lib/wings/model_registry.rb +8 -0
  222. data/lib/wings/model_transformer.rb +19 -2
  223. data/lib/wings/orm_converter.rb +4 -0
  224. data/lib/wings/services/custom_queries/find_ids_by_model.rb +2 -2
  225. data/lib/wings/valkyrie/query_service.rb +5 -2
  226. data/lib/wings.rb +3 -0
  227. data/spec/factories/access_control.rb +12 -0
  228. data/spec/factories/admin_sets.rb +32 -0
  229. data/spec/factories/admin_sets_lw.rb +222 -0
  230. data/spec/factories/administrative_sets.rb +79 -0
  231. data/spec/factories/api_items.rb +92 -0
  232. data/spec/factories/collection_branding_infos.rb +12 -0
  233. data/spec/factories/collection_type_participants.rb +9 -0
  234. data/spec/factories/collection_types.rb +139 -0
  235. data/spec/factories/collections.rb +282 -0
  236. data/spec/factories/collections_factory.rb +107 -0
  237. data/spec/factories/content_blocks.rb +5 -0
  238. data/spec/factories/counter_metrics.rb +12 -0
  239. data/spec/factories/featured_works.rb +5 -0
  240. data/spec/factories/file_sets.rb +45 -0
  241. data/spec/factories/generic_works.rb +200 -0
  242. data/spec/factories/hyrax_collection.rb +92 -0
  243. data/spec/factories/hyrax_default_admin_set.rb +7 -0
  244. data/spec/factories/hyrax_embargo.rb +18 -0
  245. data/spec/factories/hyrax_file_metadata.rb +92 -0
  246. data/spec/factories/hyrax_file_set.rb +129 -0
  247. data/spec/factories/hyrax_lease.rb +18 -0
  248. data/spec/factories/hyrax_resource.rb +15 -0
  249. data/spec/factories/hyrax_work.rb +221 -0
  250. data/spec/factories/object_id.rb +7 -0
  251. data/spec/factories/operations.rb +22 -0
  252. data/spec/factories/permission.rb +7 -0
  253. data/spec/factories/permission_template_accesses.rb +17 -0
  254. data/spec/factories/permission_templates.rb +111 -0
  255. data/spec/factories/proxy_deposit_requests.rb +7 -0
  256. data/spec/factories/single_use_links.rb +14 -0
  257. data/spec/factories/sipity_entities.rb +17 -0
  258. data/spec/factories/uploaded_files.rb +11 -0
  259. data/spec/factories/users.rb +52 -0
  260. data/spec/factories/workflow_actions.rb +7 -0
  261. data/spec/factories/workflow_states.rb +7 -0
  262. data/spec/factories/workflows.rb +7 -0
  263. data/spec/support/book_resource.rb +36 -0
  264. data/spec/support/can_can_overrides.rb +43 -0
  265. data/spec/support/clean_solr.rb +7 -0
  266. data/spec/support/controller_level_helpers.rb +27 -0
  267. data/spec/support/factory_helpers.rb +94 -0
  268. data/spec/support/fakes/fake_actor.rb +22 -0
  269. data/spec/support/fakes/fake_authority.rb +14 -0
  270. data/spec/support/fakes/fake_search_builder_scope.rb +44 -0
  271. data/spec/support/fakes/indexing_adapter.rb +17 -0
  272. data/spec/support/fakes/test_hydra_group_service.rb +55 -0
  273. data/spec/support/features/batch_edit_actions.rb +37 -0
  274. data/spec/support/features/session_helpers.rb +15 -0
  275. data/spec/support/features/workflow.rb +10 -0
  276. data/spec/support/features.rb +11 -0
  277. data/spec/support/form_with_validations.rb +15 -0
  278. data/spec/support/input_support.rb +12 -0
  279. data/spec/support/logging_formatter.rb +67 -0
  280. data/spec/support/matchers/api_responses.rb +27 -0
  281. data/spec/support/matchers/collection_type_property_matchers.rb +30 -0
  282. data/spec/support/matchers/embargo.rb +9 -0
  283. data/spec/support/matchers/lease.rb +9 -0
  284. data/spec/support/matchers/match_valkyrie_ids_with_af_ids.rb +12 -0
  285. data/spec/support/matchers/pcdm_matchers.rb +34 -0
  286. data/spec/support/matchers/permission.rb +31 -0
  287. data/spec/support/matchers/response_matchers.rb +8 -0
  288. data/spec/support/optional_example.rb +17 -0
  289. data/spec/support/rake.rb +42 -0
  290. data/spec/support/selectors.rb +112 -0
  291. data/spec/support/shared_examples_for_collection_presenter.rb +44 -0
  292. data/spec/support/simple_work.rb +28 -0
  293. data/spec/support/spec_statistic.rb +24 -0
  294. data/spec/support/speedup.rb +7 -0
  295. data/spec/support/statistic_helper.rb +10 -0
  296. data/spec/support/valkyrie_indexing.rb +2 -0
  297. data/spec/support/wings_models.rb +9 -0
  298. data/template.rb +1 -3
  299. metadata +112 -30
  300. data/app/indexers/hyrax/resource_indexer.rb +0 -15
  301. data/app/models/concerns/hyrax/riiif_file.rb +0 -30
  302. data/app/services/hyrax/characterization/model_wrapper.rb +0 -0
  303. data/app/services/hyrax/custom_queries/find_by_collection_type.rb +0 -0
  304. data/app/services/hyrax/query_service.rb +0 -0
  305. data/app/services/hyrax/riiif_file_resolver.rb +0 -50
  306. data/lib/hyrax/specs/disable_animations_in_test_environment.rb +0 -53
  307. /data/app/indexers/{hyrax → concerns/hyrax}/thumbnail_indexer.rb +0 -0
@@ -4,9 +4,9 @@
4
4
  <div class="col-md-12">
5
5
 
6
6
  <% if @presenter.banner_file.present? %>
7
- <div class="hyc-banner" style="background-image:url(<%= @presenter.banner_file %>)">
7
+ <div class="hyc-banner" style="background-image:url(<%= @presenter.banner_file %>)">
8
8
  <% else %>
9
- <div class="hyc-generic">
9
+ <div class="hyc-generic">
10
10
  <% end %>
11
11
 
12
12
  <div class="hyc-title">
@@ -80,11 +80,11 @@
80
80
  <!-- Search results label -->
81
81
  <% if @members_count > 0 || @presenter.subcollection_count > 0 %>
82
82
  <div class="hyc-blacklight hyc-bl-title">
83
- <% if collection_search_parameters? %>
84
- <h2>
85
- <%= t('hyrax.dashboard.collections.show.search_results') %>
86
- </h2>
87
- <% end %>
83
+ <% if collection_search_parameters? %>
84
+ <h2>
85
+ <%= t('hyrax.dashboard.collections.show.search_results') %>
86
+ </h2>
87
+ <% end %>
88
88
  </div>
89
89
  <% end %>
90
90
 
@@ -125,6 +125,4 @@
125
125
  <% end # if @members_count > 0 %>
126
126
  </div>
127
127
 
128
-
129
128
  <span class='hide analytics-event' data-category="collection" data-action="collection-page-view" data-name="<%= @presenter.id %>" >
130
-
@@ -12,9 +12,10 @@
12
12
  </div>
13
13
  </div>
14
14
  </li>
15
- <li class="nav-item"><%= link_to hyrax.dashboard_path, class: "nav-link" do %>
16
- <span class="fa fa-home" aria-hidden="true"></span> <span class="sidebar-action-text"><%= t('hyrax.admin.sidebar.dashboard') %></span>
17
- <% end %>
15
+ <li class="nav-item">
16
+ <%= link_to hyrax.dashboard_path, class: "nav-link", title: t('hyrax.admin.sidebar.dashboard') do %>
17
+ <span class="fa fa-home" aria-hidden="true"></span> <span class="sidebar-action-text"><%= t('hyrax.admin.sidebar.dashboard') %></span>
18
+ <% end %>
18
19
  </li>
19
20
  <%= render 'hyrax/dashboard/sidebar/activity', menu: menu %>
20
21
  <%= render 'hyrax/dashboard/sidebar/repository_content', menu: menu %>
@@ -2,7 +2,7 @@
2
2
 
3
3
  <h3 class="h4"><%= t(".#{access}.title") %></h3>
4
4
  <p><%= t(".#{access}.help") %></p>
5
- <p><%= t(".#{access}.help_with_works", type_title: @collection_type.title) if @collection_type.share_applies_to_new_works? && access != 'depositors' %></p>
5
+ <p><%= t(".#{access}.help_with_works", type_title: collection_type.title) if collection_type.share_applies_to_new_works? && access != 'depositors' %></p>
6
6
  <% if collection_permission_template_form_for(form: @form).access_grants.select(&filter).any? %>
7
7
  <table class="table table-striped share-status">
8
8
  <thead>
@@ -31,4 +31,4 @@
31
31
  <% else %>
32
32
  <p><em><%= t(".#{access}.empty") %></em></p>
33
33
  <% end %>
34
- </div>
34
+ </div>
@@ -8,7 +8,7 @@
8
8
  </audio>
9
9
  <%= link_to t('hyrax.file_set.show.downloadable_content.audio_link'),
10
10
  hyrax.download_path(file_set),
11
- data: { label: file_set.id, work_id: @presenter.id, collection_ids: @presenter.member_of_collection_ids },
11
+ data: { label: file_set.id.to_s, work_id: @presenter.id, collection_ids: @presenter.member_of_collection_ids },
12
12
  target: :_blank,
13
13
  id: "file_download" %>
14
14
  </div>
@@ -8,7 +8,7 @@
8
8
  </video>
9
9
  <%= link_to t('hyrax.file_set.show.downloadable_content.video_link'),
10
10
  hyrax.download_path(file_set),
11
- data: { label: file_set.id, work_id: @presenter.id, collection_ids: @presenter.member_of_collection_ids },
11
+ data: { label: file_set.id.to_s, work_id: @presenter.id, collection_ids: @presenter.member_of_collection_ids },
12
12
  target: :_blank,
13
13
  id: "file_download" %>
14
14
  </div>
@@ -9,7 +9,7 @@
9
9
  <%= render partial: 'facet_index_navigation' if @facet.index_range && @display_facet.index? %>
10
10
 
11
11
  <div class="facet-extended-list">
12
- <%= render_facet_limit(@display_facet, layout: false) %>
12
+ <%= render_facet_limit(@display_facet, layout: false, partial: 'catalog/facet_limit') %>
13
13
  </div>
14
14
 
15
15
  <%# Removed component footer and placed the facet pagination partial within a `container` div %>
@@ -9,6 +9,7 @@ signed in %>
9
9
  <!-- added for use on small devices like phones -->
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
11
11
  <link rel="resourcesync" href="<%= hyrax.capability_list_url %>" />
12
+ <meta name="generator" content="Samvera Hyrax <%= ::Hyrax::VERSION %>" />
12
13
 
13
14
  <!-- Twitter card metadata -->
14
15
  <%= yield :twitter_meta %>
@@ -6,7 +6,7 @@
6
6
  </div>
7
7
  <div class="navbar-right">
8
8
  <div class="navbar-text text-right">
9
- <p><%= t('hyrax.footer.copyright_html') %></p>
9
+ <p><%= t('hyrax.footer.copyright_html', current_year: Time.current.year) %></p>
10
10
  <p><%= t('hyrax.background_attribution_html') %></p>
11
11
  </div>
12
12
  </div>
@@ -2,11 +2,11 @@ apiVersion: v2
2
2
  name: hyrax
3
3
  description: An open-source, Samvera-powered digital repository system
4
4
  type: application
5
- version: 3.5.0
6
- appVersion: 3.3.0
5
+ version: 3.6.0
6
+ appVersion: 5.0.0
7
7
  dependencies:
8
8
  - name: fcrepo
9
- version: 1.0.0
9
+ version: 2.0.0
10
10
  repository: oci://ghcr.io/samvera
11
11
  condition: fcrepo.enabled
12
12
  - name: memcached
@@ -226,7 +226,7 @@ fcrepo:
226
226
  enabled: false
227
227
  image:
228
228
  repository: bitnami/postgresql
229
- tag: 12.11.0-debian-11-r12
229
+ tag: 12.17.0-debian-11-r28
230
230
 
231
231
  # configuration for an external/existing fits service;
232
232
  # ignored if `fits.enabled` is true
@@ -284,6 +284,14 @@ nginx:
284
284
  image:
285
285
  repository: bitnami/nginx
286
286
  tag: 1.23.0-debian-11-r1
287
+ # this needs to be set since templates/ingress.yaml tries to
288
+ # evaluate .Values.nginx.service.port, and it needs to at least evaluate to
289
+ # nil, rather than throw an error (which it does if `service` itself is nil).
290
+ # you can change to NodePort or LoadBalancer if direct access is needed.
291
+ # ClusterIP is used as we assume an ingress is in place.
292
+ service:
293
+ type: ClusterIP
294
+ port: 80
287
295
  # The set up below does malicious bot / ip blocking and mounts
288
296
  # volumes to allow nginx to server assets and other public directory items
289
297
  # extraVolumes:
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- Hyrax.publisher.subscribe(Hyrax::Listeners::ActiveFedoraAclIndexListener.new) unless Hyrax.config.disable_wings
3
+ Hyrax.publisher.subscribe(Hyrax::Listeners::ActiveFedoraACLIndexListener.new) unless Hyrax.config.disable_wings
4
4
 
5
5
  Hyrax.publisher.default_listeners.each do |listener|
6
6
  Hyrax.publisher.subscribe(listener)
@@ -905,6 +905,11 @@ de:
905
905
  collection_title: Sammlungstitel
906
906
  this_collection_in_other_collections_description: Sie können diese Sammlung anderen Sammlungen als Untersammlung hinzufügen.
907
907
  form_share:
908
+ access_options:
909
+ creator: Schöpfer
910
+ depositor: Einleger
911
+ manager: Manager
912
+ viewer: Zuschauer
908
913
  add_group: Gruppe hinzufügen
909
914
  add_sharing: Freigaben hinzufügen
910
915
  add_user: Benutzer hinzufügen
@@ -584,6 +584,11 @@ en:
584
584
  help_html: Select the file with media that represents this work.
585
585
  legend_html: Representative Media
586
586
  form_share:
587
+ access_options:
588
+ creator: Creator
589
+ depositor: Depositor
590
+ manager: Manager
591
+ viewer: Viewer
587
592
  access_type_to_grant: Access type to grant
588
593
  account_label_without_suffix: "%{account_label} (without the %{suffix} part)"
589
594
  add_sharing: Add Sharing
@@ -903,6 +908,11 @@ en:
903
908
  collection_title: Collection Title
904
909
  this_collection_in_other_collections_description: You can add this collection to other collections as a sub-collection.
905
910
  form_share:
911
+ access_options:
912
+ creator: Creator
913
+ depositor: Depositor
914
+ manager: Manager
915
+ viewer: Viewer
906
916
  add_group: Add group
907
917
  add_sharing: Add Sharing
908
918
  add_user: Add user
@@ -905,6 +905,11 @@ es:
905
905
  collection_title: Título de la colección
906
906
  this_collection_in_other_collections_description: Puede agregar esta colección a otras colecciones como una subcolección.
907
907
  form_share:
908
+ access_options:
909
+ creator: Creador
910
+ depositor: Depositor
911
+ manager: Gerente
912
+ viewer: Espectador
908
913
  add_group: Añadir grupo
909
914
  add_sharing: Agregar Compartir
910
915
  add_user: Agregar usuario
@@ -906,6 +906,11 @@ fr:
906
906
  collection_title: Titre de la collection
907
907
  this_collection_in_other_collections_description: Vous pouvez ajouter cette collection à d'autres collections en tant que sous-collection.
908
908
  form_share:
909
+ access_options:
910
+ creator: Créateur
911
+ depositor: Déposant
912
+ manager: Gestionnaire
913
+ viewer: Téléspectateur
909
914
  add_group: Ajouter un groupe
910
915
  add_sharing: Ajouter un partage
911
916
  add_user: Ajouter un utilisateur
@@ -905,6 +905,11 @@ it:
905
905
  collection_title: Titolo della collezione
906
906
  this_collection_in_other_collections_description: È possibile aggiungere questa raccolta ad altre raccolte come sotto-raccolta.
907
907
  form_share:
908
+ access_options:
909
+ creator: Creatore
910
+ depositor: Depositante
911
+ manager: Gestore
912
+ viewer: Spettatore
908
913
  add_group: Aggiungere gruppo
909
914
  add_sharing: Aggiungi condivisione
910
915
  add_user: Aggiungi utente
@@ -904,6 +904,11 @@ pt-BR:
904
904
  collection_title: Título da Coleção
905
905
  this_collection_in_other_collections_description: Você pode embutir esta coleção em outras coleções como uma sub-coleção.
906
906
  form_share:
907
+ access_options:
908
+ creator: O Criador
909
+ depositor: Depositante
910
+ manager: Gerente
911
+ viewer: Visualizador
907
912
  add_group: Acrescentar Grupo
908
913
  add_sharing: Acrescentar Compartilhamento
909
914
  add_user: Acrescentar Usuário
@@ -903,6 +903,11 @@ zh:
903
903
  collection_title: 收藏标题
904
904
  this_collection_in_other_collections_description: 您可以将此集合作为子集合添加到其他集合。
905
905
  form_share:
906
+ access_options:
907
+ creator: 造物主
908
+ depositor: 储户
909
+ manager: 经理
910
+ viewer: 查看器
906
911
  add_group: 添加组
907
912
  add_sharing: 添加共享
908
913
  add_user: 添加用户
@@ -50,6 +50,7 @@ attributes:
50
50
  primary: false
51
51
  index_keys:
52
52
  - "contributor_tesim"
53
+ - "contributor_sim"
53
54
  predicate: http://purl.org/dc/elements/1.1/contributor
54
55
  creator:
55
56
  type: string
@@ -19,3 +19,5 @@ attributes:
19
19
  depositor:
20
20
  type: string
21
21
  predicate: http://id.loc.gov/vocabulary/relators/dpt
22
+ index_keys:
23
+ - "depositor_tesim"
@@ -20,6 +20,8 @@ attributes:
20
20
  required: false
21
21
  primary: true
22
22
  predicate: http://purl.org/dc/terms/license
23
+ index_keys:
24
+ - "license_tesim"
23
25
 
24
26
  # Other attributes:
25
27
  abstract:
@@ -99,8 +99,8 @@ services:
99
99
  - /dev/shm:/dev/shm
100
100
  shm_size: 2G
101
101
  ports:
102
- - "4445:4444"
103
- - "5960:5900"
102
+ - "4446:4444"
103
+ - "5961:5900"
104
104
  networks:
105
105
  - koppie
106
106
 
@@ -145,7 +145,7 @@ services:
145
145
  command:
146
146
  - sh
147
147
  - "-c"
148
- - "precreate-core koppie_test /opt/solr/server/configsets/hyraxconf; solr-precreate koppie /opt/solr/server/configsets/hyraxconf"
148
+ - "precreate-core hydra-test /opt/solr/server/configsets/hyraxconf; solr-precreate koppie /opt/solr/server/configsets/hyraxconf"
149
149
  volumes:
150
150
  - solr_home:/var/solr/data:cached
151
151
  - .koppie/solr/conf:/opt/solr/server/configsets/hyraxconf
@@ -129,8 +129,8 @@ services:
129
129
  image: fcrepo/fcrepo:6.4.0
130
130
  environment:
131
131
  - >-
132
- CATALINA_OPTS=-Dfcrepo.home=/fcrepo-home -Djava.awt.headless=true -Dfile.encoding=UTF-8
133
- -server -Xms512m -Xmx1024m -XX:NewSize=256m -XX:MaxNewSize=256m -XX:PermSize=256m
132
+ CATALINA_OPTS=-Dfcrepo.home=/fcrepo-home -Djava.awt.headless=true -Dfile.encoding=UTF-8
133
+ -server -Xms512m -Xmx1024m -XX:NewSize=256m -XX:MaxNewSize=256m -XX:PermSize=256m
134
134
  -XX:MaxPermSize=256m -XX:+DisableExplicitGC -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true
135
135
  - JAVA_OPTS=-Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true
136
136
  volumes:
@@ -170,7 +170,7 @@ services:
170
170
  command:
171
171
  - sh
172
172
  - "-c"
173
- - "precreate-core koppie_test /opt/solr/server/configsets/hyraxconf; solr-precreate koppie /opt/solr/server/configsets/hyraxconf"
173
+ - "precreate-core hydra-test /opt/solr/server/configsets/hyraxconf; solr-precreate koppie /opt/solr/server/configsets/hyraxconf"
174
174
  volumes:
175
175
  - solr_home:/var/solr/data:cached
176
176
  - .koppie/solr/conf:/opt/solr/server/configsets/hyraxconf
@@ -29,8 +29,10 @@ A Hyrax-based application includes lots of dependencies. We provide a [Docker im
29
29
 
30
30
  You can also try [Running Hyrax-based application in local VM](https://github.com/samvera/hyrax/wiki/Hyrax-Development-Guide#running-hyrax-based-application-in-local-vm) which uses Ubuntu.
31
31
 
32
+ During development, running only the dependent services in a container environment may be beneficial. This avoids potential headaches concerning file permissions and eases the use of debugging tools. The application generation instructions below use [Lando](https://lando.dev) to achieve this setup.
33
+
32
34
  This document contains instructions specific to setting up an app with __Hyrax
33
- v5.0.0.rc2__. If you are looking for instructions on installing a different
35
+ v5.0.0.rc3__. If you are looking for instructions on installing a different
34
36
  version, be sure to select the appropriate branch or tag from the drop-down
35
37
  menu above.
36
38
 
@@ -44,8 +46,8 @@ Prerequisites are required for both creating a Hyrax\-based app and contributing
44
46
  Hyrax requires the following software to work:
45
47
 
46
48
  1. [Solr](http://lucene.apache.org/solr/) version >= 5.x (tested up to 8.11.1, which includes the log4j library update)
47
- 1. [Fedora Commons](http://www.fedora-commons.org/) digital repository version >= 4.5.1 (tested up to 4.7.5)
48
- 1. A SQL RDBMS (MySQL, PostgreSQL), though **note** that SQLite will be used by default if you're looking to get up and running quickly
49
+ 1. [Fedora Commons](http://www.fedora-commons.org/) digital repository version >= 4.7.6 (if not using the Valkyrie Postgres adapter)
50
+ 1. A SQL RDBMS ([PostgreSQL](https://www.postgresql.org) recommended)
49
51
  1. [Redis](http://redis.io/), a key-value store
50
52
  1. [ImageMagick](http://www.imagemagick.org/) with JPEG-2000 support
51
53
  1. [FITS](#characterization) (tested up to version 1.5.0 -- avoid version 1.1.0)
@@ -55,7 +57,12 @@ Hyrax requires the following software to work:
55
57
  **NOTE: The [Hyrax Development Guide](https://github.com/samvera/hyrax/wiki/Hyrax-Development-Guide) has instructions for installing Solr and Fedora in a development environment.**
56
58
 
57
59
  ### Characterization
60
+ #### Servlet FITS
61
+ FITS can be run as a web service. This has the benefit of improved performance by avoiding the slow startup time inherent to the local option below.
62
+
63
+ A container image is available for this purpose: [ghcr.io/samvera/fitsservlet](https://ghcr.io/samvera/fitsservlet)
58
64
 
65
+ #### Local FITS
59
66
  FITS can be installed on OSX using Homebrew by running the command: `brew install fits`
60
67
 
61
68
  **OR**
@@ -122,10 +129,21 @@ NOTE: [nodejs](https://nodejs.org/en/) is preinstalled on most Mac computers and
122
129
 
123
130
  NOTE: The steps need to be done in order to create a new Hyrax based app.
124
131
 
132
+ ### Development Prerequisites
133
+
134
+ These instructions assume the use of [Lando](https://lando.dev) and [Docker](https://docker.io) to manage the backend services needed by your Hyrax application. Follow the Lando installation instructions before proceeding, or have alternate providers for the services listed in the generated `.lando.yml`:
135
+ - Solr
136
+ - Postgres
137
+ - Redis
138
+ - FITS servlet
139
+ - Fedora (if not using Postgres)
140
+
141
+ ### Generate the application
142
+
125
143
  Generate a new Rails application using the template.
126
144
 
127
- ```
128
- rails _6.1.7.6_ new my_app -m https://raw.githubusercontent.com/samvera/hyrax/hyrax-v5.0.0.rc2/template.rb
145
+ ```shell
146
+ rails _6.1.7.6_ new my_app --database=postgresql -m https://raw.githubusercontent.com/samvera/hyrax/hyrax-v5.0.0.rc3/template.rb
129
147
  ```
130
148
 
131
149
  Generating a new Rails application using Hyrax's template above takes cares of a number of steps for you, including:
@@ -133,23 +151,65 @@ Generating a new Rails application using Hyrax's template above takes cares of a
133
151
  * Adding Hyrax (and any of its dependencies) to your application `Gemfile`, to declare that Hyrax is a dependency of your application
134
152
  * Running `bundle install`, to install Hyrax and its dependencies
135
153
  * Running Hyrax's install generator, to add a number of files that Hyrax requires within your Rails app, including e.g. database migrations
154
+
155
+ ### Start Services
156
+
157
+ Start the background services managed by Lando. The
158
+
159
+ ```shell
160
+ cd my_app
161
+ lando start
162
+ ```
163
+
164
+ ### Run Migrations/Seeds
165
+
166
+ This performs the following actions:
167
+
136
168
  * Loading all of Hyrax's database migrations into your application's database
137
- * Loading Hyrax's default workflows into your application's database
138
169
  * Create default collection types (e.g. Admin Set, User Collection)
170
+ * Loading Hyrax's default workflows into your application's database
171
+
172
+ ```shell
173
+ rails db:migrate
174
+ rails db:seed
175
+ ```
139
176
 
140
- ### Start servers
177
+ **NOTE**: You will want to run these commands the first time this code is deployed to a new environment as well.
141
178
 
142
- To test-drive your new Hyrax application in development mode, spin up the servers that Hyrax needs (Solr, Fedora, and Rails):
179
+ This creates the default administrative set -- into which all works will be deposited unless assigned to other administrative sets.
180
+ This command also makes sure that Hyrax's built-in workflows are loaded for your application and available for the default administrative set.
181
+
182
+ ### Generate a work type
183
+
184
+ Using Hyrax requires generating at least one type of repository object, or "work type." Hyrax allows you to generate the work types required in your application by using a Rails generator-based tool. You may generate one or more of these work types.
185
+
186
+ Pass a (CamelCased) model name to Hyrax's work generator to get started, e.g.:
143
187
 
144
188
  ```
145
- bin/rails hydra:server
189
+ rails generate hyrax:work_resource MovingImage
190
+ ```
191
+
192
+ If your applications requires your work type to be namespaced, namespaces can be included by adding a slash to the model name which creates a new class called `MovingImage` within the `My` namespace:
193
+
194
+ ```shell
195
+ rails generate hyrax:work_resource My/MovingImage
196
+ ```
197
+
198
+ You may wish to [customize your work type](https://github.com/samvera/hyrax/wiki/Customizing-your-work-types) now that it's been generated.
199
+
200
+ ### Start Hyrax web server
201
+
202
+ Test-drive your new Hyrax application in development mode:
203
+
204
+ ```shell
205
+ rails s
146
206
  ```
147
207
 
148
208
  And now you should be able to browse to [localhost:3000](http://localhost:3000/) and see the application.
149
209
 
150
210
  Notes:
151
211
  * This web server is purely for development purposes. You will want to use a more fully featured [web server](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide#web-server) for production-like environments.
152
- * You have the option to start each of these services individually. More information on [solr_wrapper](https://github.com/cbeer/solr_wrapper) and [fcrepo_wrapper](https://github.com/cbeer/fcrepo_wrapper) will help you set this up. Start rails with `rails s`.
212
+ * For a fresh start, the data persisted in Lando can be wiped using `lando destroy`.
153
213
 
154
214
  ### Start background workers
155
215
 
@@ -163,14 +223,10 @@ Many of the services performed by Hyrax are resource intensive, and therefore ar
163
223
 
164
224
  Hyrax implements these jobs using the Rails [ActiveJob](http://edgeguides.rubyonrails.org/active_job_basics.html) framework, allowing you to choose the message queue system of your choice.
165
225
 
166
- For initial development, it is recommended that you change the default ActiveJob adapter from `:async` to `:inline`. This adapter will execute jobs immediately (in the foreground) as they are received. This can be accomplished by adding the following to your `config/environments/development.rb`
226
+ For initial development, it is recommended that you change the default ActiveJob adapter from `:async` to `:inline`. This adapter will execute jobs immediately (in the foreground) as they are received. This can be accomplished by modifying the `.env` file:
167
227
 
168
- ```
169
- class Application < Rails::Application
170
- # ...
171
- config.active_job.queue_adapter = :inline
172
- # ...
173
- end
228
+ ```dotenv
229
+ HYRAX_ACTIVE_JOB_QUEUE=inline
174
230
  ```
175
231
 
176
232
  For testing, it is recommended that you use the [built-in `:test` adapter](http://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/TestAdapter.html) which stores enqueued and performed jobs, running only those configured to run during test setup. To do this, add the following to `config/environments/test.rb`:
@@ -185,54 +241,15 @@ end
185
241
 
186
242
  **For production applications** you will want to use a more robust message queue system such as [Sidekiq](http://sidekiq.org/). The Hyrax Development Guide has a detailed walkthrough of [installing and configuring Sidekiq](https://github.com/samvera/hyrax/wiki/Using-Sidekiq-with-Hyrax).
187
243
 
188
- ### Create default administrative set
189
-
190
- **After** Fedora and Solr are running, create the default administrative set -- into which all works will be deposited unless assigned to other administrative sets -- by running the following command:
191
-
192
- ```
193
- rails hyrax:default_admin_set:create
194
- ```
195
-
196
- This command also makes sure that Hyrax's built-in workflows are loaded for your application and available for the default administrative set.
197
-
198
- **NOTE**: You will want to run this command the first time this code is deployed to a new environment as well.
199
-
200
- ### Generate a work type
201
-
202
- Using Hyrax requires generating at least one type of repository object, or "work type." Hyrax allows you to generate the work types required in your application by using a Rails generator-based tool. You may generate one or more of these work types.
203
-
204
- Pass a (CamelCased) model name to Hyrax's work generator to get started, e.g.:
205
-
206
- ```
207
- rails generate hyrax:work Work
208
- ```
209
-
210
- or
211
-
212
- ```
213
- rails generate hyrax:work MovingImage
214
- ```
215
-
216
- If your applications requires your work type to be namespaced, namespaces can be included by adding a slash to the model name which creates a new class called `MovingImage` within the `My` namespace:
217
-
218
- ```
219
- rails generate hyrax:work My/MovingImage
220
- ```
221
-
222
- You may wish to [customize your work type](https://github.com/samvera/hyrax/wiki/Customizing-your-work-types) now that it's been generated.
223
-
224
- ### Enable notifications
225
-
226
- Hyrax 2+ uses a WebSocket-based user notifications system, which requires Redis. To enable user notifications, make sure that you have configured ActionCable to use Redis as the adapter in your application's `config/cable.yml`. E.g., for the `development` Rails environment:
244
+ ### Create an Admin User
227
245
 
246
+ To access all of Hyrax's features you must be signed in as a user in the `admin` role. The default role management system uses the `config/role_map.yml` file to assign users to roles. For example:
228
247
  ```yaml
229
248
  development:
230
- adapter: redis
231
- url: redis://localhost:6379
249
+ admin:
250
+ - dev@test.internal
232
251
  ```
233
252
 
234
- Note that the Hyrax Management Guide contains additional information on [how to configure ActionCable in production environments](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide#notifications).
235
-
236
253
  ## Managing a Hyrax-based app
237
254
 
238
255
  The [Hyrax Management Guide](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide) provides tips for how to manage, customize, and enhance your Hyrax application, including guidance specific to:
data/hyrax.gemspec CHANGED
@@ -17,7 +17,15 @@ SUMMARY
17
17
 
18
18
  spec.homepage = "http://github.com/samvera/hyrax"
19
19
 
20
- spec.files = `git ls-files`.split($OUTPUT_RECORD_SEPARATOR).select { |f| File.dirname(f) !~ %r{\A"?spec\/?} && f != 'bin/rails' }
20
+ spec.files = `git ls-files`.split($OUTPUT_RECORD_SEPARATOR).reject do |f|
21
+ f == 'bin/rails' ||
22
+ # We want for downstream implementations to be able to leverage the various Hyrax factories.
23
+ # As such we need them to be available in the .gem file. See `./lib/hyrax/spec/factories.rb`
24
+ # for more details.
25
+ (File.dirname(f) =~ %r{\A"?spec\/?} &&
26
+ File.dirname(f) !~ %r{\A"?spec\/(factories|assets|support)\/?}
27
+ )
28
+ end
21
29
  spec.executables = spec.files.grep(%r{^bin/}).map { |f| File.basename(f) }
22
30
  spec.name = "hyrax"
23
31
  spec.require_paths = ["lib"]
@@ -48,7 +56,6 @@ SUMMARY
48
56
  spec.add_dependency 'dry-container', '~> 0.11'
49
57
  spec.add_dependency 'dry-events', '~> 1.0', '>= 1.0.1'
50
58
  spec.add_dependency 'dry-monads', '~> 1.6'
51
- spec.add_dependency 'dry-struct', '~> 1.6'
52
59
  spec.add_dependency 'dry-validation', '~> 1.10'
53
60
  spec.add_dependency 'flipflop', '~> 2.3'
54
61
  # Pin more tightly because 0.x gems are potentially unstable
@@ -2,6 +2,6 @@
2
2
 
3
3
  # Generated via
4
4
  # `rails generate hyrax:collection_resource <%= class_name %>`
5
- class <%= class_name %>Indexer < Hyrax::PcdmCollectionIndexer
5
+ class <%= class_name %>Indexer < Hyrax::Indexers::PcdmCollectionIndexer
6
6
  include Hyrax::Indexer(:<%= file_name %>)
7
7
  end
@@ -38,11 +38,23 @@ class Hyrax::ConfigGenerator < Rails::Generators::Base
38
38
  copy_file 'config/initializers/redis_config.rb'
39
39
  end
40
40
 
41
+ def configure_valkyrie
42
+ copy_file 'config/initializers/1_valkyrie.rb'
43
+ end
44
+
41
45
  def configure_valkyrie_index
42
46
  copy_file 'config/valkyrie_index.yml'
43
47
  copy_file 'config/solr_wrapper_valkyrie_test.yml'
44
48
  end
45
49
 
50
+ def metadata_dir
51
+ empty_directory 'config/metadata'
52
+ end
53
+
54
+ def derivatives_file_services
55
+ copy_file 'config/initializers/file_services.rb'
56
+ end
57
+
46
58
  def create_initializer_config_file
47
59
  copy_file 'config/initializers/hyrax.rb'
48
60
  end