Skip to content

Commit

Permalink
Merge pull request #33 from UNC-Libraries/APPDEV-11094-wcm-no-ac-fields
Browse files Browse the repository at this point in the history
APPDEV-11094: WCM no AC fields
  • Loading branch information
ldss-jm authored Oct 23, 2023
2 parents 71991cf + 9540b07 commit f1d5293
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 54 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ruby: [2.5, 2.6, 2.7]
ruby: [2.7, 3.0, 3.1, 3.2]
steps:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
Expand Down
45 changes: 0 additions & 45 deletions config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,6 @@ workflows:
# replace: ''
use id affix: false
use existing record set: false
elvl sets AC status: false
write format flag to recs: true
check LDR/09 for in-set consistency: true
write warnings to recs: true
Expand Down Expand Up @@ -160,7 +159,6 @@ workflows:
NEW: '_in_new_only'
produce delete file: true
report delete count on screen: true
elvl sets AC status: false
write format flag to recs: false
check LDR/09 for in-set consistency: false
write warnings to recs: false
Expand Down Expand Up @@ -222,10 +220,6 @@ workflows:
NEW: '_prep_for_load'
produce delete file: true
report delete count on screen: true
elvl sets AC status: true
add AC MARC fields: false
add noAC MARC fields: true
flag AC recs with changed headings: true
write format flag to recs: true
warn about non-e-resource records: true
warn about cat lang: true
Expand Down Expand Up @@ -256,10 +250,6 @@ workflows:
set record status by file diff: false
flag rec status: false
produce delete file: false
elvl sets AC status: true
add AC MARC fields: false
add noAC MARC fields: true
flag AC recs with changed headings: false

WCM - compare current downloadable full set against current ILS set:
clean ids:
Expand Down Expand Up @@ -337,10 +327,6 @@ workflows:
NEW: '_prep_for_load'
produce delete file: true
report delete count on screen: true
elvl sets AC status: true
add AC MARC fields: false
add noAC MARC fields: true
flag AC recs with changed headings: true

OHO pre-edit:
use existing record set: true
Expand Down Expand Up @@ -494,18 +480,6 @@ collections:
subfields:
- delimiter: 'f'
value: 'Unlimited simultaneous users'
- tag: '915'
i1: ' '
i2: ' '
subfields:
- delimiter: '9'
value: 'NOTAUTHO'
- tag: '949'
i1: ' '
i2: ' '
subfields:
- delimiter: 'a'
value: '*b3=x'
subcollection spec:
set by:
tag: '773'
Expand All @@ -521,10 +495,6 @@ collections:
JSTOR:
value: 'JSTOR .*(online collection)'
provider_param: 'JSTOR'
elvl sets AC status: false
add AC MARC fields: false
add noAC MARC fields: false
flag AC recs with changed headings: false
WCM - AGU:
id affix value: 'AGU'
add MARC field spec:
Expand Down Expand Up @@ -755,19 +725,4 @@ collections:
subfields:
- delimiter: 'a'
value: 'Provider: Wiley.'
- tag: '915'
i1: ' '
i2: ' '
subfields:
- delimiter: '9'
value: 'NOTAUTHO'
- tag: '949'
i1: ' '
i2: ' '
subfields:
- delimiter: 'a'
value: '*b3=x'
elvl sets AC status: false
add noAC MARC fields: true
flag AC recs with changed headings: false

13 changes: 7 additions & 6 deletions lib/marc_wrangler/record_comparer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,8 @@ def initialize(rec, ex_rec, spec)

@changed = detect_change(comparable_in_fields, comparable_ex_fields)

output_static = @spec['incoming record output files'] &&
@spec['incoming record output files']['STATIC'] != 'do not output'
return unless @changed || output_static

@ac_change = detect_ac_change(ac_in_fields, ac_ex_fields)
@output_static = @spec['incoming record output files'] &&
@spec['incoming record output files']['STATIC'] != 'do not output'
end

def static?
Expand All @@ -31,7 +28,11 @@ def detect_change(in_fields, ex_fields)
end

def ac_change?
@ac_change
return @ac_change if @ac_change

return unless @changed || @output_static

@ac_change ||= detect_ac_change(ac_in_fields, ac_ex_fields)
end

def detect_ac_change(in_fields, ex_fields)
Expand Down
2 changes: 1 addition & 1 deletion lib/marc_wrangler/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module MarcWrangler
VERSION = '0.1.5.1'.freeze
VERSION = '0.1.6'.freeze
end
2 changes: 1 addition & 1 deletion marc_wrangler.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Gem::Specification.new do |spec|
spec.add_development_dependency "rspec", "~> 3.0"

spec.add_runtime_dependency 'highline', "~> 2.0.1"
spec.add_runtime_dependency 'marc', "~> 1.0.2"
spec.add_runtime_dependency 'marc', "~> 1.1"
spec.add_runtime_dependency 'enhanced_marc', "~> 0.3.2"

# unf_ext 0.0.7.6 was released without windows binaries
Expand Down

0 comments on commit f1d5293

Please sign in to comment.