cul_hydra 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f781b50741ba5033e8befb86f7c1258250016592
4
- data.tar.gz: d3d5888a4e3c74576d238bba68fa68773c699cc9
3
+ metadata.gz: add7cd1403a95f97a6b1ad05e3696b555ffae5be
4
+ data.tar.gz: 4c2ff7a69468b565d1aff893ff455c9513d61f90
5
5
  SHA512:
6
- metadata.gz: 5197dbc0e00ce674ee31892589c6e40bc23063ad4ad46cb49a674bbdd0b8a4e87c822290f44d19ca92885aa2585b91c8ed34a321a7e4734022c8a25205c613ce
7
- data.tar.gz: c535c795331b38e79d1b1e87a2ae0ceb151e1fcbaf4943bc8bfdc9968d0459a15f82c8647c563765d953d39378ea57f103aeb5bb4b197f202df106f330906202
6
+ metadata.gz: a0cd91ebf116b1dd412bf0f69789e826cd4bc38e2bcf2be757b3b36feaa8fc7c05d37349cf6b107257e7f743b852d5cd174e8d28adffe1072e4ca32c6fb5421d
7
+ data.tar.gz: 39a9ae0bacf69f72f5e890021566442ea26d24216fa6301af9da7db37785cde412bf6790b0f2224cad8c1ed49cb9c9f23ae1df331cbaea801b9857f4c6f66155
@@ -1,6 +1,6 @@
1
1
  module Cul
2
2
  module Hydra
3
- VERSION = '1.0.1'
3
+ VERSION = '1.0.2'
4
4
  def self.version
5
5
  VERSION
6
6
  end
@@ -1,6 +1,6 @@
1
1
  module Cul
2
2
  module Hydra
3
- VERSION = '1.0.0'
3
+ VERSION = '1.0.1'
4
4
  def self.version
5
5
  VERSION
6
6
  end
data/lib/tasks/index.rake CHANGED
@@ -67,6 +67,36 @@ namespace :cul_hydra do
67
67
  end
68
68
 
69
69
  end
70
+
71
+ task :by_publish_target_pid => :environment do
72
+
73
+ puts '---------------------------'
74
+ puts 'Fedora URL: ' + ActiveFedora.config.credentials[:url]
75
+ puts 'Solr URL: ' + ActiveFedora.solr_config[:url]
76
+ puts '---------------------------'
77
+
78
+ if ENV['PID']
79
+ publish_target_pid = ENV['PID']
80
+ else
81
+ puts 'Please specify a publish target PID (e.g. PID=cul:123)'
82
+ next
83
+ end
84
+
85
+ skip_generic_resources = (ENV['skip_generic_resources'] == 'true')
86
+
87
+ start_time = Time.now
88
+ pids = Cul::Hydra::RisearchMembers.get_publish_target_member_pids(publish_target_pid, true)
89
+ total = pids.length
90
+ puts "Found #{total} publish target members."
91
+ counter = 0
92
+
93
+ pids.each do |pid|
94
+ Cul::Hydra::Indexer.index_pid(pid, skip_generic_resources, false)
95
+ counter += 1
96
+ puts "Indexed #{counter} of #{total} | #{Time.now - start_time} seconds"
97
+ end
98
+
99
+ end
70
100
 
71
101
  end
72
102
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cul_hydra
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Benjamin Armintor
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-05-06 00:00:00.000000000 Z
12
+ date: 2015-05-15 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: blacklight