EPrints Technical Mailing List Archive

See the EPrints wiki for instructions on how to join this mailing list and related information.

Message: #10190


< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

Re: [EP-tech] Plugins/issues


Hi Will,

I think you would need to write your own plugin or modify the existing ones to do that.  It should be relatively easy to do in:

perl_lib/EPrints/Plugin/Issues/ExactTitleDups.pm
perl_lib/EPrints/Plugin/Issues/SimilarTitles.pm

You could either copy these to your archive's cfg/plugins/EPrints/Plugin/Issues/ directory and rename as TypeSimilarTitles.pm and TypeExactTitleDups.pm
and then start editing them there.  You would also need to disable the original Issue plugins in the archive's cfg/cfg.d/plugins.pl or similar:

$c->{plugins}->{"Issues::SimilarTitles"}->{params}->{disable} = 1;
$c->{plugins}->{"Issues::ExactTitleDups"}->{params}->{disable} = 1;

I think my approach would be to alter process_item_in_list in these to Issues plugins and get the type as well as the title and then maybe create a variable as follows:

my $type_title = $item->get_value( "type" ) . " " . $item->get_value( "title" );

Then use that in the code below (first for ExactTitleDups, second for SimilarTitles:

push @{$info->{titlemap}->{$type_title}}, $item->get_id;

push @{$info->{codemap}->{make_code( $type_title )}}, $item->get_id;


Once, you have done this.  I think if you run issues_audit you should only get dupes and similar titles where the type also matches.  However, as this is a little hacky, it is possible you may get some errant results, if you have eprint types that are only two characters or that are identical if you remove vowels.  I don't think and of the eprint types currently fall into this category.

Regards

David Newman


On 31/07/2025 11:30, Will Hughes wrote:
CAUTION: This e-mail originated outside the University of Southampton.
CAUTION: This e-mail originated outside the University of Southampton.

Hi

 

Sorry to surface here again – just coming for air…

I have been looking on Github, in the online manual, and the Bazaar but cannot find any hints. Are there readily available plugins for audit_issues that will only flag duplicate or similar titles if the reference type is the same?

 

If not, how can I mark a pair of duplicates so that they do not repeatedly show up in the audit_issues process?

 

Best wishes

 

Will   

 

Will Hughes

Emeritus Professor of Construction Management and Economics

School of the Built Environment     

University of Reading, PO Box 219, Whiteknights

Reading, RG6 6DF, UK

 


*** Options: https://wiki.eprints.org/w/Eprints-tech_Mailing_List
*** Archive: https://www.eprints.org/tech.php/
*** EPrints community wiki: https://wiki.eprints.org/