hyrax 4.0.0.beta2 → 4.0.0.rc2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (141) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +126 -53
  3. data/.dassie/Gemfile +1 -1
  4. data/.dassie/app/controllers/catalog_controller.rb +1 -1
  5. data/.dassie/config/initializers/hyrax.rb +4 -0
  6. data/.github/CONTRIBUTING.md +39 -27
  7. data/.github/SUPPORT.md +2 -3
  8. data/.github/workflows/main.yml +4 -4
  9. data/.github/workflows/release.yml +10 -4
  10. data/.koppie/Gemfile +1 -2
  11. data/.koppie/app/controllers/catalog_controller.rb +1 -1
  12. data/.koppie/config/authorities/licenses.yml +7 -7
  13. data/.koppie/config/initializers/file_services.rb +4 -0
  14. data/.koppie/db/schema.rb +2 -2
  15. data/.koppie/yarn.lock +1 -1
  16. data/.regen +1 -1
  17. data/CONTAINERS.md +5 -5
  18. data/CONTRIBUTING.md +2 -2
  19. data/Dockerfile +21 -9
  20. data/README.md +24 -97
  21. data/app/actors/hyrax/actors/create_with_files_actor.rb +1 -1
  22. data/app/assets/stylesheets/hyrax/_catalog.scss +4 -0
  23. data/app/assets/stylesheets/hyrax/_forms.scss +4 -0
  24. data/app/controllers/concerns/hyrax/controller.rb +3 -24
  25. data/app/controllers/concerns/hyrax/works_controller_behavior.rb +1 -0
  26. data/app/controllers/hyrax/admin/strategies_controller.rb +2 -2
  27. data/app/controllers/hyrax/dashboard/collections_controller.rb +1 -1
  28. data/app/controllers/hyrax/downloads_controller.rb +16 -1
  29. data/app/controllers/hyrax/file_sets_controller.rb +9 -2
  30. data/app/controllers/hyrax/my/works_controller.rb +3 -1
  31. data/app/controllers/hyrax/transfers_controller.rb +4 -1
  32. data/app/controllers/hyrax/workflow_actions_controller.rb +3 -2
  33. data/app/forms/hyrax/forms/administrative_set_form.rb +1 -1
  34. data/app/forms/hyrax/forms/file_set_edit_form.rb +1 -1
  35. data/app/forms/hyrax/forms/file_set_form.rb +8 -35
  36. data/app/forms/hyrax/forms/pcdm_collection_form.rb +2 -2
  37. data/app/forms/hyrax/forms/pcdm_object_form.rb +46 -0
  38. data/app/forms/hyrax/forms/permission.rb +2 -2
  39. data/app/forms/hyrax/forms/resource_form.rb +19 -44
  40. data/app/forms/hyrax/forms/work_embargo_form.rb +3 -3
  41. data/app/forms/hyrax/forms/work_lease_form.rb +3 -3
  42. data/app/helpers/hyrax/content_block_helper_behavior.rb +1 -1
  43. data/app/helpers/hyrax/hyrax_helper_behavior.rb +1 -1
  44. data/app/helpers/hyrax/iiif_helper.rb +1 -1
  45. data/app/indexers/hyrax/valkyrie_file_set_indexer.rb +1 -1
  46. data/app/jobs/characterize_job.rb +3 -2
  47. data/app/jobs/valkyrie_create_derivatives_job.rb +0 -2
  48. data/app/models/collection_branding_info.rb +7 -13
  49. data/app/models/concerns/hyrax/ability.rb +1 -1
  50. data/app/models/concerns/hyrax/collection_behavior.rb +0 -47
  51. data/app/models/concerns/hyrax/solr_document/metadata.rb +1 -0
  52. data/app/models/concerns/hyrax/suppressible.rb +0 -8
  53. data/app/models/file_download_stat.rb +4 -4
  54. data/app/models/hyrax/collection_type.rb +0 -16
  55. data/app/models/hyrax/file_metadata.rb +5 -12
  56. data/app/models/hyrax/file_set.rb +1 -9
  57. data/app/models/hyrax/permission_template.rb +1 -1
  58. data/app/models/hyrax/statistic.rb +4 -4
  59. data/app/models/sipity.rb +27 -6
  60. data/app/presenters/hyrax/collection_presenter.rb +1 -1
  61. data/app/presenters/hyrax/iiif_manifest_presenter.rb +15 -5
  62. data/app/presenters/hyrax/presenter_factory.rb +2 -2
  63. data/app/presenters/hyrax/work_show_presenter.rb +1 -1
  64. data/app/presenters/hyrax/workflow_presenter.rb +1 -1
  65. data/app/search_builders/hyrax/collection_search_builder.rb +1 -0
  66. data/app/search_builders/hyrax/filter_suppressed_with_roles.rb +1 -1
  67. data/app/services/hyrax/admin_set_service.rb +1 -1
  68. data/app/services/hyrax/collections/nested_collection_query_service.rb +2 -2
  69. data/app/services/hyrax/database_migrator.rb +1 -1
  70. data/app/services/hyrax/edit_permissions_service.rb +21 -3
  71. data/app/services/hyrax/restriction_service.rb +1 -1
  72. data/app/services/hyrax/solr_query_service.rb +10 -2
  73. data/app/services/hyrax/solr_service.rb +24 -18
  74. data/app/services/hyrax/thumbnail_path_service.rb +10 -2
  75. data/app/services/hyrax/valkyrie_persist_derivatives.rb +26 -15
  76. data/app/services/hyrax/valkyrie_upload.rb +23 -30
  77. data/app/services/hyrax/visibility_propagator.rb +5 -5
  78. data/app/services/hyrax/visibility_reader.rb +1 -1
  79. data/app/services/hyrax/visibility_writer.rb +1 -1
  80. data/app/services/hyrax/workflow/permission_query.rb +5 -5
  81. data/app/services/hyrax/workflow/status_list_service.rb +1 -1
  82. data/app/validators/hyrax/collection_membership_validator.rb +2 -2
  83. data/app/views/hyrax/base/_attribute_rows.html.erb +2 -0
  84. data/app/views/hyrax/dashboard/collections/_form_for_select_collection.html.erb +1 -1
  85. data/app/views/hyrax/file_sets/_permission.html.erb +1 -1
  86. data/app/views/hyrax/file_sets/edit.html.erb +1 -1
  87. data/app/views/hyrax/file_sets/media_display/_audio.html.erb +1 -1
  88. data/app/views/hyrax/file_sets/media_display/_default.html.erb +1 -1
  89. data/app/views/hyrax/file_sets/media_display/_image.html.erb +1 -1
  90. data/app/views/hyrax/file_sets/media_display/_office_document.html.erb +1 -1
  91. data/app/views/hyrax/file_sets/media_display/_pdf.html.erb +1 -1
  92. data/app/views/hyrax/file_sets/media_display/_video.html.erb +1 -1
  93. data/app/views/hyrax/uploads/_js_templates.html.erb +8 -8
  94. data/app/views/hyrax/uploads/_js_templates_branding.html.erb +2 -2
  95. data/app/views/hyrax/users/_vitals.html.erb +4 -4
  96. data/chart/hyrax/Chart.yaml +7 -7
  97. data/chart/hyrax/README.md +5 -0
  98. data/chart/hyrax/templates/_helpers.tpl +14 -6
  99. data/chart/hyrax/templates/cron-embargo.yaml +1 -1
  100. data/chart/hyrax/templates/cron-lease.yaml +1 -1
  101. data/chart/hyrax/templates/deployment-worker.yaml +2 -2
  102. data/chart/hyrax/templates/extra-list.yaml +8 -0
  103. data/chart/hyrax/templates/secrets.yaml +3 -3
  104. data/chart/hyrax/values.yaml +22 -15
  105. data/config/initializers/kaminari_engine_patch.rb +16 -0
  106. data/config/locales/hyrax.de.yml +7 -7
  107. data/config/locales/hyrax.es.yml +7 -7
  108. data/config/locales/hyrax.fr.yml +8 -8
  109. data/config/locales/hyrax.it.yml +7 -7
  110. data/config/locales/hyrax.pt-BR.yml +7 -7
  111. data/config/locales/hyrax.zh.yml +8 -8
  112. data/config/metadata/file_set_metadata.yaml +130 -0
  113. data/documentation/MAINTENANCE.md +77 -0
  114. data/documentation/developing-your-hyrax-based-app.md +2 -2
  115. data/documentation/legacyREADME.md +3 -3
  116. data/hyrax.gemspec +7 -10
  117. data/lib/generators/hyrax/templates/catalog_controller.rb +1 -1
  118. data/lib/hyrax/configuration.rb +16 -0
  119. data/lib/hyrax/controlled_vocabularies/resource_label_caching.rb +1 -1
  120. data/lib/hyrax/engine.rb +2 -1
  121. data/lib/hyrax/transactions/container.rb +0 -2
  122. data/lib/hyrax/transactions/steps/save_collection_banner.rb +1 -1
  123. data/lib/hyrax/transactions/steps/save_collection_logo.rb +1 -1
  124. data/lib/hyrax/transactions/transaction.rb +3 -2
  125. data/lib/hyrax/version.rb +1 -1
  126. data/lib/hyrax.rb +0 -1
  127. data/lib/valkyrie/indexing/solr/indexing_adapter.rb +1 -1
  128. data/lib/wings/active_fedora_converter/file_metadata_node.rb +1 -1
  129. data/lib/wings/valkyrie/storage.rb +4 -1
  130. data/samvera-fall-TM3.svg +376 -0
  131. data/template.rb +1 -1
  132. metadata +43 -85
  133. data/app/conversions/power_converters/polymorphic_type.rb +0 -9
  134. data/app/conversions/power_converters/sipity_action.rb +0 -11
  135. data/app/conversions/power_converters/sipity_action_name.rb +0 -10
  136. data/app/conversions/power_converters/sipity_agent.rb +0 -9
  137. data/app/conversions/power_converters/sipity_entity.rb +0 -14
  138. data/app/conversions/power_converters/sipity_role.rb +0 -10
  139. data/app/conversions/power_converters/sipity_workflow_id.rb +0 -17
  140. data/app/conversions/power_converters/sipity_workflow_state.rb +0 -13
  141. data/app/conversions/power_converters.rb +0 -7
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f39a5cb135f87ff31b87b65f105d488572df699258a55c12bcc17f7f9e34b9a1
4
- data.tar.gz: c1aa78455834f0440debab01d811044787b1749a6825b937d6f23a114c96027e
3
+ metadata.gz: 24e7e9d00de4eebd2f2dfaf96bcd1a09ac9589b17e94ddcc0bf5681d3c93b0c4
4
+ data.tar.gz: 92753b2fbb1271cfec93e2eddd07d11da1091eaf8b36494e754ac3400a83a6a1
5
5
  SHA512:
6
- metadata.gz: e42131c51271b260719032394cdeed9d5c0464b5aeaf97206a276b79ae68a2bb714a6e255ffb3053275ea3c964014648acbfedbf5dbc098ec63089fd3eb25d2e
7
- data.tar.gz: c9c2645320f0ddf32e0d190057ee0fe58ac93886c9c104f0293e47ef44add50c8d3b569dedad6bdc02285b95c9993e3c2dc1a438f74a00cdfa8db65875a179d6
6
+ metadata.gz: 16a328b5b11d826f8149f0b260675ffe913d7e41a4b5c37035696cb32741b650a9f4bf9fa0d70ed08a1be712ddc8b452824bfb5be60a99b1a9d52ead57d8b7f3
7
+ data.tar.gz: bff8a0b37d073e1014f9566472030bb2b22e16a19fc1413dec6405cf21d6c3f178b0644ecbb48ee8ed0d259fe4f1b0422e747a5f3192c63753dc76d89ba8cb33
data/.circleci/config.yml CHANGED
@@ -2,22 +2,25 @@ version: 2.1
2
2
  orbs:
3
3
  samvera: samvera/circleci-orb@1
4
4
  browser-tools: circleci/browser-tools@1.3
5
+ ruby: circleci/ruby@2
6
+ node: circleci/node@5
7
+
5
8
  jobs:
6
9
  bundle:
7
10
  parameters:
8
11
  ruby_version:
9
12
  type: string
10
- default: 2.7.6
13
+ default: 2.7.7
11
14
  bundler_version:
12
15
  type: string
13
- default: 2.3.13
16
+ default: 2.4.8
14
17
  rails_version:
15
18
  type: string
16
- default: 6.1.6.1
19
+ default: 6.1.7.2
17
20
  executor:
18
21
  name: 'samvera/ruby'
19
22
  ruby_version: << parameters.ruby_version >>
20
- resource_class: medium+
23
+ resource_class: medium
21
24
  environment:
22
25
  RAILS_VERSION: << parameters.rails_version >>
23
26
  NOKOGIRI_USE_SYSTEM_LIBRARIES: true
@@ -44,8 +47,8 @@ jobs:
44
47
  - restore_cache:
45
48
  name: Restore rubocop cache
46
49
  keys:
47
- - v1-ruby<< parameters.ruby_version >>-bundle{{ checksum "Gemfile.lock" }}
48
- - v1-ruby<< parameters.ruby_version >>
50
+ - v1-rubocop-ruby<< parameters.ruby_version >>-bundle{{ checksum "Gemfile.lock" }}
51
+ - v1-rubocop-ruby<< parameters.ruby_version >>
49
52
  - v1
50
53
 
51
54
  - run:
@@ -54,9 +57,9 @@ jobs:
54
57
 
55
58
  - save_cache:
56
59
  name: Save rubocop cache
57
- key: v1-ruby<< parameters.ruby_version >>-bundle{{ checksum "Gemfile.lock" }}
60
+ key: v1-rubocop-ruby<< parameters.ruby_version >>-bundle{{ checksum "Gemfile.lock" }}
58
61
  paths:
59
- - ~/.cache
62
+ - ~/.cache/rubocop_cache
60
63
 
61
64
  - persist_to_workspace:
62
65
  root: ~/
@@ -68,17 +71,17 @@ jobs:
68
71
  parameters:
69
72
  ruby_version:
70
73
  type: string
71
- default: 2.7.6
74
+ default: 2.7.7
72
75
  bundler_version:
73
76
  type: string
74
- default: 2.3.13
77
+ default: 2.4.8
75
78
  rails_version:
76
79
  type: string
77
- default: 6.1.6.1
80
+ default: 6.1.7.2
78
81
  executor:
79
82
  name: 'samvera/ruby_fcrepo_solr_redis_postgres'
80
83
  ruby_version: << parameters.ruby_version >>
81
- resource_class: medium+
84
+ resource_class: medium
82
85
  environment:
83
86
  RAILS_VERSION: << parameters.rails_version >>
84
87
  NOKOGIRI_USE_SYSTEM_LIBRARIES: true
@@ -92,6 +95,15 @@ jobs:
92
95
  - samvera/bundle:
93
96
  ruby_version: << parameters.ruby_version >>
94
97
  bundler_version: << parameters.bundler_version >>
98
+ - run:
99
+ name: Generate .internal_test_app/Gemfile.lock
100
+ command: bundle lock
101
+ working_directory: .internal_test_app
102
+ - ruby/install-deps:
103
+ app-dir: .internal_test_app
104
+ - node/install-packages:
105
+ pkg-manager: yarn
106
+ app-dir: .internal_test_app
95
107
  - persist_to_workspace:
96
108
  root: ~/
97
109
  paths:
@@ -102,10 +114,10 @@ jobs:
102
114
  parameters:
103
115
  ruby_version:
104
116
  type: string
105
- default: 2.7.6
117
+ default: 2.7.7
106
118
  bundler_version:
107
119
  type: string
108
- default: 2.3.13
120
+ default: 2.4.8
109
121
  hyrax_valkyrie:
110
122
  type: string
111
123
  default: "false"
@@ -120,6 +132,7 @@ jobs:
120
132
  DATABASE_URL: postgresql://postgres@127.0.0.1/circle_test # Hard-coded with data from CircleCI orb, related to https://github.com/samvera-labs/samvera-circleci-orb/issues/42
121
133
  KARMA_BROWSER: ChromeHeadlessCustom
122
134
  RAILS_ROOT: .internal_test_app
135
+ SPEC_OPTS: "" # Clear output conflicts between samvera orb executor and ruby orb rspec command
123
136
  steps:
124
137
  - attach_workspace:
125
138
  at: ~/
@@ -127,17 +140,25 @@ jobs:
127
140
  name: Install system dependencies
128
141
  command: |
129
142
  sudo apt-get update
130
- sudo apt-get install imagemagick librsvg2-bin
143
+ sudo apt-get install imagemagick librsvg2-bin lsof
131
144
  - browser-tools/install-chrome
132
145
  - browser-tools/install-chromedriver
133
146
  - run:
147
+ name: Check Chrome install
134
148
  command: |
135
149
  google-chrome --version
136
150
  chromedriver --version
137
- name: Check Chrome install
151
+ - restore_cache:
152
+ keys:
153
+ - engine-node-v1-{{ checksum "package.json" }}
154
+ # Call yarn directly for hyrax engine; node orb demands a lockfile to use caching
138
155
  - run:
139
- name: Yarn install
156
+ name: Yarn Install (engine)
140
157
  command: yarn install
158
+ - save_cache:
159
+ key: engine-node-v1-{{ checksum "package.json" }}
160
+ paths:
161
+ - node_modules
141
162
  - samvera/install_solr_core:
142
163
  solr_config_path: .internal_test_app/solr/conf
143
164
  - samvera/install_solr_core:
@@ -147,56 +168,108 @@ jobs:
147
168
  - samvera/bundle:
148
169
  ruby_version: << parameters.ruby_version >>
149
170
  bundler_version: << parameters.bundler_version >>
171
+ # Ensure gems needed by the test app are installed
172
+ - ruby/install-deps:
173
+ app-dir: .internal_test_app
174
+ - node/install-packages:
175
+ pkg-manager: yarn
176
+ app-dir: .internal_test_app
150
177
  - run:
151
- command: bundle exec rake app:db:migrate
152
- - samvera/parallel_rspec
178
+ command: bundle exec rake db:migrate
179
+ working_directory: .internal_test_app
180
+ - ruby/rspec-test
181
+ - store_artifacts:
182
+ path: Gemfile.lock
183
+ destination: engine-gemfile-lock
184
+ - store_artifacts:
185
+ path: .internal_test_app/Gemfile.lock
186
+ destination: webapp-gemfile-lock
153
187
 
154
- # Trigger a workflow on the nurax repository that will deploy the most recent hyrax gem code to https://nurax-dev.curationexperts.com/
155
- deploy:
156
- docker:
157
- - image: ubuntu
158
- steps:
159
- - run:
160
- name: Install curl
161
- command: apt-get update && apt-get install -y curl
162
- - run:
163
- name: "Trigger Nurax deploy"
164
- command: |
165
- curl -X POST https://circleci.com/api/v2/project/gh/curationexperts/nurax/pipeline \
166
- --header "Circle-Token: $NURAX_CIRCLECI_TOKEN" \
167
- --header 'Accept: text/plain' \
168
- --header 'Content-Type: application/json'
169
188
  workflows:
170
189
  version: 2
171
- ruby2-7-6:
190
+ ruby3-2:
172
191
  jobs:
173
192
  - bundle:
174
- ruby_version: "2.7.6"
175
- rails_version: "6.1.6.1"
176
- bundler_version: "2.3.13"
193
+ ruby_version: "3.2.2"
194
+ rails_version: "6.1.7.2"
195
+ bundler_version: "2.4.8"
177
196
  - build:
178
- ruby_version: "2.7.6"
179
- rails_version: "6.1.6.1"
180
- bundler_version: "2.3.13"
197
+ ruby_version: "3.2.2"
198
+ rails_version: "6.1.7.2"
199
+ bundler_version: "2.4.8"
181
200
  requires:
182
201
  - bundle
183
202
  - test:
184
- name: "ruby2-7-6"
185
- ruby_version: "2.7.6"
186
- bundler_version: "2.3.13"
203
+ name: "ruby3-2"
204
+ ruby_version: "3.2.2"
205
+ bundler_version: "2.4.8"
187
206
  requires:
188
207
  - build
189
208
  - test:
190
- name: "ruby2-7-6-valkyrie"
191
- ruby_version: "2.7.6"
192
- bundler_version: "2.3.13"
209
+ name: "ruby3-2-valkyrie"
210
+ ruby_version: "3.2.2"
211
+ bundler_version: "2.4.8"
193
212
  hyrax_valkyrie: "true"
194
213
  requires:
195
214
  - build
196
- nurax-dev_deploy:
215
+ ruby3-1:
197
216
  jobs:
198
- - deploy:
199
- filters:
200
- branches:
201
- only:
202
- - main
217
+ - bundle:
218
+ ruby_version: "3.1.4"
219
+ rails_version: "6.1.7.2"
220
+ bundler_version: "2.4.8"
221
+ - build:
222
+ ruby_version: "3.1.4"
223
+ rails_version: "6.1.7.2"
224
+ bundler_version: "2.4.8"
225
+ requires:
226
+ - bundle
227
+ - test:
228
+ name: "ruby3-1"
229
+ ruby_version: "3.1.4"
230
+ bundler_version: "2.4.8"
231
+ requires:
232
+ - build
233
+ ruby3-0:
234
+ jobs:
235
+ - bundle:
236
+ ruby_version: "3.0.6"
237
+ rails_version: "6.1.7.2"
238
+ bundler_version: "2.4.8"
239
+ - build:
240
+ ruby_version: "3.0.6"
241
+ rails_version: "6.1.7.2"
242
+ bundler_version: "2.4.8"
243
+ requires:
244
+ - bundle
245
+ - test:
246
+ name: "ruby3-0"
247
+ ruby_version: "3.0.6"
248
+ bundler_version: "2.4.8"
249
+ requires:
250
+ - build
251
+ ruby2-7:
252
+ jobs:
253
+ - bundle:
254
+ ruby_version: "2.7.7"
255
+ rails_version: "6.1.7.2"
256
+ bundler_version: "2.4.8"
257
+ - build:
258
+ ruby_version: "2.7.7"
259
+ rails_version: "6.1.7.2"
260
+ bundler_version: "2.4.8"
261
+ requires:
262
+ - bundle
263
+ - test:
264
+ name: "ruby2-7"
265
+ ruby_version: "2.7.7"
266
+ bundler_version: "2.4.8"
267
+ requires:
268
+ - build
269
+ - test:
270
+ name: "ruby2-7-valkyrie"
271
+ ruby_version: "2.7.7"
272
+ bundler_version: "2.4.8"
273
+ hyrax_valkyrie: "true"
274
+ requires:
275
+ - build
data/.dassie/Gemfile CHANGED
@@ -8,7 +8,7 @@ else
8
8
  end
9
9
  git_source(:github) { |repo| "https://github.com/#{repo}.git" }
10
10
 
11
- ruby '2.7.6'
11
+ ruby '3.2.1'
12
12
 
13
13
  # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
14
14
  gem 'rails', '~> 6.0'
@@ -25,7 +25,7 @@ class CatalogController < ApplicationController
25
25
 
26
26
  # Because too many times on Samvera tech people raise a problem regarding a failed query to SOLR.
27
27
  # Often, it's because they inadvertently exceeded the character limit of a GET request.
28
- config.http_method = :post
28
+ config.http_method = Hyrax.config.solr_default_method
29
29
 
30
30
  ## Default parameters to send to solr for all search-like requests. See also SolrHelper#solr_search_params
31
31
  config.default_solr_params = {
@@ -46,6 +46,10 @@ Hyrax.config do |config|
46
46
  # Set the system-wide virus scanner
47
47
  config.virus_scanner = Hyrax::VirusScanner
48
48
 
49
+ # The default method used for Solr queries. Values are :get or :post.
50
+ # Post is suggested to prevent issues with URL length.
51
+ config.solr_default_method = :post
52
+
49
53
  ##
50
54
  # To index to the Valkyrie core, uncomment the following lines.
51
55
  # config.query_index_from_valkyrie = true
@@ -1,6 +1,6 @@
1
1
  # How to Contribute
2
2
 
3
- We want your help to make Samvera great. There are a few guidelines
3
+ We want your help to make the Samvera community great. There are a few guidelines
4
4
  that we need contributors to follow so that we can have a chance of
5
5
  keeping on top of things.
6
6
 
@@ -11,16 +11,27 @@ experience for all its members, whether they are at a formal gathering, in
11
11
  a social setting, or taking part in activities online. Please see our
12
12
  [Code of Conduct](CODE_OF_CONDUCT.md) for more information.
13
13
 
14
- ## Samvera Community Intellectual Property Licensing and Ownership
14
+ ## Language
15
15
 
16
- All code contributors must have an Individual Contributor License Agreement
17
- (iCLA) on file with the Samvera Steering Group. If the contributor works for
18
- an institution, the institution must have a Corporate Contributor License
19
- Agreement (cCLA) on file.
16
+ The language we use matters. Today, tomorrow, and for years to come
17
+ people will read the code we write. They will judge us for our
18
+ design, logic, and the words we use to describe the system.
20
19
 
21
- https://wiki.lyrasis.org/display/samvera/Samvera+Community+Intellectual+Property+Licensing+and+Ownership
20
+ Our words should be accessible. Favor descriptive words that give
21
+ meaning while avoiding reinforcing systemic inequities. For example,
22
+ in the Samvera community, we should favor using allowed\_list instead
23
+ of whitelist, denied\_list instead of blacklist, or source/copy
24
+ instead of master/slave.
22
25
 
23
- You should also add yourself to the `CONTRIBUTORS.md` file in the root of the project.
26
+ We're going to get it wrong, but this is a call to keep working to
27
+ make it right. View our code and the words we choose as a chance to
28
+ have a conversation. A chance to grow an understanding of the systems
29
+ we develop as well as the systems in which we live.
30
+
31
+ See [“Blacklists” and “whitelists”: a salutary warning concerning the
32
+ prevalence of racist language in discussions of predatory
33
+ publishing](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC6148600/) for
34
+ further details.
24
35
 
25
36
  ## Contribution Tasks
26
37
 
@@ -34,7 +45,7 @@ You should also add yourself to the `CONTRIBUTORS.md` file in the root of the pr
34
45
  ### Reporting Issues
35
46
 
36
47
  * Make sure you have a [GitHub account](https://github.com/signup/free)
37
- * Submit a [Github issue](./issues) by:
48
+ * Submit a [Github issue](https://github.com/samvera/hyrax/issues/) by:
38
49
  * Clearly describing the issue
39
50
  * Provide a descriptive summary
40
51
  * Explain the expected behavior
@@ -45,15 +56,22 @@ You should also add yourself to the `CONTRIBUTORS.md` file in the root of the pr
45
56
 
46
57
  * Fork the repository on GitHub
47
58
  * Create a topic branch from where you want to base your work.
48
- * This is usually the master branch.
49
- * To quickly create a topic branch based on master; `git branch fix/master/my_contribution master`
50
- * Then checkout the new branch with `git checkout fix/master/my_contribution`.
51
- * Please avoid working directly on the `master` branch.
59
+ * This is usually the `main` branch.
60
+ * To quickly create a topic branch based on `main`; `git branch fix/main/my_contribution main`
61
+ * Then checkout the new branch with `git checkout fix/main/my_contribution`.
62
+ * Please avoid working directly on the `main` branch.
63
+ * Please do not create a branch called `master`. (See note below.)
52
64
  * You may find the [hub suite of commands](https://github.com/defunkt/hub) helpful
53
65
  * Make sure you have added sufficient tests and documentation for your changes.
54
66
  * Test functionality with RSpec; Test features / UI with Capybara.
55
67
  * Run _all_ the tests to assure nothing else was accidentally broken.
56
68
 
69
+ NOTE: This repository follows the [Samvera Community Code of Conduct](https://samvera.atlassian.net/wiki/spaces/samvera/pages/405212316/Code+of+Conduct)
70
+ and [language recommendations](#language).
71
+ Please ***do not*** create a branch called `master` for this repository or as part of
72
+ your pull request; the branch will either need to be removed or renamed before it can
73
+ be considered for inclusion in the code base and history of this repository.
74
+
57
75
  ### Documenting Code
58
76
 
59
77
  * All new public methods, modules, and classes should include inline documentation in [YARD](http://yardoc.org/).
@@ -63,15 +81,11 @@ You should also add yourself to the `CONTRIBUTORS.md` file in the root of the pr
63
81
  * If you don't know exactly what a bit of code does, it is extra likely that it needs to be documented. Take a stab at it and ask for feedback in your pull request. You can use the 'blame' button on GitHub to identify the original developer of the code and @mention them in your comment.
64
82
  * This work greatly increases the usability of the code base and supports the on-ramping of new committers.
65
83
  * We will all be understanding of one another's time constraints in this area.
66
- * YARD examples:
67
- * [Hyrax::AdminSet](https://github.com/samvera/hyrax/blob/master/app/models/admin_set.rb)
68
- * [ActiveTriples::LocalName::Minter](https://github.com/ActiveTriples/active_triples-local_name/blob/master/lib/active_triples/local_name/minter.rb)
69
84
  * [Getting started with YARD](http://www.rubydoc.info/gems/yard/file/docs/GettingStarted.md)
70
85
 
71
86
  ### Committing changes
72
87
 
73
88
  * Make commits of logical units.
74
- * Your commit should include a high level description of your work in HISTORY.textile
75
89
  * Check for unnecessary whitespace with `git diff --check` before committing.
76
90
  * Make sure your commit messages are [well formed](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html).
77
91
  * If you created an issue, you can close it by including "Closes #issue" in your commit message. See [Github's blog post for more details](https://github.com/blog/1386-closing-issues-via-commit-messages)
@@ -112,18 +126,16 @@ You should also add yourself to the `CONTRIBUTORS.md` file in the root of the pr
112
126
 
113
127
  ### Submitting Changes
114
128
 
115
- [Detailed Walkthrough of One Pull Request per Commit](http://ndlib.github.io/practices/one-commit-per-pull-request/)
116
-
117
129
  * Read the article ["Using Pull Requests"](https://help.github.com/articles/using-pull-requests) on GitHub.
118
- * Make sure your branch is up to date with its parent branch (i.e. master)
119
- * `git checkout master`
130
+ * Make sure your branch is up to date with its parent branch (i.e. main)
131
+ * `git checkout main`
120
132
  * `git pull --rebase`
121
133
  * `git checkout <your-branch>`
122
- * `git rebase master`
134
+ * `git rebase main`
123
135
  * It is a good idea to run your tests again.
124
136
  * If you've made more than one commit take a moment to consider whether squashing commits together would help improve their logical grouping.
125
137
  * [Detailed Walkthrough of One Pull Request per Commit](http://ndlib.github.io/practices/one-commit-per-pull-request/)
126
- * `git rebase --interactive master` ([See Github help](https://help.github.com/articles/interactive-rebase))
138
+ * `git rebase --interactive main` ([See Github help](https://help.github.com/articles/interactive-rebase))
127
139
  * Squashing your branch's changes into one commit is "good form" and helps the person merging your request to see everything that is going on.
128
140
  * Push your changes to a topic branch in your fork of the repository.
129
141
  * Submit a pull request from your fork to the project.
@@ -133,14 +145,14 @@ You should also add yourself to the `CONTRIBUTORS.md` file in the root of the pr
133
145
  We adopted [Github's Pull Request Review](https://help.github.com/articles/about-pull-request-reviews/) for our repositories.
134
146
  Common checks that may occur in our repositories:
135
147
 
136
- 1. Travis CI - where our automated tests are running
137
- 2. Hound CI - where we check for style violations
148
+ 1. [CircleCI](https://circleci.com/gh/samvera) - where our automated tests are running
149
+ 2. RuboCop/Bixby - where we check for style violations
138
150
  3. Approval Required - Github enforces at least one person approve a pull request. Also, all reviewers that have chimed in must approve.
139
151
  4. CodeClimate - is our code remaining healthy (at least according to static code analysis)
140
152
 
141
153
  If one or more of the required checks failed (or are incomplete), the code should not be merged (and the UI will not allow it). If all of the checks have passed, then anyone on the project (including the pull request submitter) may merge the code.
142
154
 
143
- *Example: Carolyn submits a pull request, Justin reviews the pull request and approves. However, Justin is still waiting on other checks (Travis CI is usually the culprit), so he does not merge the pull request. Eventually, all of the checks pass. At this point, Carolyn or anyone else may merge the pull request.*
155
+ *Example: Carolyn submits a pull request, Justin reviews the pull request and approves. However, Justin is still waiting on other checks (CI tests are usually the culprit), so he does not merge the pull request. Eventually, all of the checks pass. At this point, Carolyn or anyone else may merge the pull request.*
144
156
 
145
157
  #### Things to Consider When Reviewing
146
158
 
@@ -157,7 +169,7 @@ This is your chance for a mentoring moment of another developer. Take time to gi
157
169
  * Do new or changed methods, modules, and classes have documentation?
158
170
  * Does the commit contain more than it should? Are two separate concerns being addressed in one commit?
159
171
  * Does the description of the new/changed specs match your understanding of what the spec is doing?
160
- * Did the Travis tests complete successfully?
172
+ * Did the Continuous Integration tests complete successfully?
161
173
 
162
174
  If you are uncertain, bring other contributors into the conversation by assigning them as a reviewer.
163
175
 
data/.github/SUPPORT.md CHANGED
@@ -1,10 +1,9 @@
1
1
  # Getting Help
2
2
 
3
- If you have questions or need help, please email [the Samvera community tech list](mailto:samvera-tech@googlegroups.com) or stop by the #dev channel in [the Samvera community Slack team](https://wiki.lyrasis.org/pages/viewpage.action?pageId=87460391#Getintouch!-Slack).
3
+ If you have questions or need help, please email [the Samvera community tech list](mailto:samvera-tech@googlegroups.com) or stop by the #dev channel in [the Samvera Community Slack Workspace](https://samvera.atlassian.net/wiki/spaces/samvera/pages/405211682/Getting+Started+in+the+Samvera+Community#Join-the-Samvera-Slack-workspace).
4
4
 
5
5
  The [Hyrax wiki](https://github.com/samvera/hyrax/wiki) gathers documentation as the community tries things and learns what works. There is useful knowledge and history there but please keep in mind that this information can age quickly. Refer to the [README.md](./README.md) for the best updated guidance we have to offer.
6
6
 
7
- You can also look in the [Samvera Community Knowledge Base](https://samvera.github.io) for help with Hyrax or other Samvera Community questions.
8
7
 
9
8
  ## Reporting Issues
10
9
 
@@ -12,4 +11,4 @@ If you would like to report an issue with Hyrax, first do search [the list of is
12
11
 
13
12
  ## Reporting Security Issues
14
13
 
15
- To report a security vulnerability, email [samvera-steering@googlegroups.com](mailto:samvera-steering@googlegroups.com) and the Steering Group will coordinate the community response. In your message, please document to the best of your ability cases (relevant software versions, conditions, etc.) where the vulnerability is applicable, the potential negative effects, and any known workarounds or fixes to mitigate the risk. Steering will communicate this to the Partners and the rest of the community in a timely fashion.
14
+ To report a security vulnerability, email [the Samvera Board](mailto:board@samvera.org) and the they will coordinate the community response. In your message, please document to the best of your ability cases (relevant software versions, conditions, etc.) where the vulnerability is applicable, the potential negative effects, and any known workarounds or fixes to mitigate the risk. The Board will communicate this to the Partners and the rest of the community in a timely fashion.
@@ -2,16 +2,16 @@ name: Trigger Nurax build
2
2
  on:
3
3
  workflow_dispatch:
4
4
  push:
5
+ branches:
6
+ - 'main'
5
7
 
6
8
  jobs:
7
9
  trigger:
8
10
  runs-on: ubuntu-latest
9
11
  steps:
10
- - uses: peter-evans/repository-dispatch@v1
12
+ - uses: peter-evans/repository-dispatch@v2.1.1
11
13
  with:
12
14
  token: ${{ secrets.NURAX_ACCESS_TOKEN }}
13
15
  event-type: push
14
- repository: curationexperts/nurax
16
+ repository: samvera-labs/nurax
15
17
  client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}"}'
16
-
17
-
@@ -2,16 +2,22 @@ name: Trigger Nurax build
2
2
  on:
3
3
  workflow_dispatch:
4
4
  release:
5
+ types: [released]
5
6
 
6
7
  jobs:
7
8
  trigger:
8
9
  runs-on: ubuntu-latest
9
10
  steps:
10
- - uses: peter-evans/repository-dispatch@v1
11
+ - id: latest-release
12
+ uses: pozetroninc/github-action-get-latest-release@v0.7.0
13
+ with:
14
+ repository: ${{ github.repository }}
15
+ token: ${{ github.token }}
16
+ excludes: prerelease, draft
17
+ - uses: peter-evans/repository-dispatch@v2.1.1
18
+ if: ${{ steps.latest-release.outputs.release == github.ref_name }}
11
19
  with:
12
20
  token: ${{ secrets.NURAX_ACCESS_TOKEN }}
13
21
  event-type: release
14
- repository: curationexperts/nurax
22
+ repository: samvera-labs/nurax
15
23
  client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}"}'
16
-
17
-
data/.koppie/Gemfile CHANGED
@@ -6,7 +6,7 @@ else
6
6
  end
7
7
  git_source(:github) { |repo| "https://github.com/#{repo}.git" }
8
8
 
9
- ruby '2.7.6'
9
+ ruby '2.7.7'
10
10
 
11
11
  gem 'bootsnap', '>= 1.1.0', require: false
12
12
  gem 'bootstrap', '~> 4.0'
@@ -29,7 +29,6 @@ gem 'turbolinks', '~> 5'
29
29
  gem 'twitter-typeahead-rails', '0.11.1.pre.corejavascript'
30
30
  gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
31
31
  gem 'uglifier', '>= 1.3.0'
32
- gem 'valkyrie', '~> 2', '>= 2.1.1'
33
32
 
34
33
  group :development do
35
34
  gem 'better_errors' # add command line in browser when errors
@@ -29,7 +29,7 @@ class CatalogController < ApplicationController
29
29
 
30
30
  # Because too many times on Samvera tech people raise a problem regarding a failed query to SOLR.
31
31
  # Often, it's because they inadvertently exceeded the character limit of a GET request.
32
- config.http_method = :post
32
+ config.http_method = Hyrax.config.solr_default_method
33
33
 
34
34
  ## Default parameters to send to solr for all search-like requests. See also SolrHelper#solr_search_params
35
35
  config.default_solr_params = {
@@ -1,25 +1,25 @@
1
1
  terms:
2
2
  - id: http://creativecommons.org/licenses/by/3.0/us/
3
3
  term: Attribution 3.0 United States
4
- active: true
4
+ active: false
5
5
  - id: http://creativecommons.org/licenses/by-sa/3.0/us/
6
6
  term: Attribution-ShareAlike 3.0 United States
7
- active: true
7
+ active: false
8
8
  - id: http://creativecommons.org/licenses/by-nc/3.0/us/
9
9
  term: Attribution-NonCommercial 3.0 United States
10
- active: true
10
+ active: false
11
11
  - id: http://creativecommons.org/licenses/by-nd/3.0/us/
12
12
  term: Attribution-NoDerivs 3.0 United States
13
- active: true
13
+ active: false
14
14
  - id: http://creativecommons.org/licenses/by-nc-nd/3.0/us/
15
15
  term: Attribution-NonCommercial-NoDerivs 3.0 United States
16
- active: true
16
+ active: false
17
17
  - id: http://creativecommons.org/licenses/by-nc-sa/3.0/us/
18
18
  term: Attribution-NonCommercial-ShareAlike 3.0 United States
19
- active: true
19
+ active: false
20
20
  - id: http://www.europeana.eu/portal/rights/rr-r.html
21
21
  term: All rights reserved
22
- active: true
22
+ active: false
23
23
  - id: https://creativecommons.org/licenses/by/4.0/
24
24
  term: Creative Commons BY Attribution 4.0 International
25
25
  active: true
@@ -0,0 +1,4 @@
1
+ ActiveSupport::Reloader.to_prepare do
2
+ Hydra::Derivatives.config.output_file_service = Hyrax::ValkyriePersistDerivatives
3
+ Hydra::Derivatives.config.source_file_service = Hyrax::LocalFileService
4
+ end
data/.koppie/db/schema.rb CHANGED
@@ -2,8 +2,8 @@
2
2
  # of editing this file, please use the migrations feature of Active Record to
3
3
  # incrementally modify your database, and then regenerate this schema definition.
4
4
  #
5
- # This file is the source Rails uses to define your schema when running `rails
6
- # db:schema:load`. When creating a new database, `rails db:schema:load` tends to
5
+ # This file is the source Rails uses to define your schema when running `bin/rails
6
+ # db:schema:load`. When creating a new database, `bin/rails db:schema:load` tends to
7
7
  # be faster and is potentially less error prone than running all of your
8
8
  # migrations from scratch. Old migrations may fail to apply correctly if those
9
9
  # migrations use external dependencies or application code.
data/.koppie/yarn.lock CHANGED
@@ -1355,7 +1355,7 @@ unfetch@^4.2.0:
1355
1355
  resolved "https://registry.yarnpkg.com/unfetch/-/unfetch-4.2.0.tgz#7e21b0ef7d363d8d9af0fb929a5555f6ef97a3be"
1356
1356
  integrity sha512-F9p7yYCn6cIW9El1zi0HI6vqpeIvBsr3dSuRO6Xuppb1u5rXpCPmMvLSyECLhybr9isec8Ohl0hPekMVrEinDA==
1357
1357
 
1358
- universalviewer@^3.1.1:
1358
+ universalviewer@^3.1.4:
1359
1359
  version "3.1.4"
1360
1360
  resolved "https://registry.yarnpkg.com/universalviewer/-/universalviewer-3.1.4.tgz#5355aa77e06a05d1252f473e7b437caa24ecd9ff"
1361
1361
  integrity sha512-1z/0iN0JcGlN3lNX3/hMts2WAaLdmvG+j50lgqdzKsGex6033XmE30otl0U2UvF21S5U7bVlW+KYlMeIQyTRww==
data/.regen CHANGED
@@ -1,2 +1,2 @@
1
1
  # When updating CI regen seed, set to current date.
2
- 2022-07-01T00
2
+ 2023-04-11T16:25:55