From 63c98ca91e2e2b434b3449be5bfc33feefcfe7ea Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 21 Jun 2021 20:43:36 +0000 Subject: apalike-ejor (21jun21) git-svn-id: svn://tug.org/texlive/trunk@59667 c570f23f-e606-0410-a88d-b1316a301751 --- .../bibtex/bst/apalike-ejor/apalike-ejor.bst | 81 +++++++++++++++------- 1 file changed, 57 insertions(+), 24 deletions(-) (limited to 'Master/texmf-dist/bibtex') diff --git a/Master/texmf-dist/bibtex/bst/apalike-ejor/apalike-ejor.bst b/Master/texmf-dist/bibtex/bst/apalike-ejor/apalike-ejor.bst index 75ae881ed53..8bfdb80b631 100644 --- a/Master/texmf-dist/bibtex/bst/apalike-ejor/apalike-ejor.bst +++ b/Master/texmf-dist/bibtex/bst/apalike-ejor/apalike-ejor.bst @@ -1,4 +1,4 @@ -% apalike-ejor v1.1.0 +% apalike-ejor v1.2.0 % Copyright (C) 2021 Adam Rumpf % % BibTeX `apalike-ejor' bibliography style, forked from the `apalike' style, @@ -14,14 +14,19 @@ % - Changed `and' to `\&' in lists of multiple authors. % - Changed `:' to `, ' between volume number and page numbers. % - Added a hyperlinked URL field (requires hyperref). -% - Added a hyperlinked DOI field (requires hyperref). +% - Added a hyperlinked DOI field (requires hyperref). If both the DOI and +% URL fields are present, the DOI is preferred. % - Removed address information from publisher names. % - Removed editor information, publisher information, and the words "In" and % "pages" from conference proceedings. -% - Removed thesis label from theses. +% - Removed thesis label and address from theses. % - Book edition numbers are in parentheses following the title, and % abbreviated "edition" to "ed.". % - Added an optional chapter number for books. +% - Added a new dataset field for misc references. If it contains any value +% besides "0" or "false", the string "[dataset]" is prepended to the +% reference. +% - Moved the note field to the end of references (except for unpublished). % % ============================================================================= % @@ -68,13 +73,15 @@ % this release clarified the license. % 18-jun-21 (AR) Modifications made by Adam Rumpf to comply with the EJOR % bibliography style guide. +% 21-jun-21 (AR) Modified misc formatting and added dataset field support. ENTRY { address author booktitle chapter - doi % added for apalike-ejor + dataset % unique field added for apalike-ejor + doi % added for apalike-ejor edition editor howpublished @@ -237,17 +244,30 @@ FUNCTION {format.urlending} % formats ending for doi and/or url fields doi missing$ { url missing$ - { fin.entry + { note output + fin.entry } { new.block % use url if no doi format.url output - fin.npentry + note missing$ + { fin.npentry } + { new.block + note output + fin.npentry + } + if$ } if$ } - { new.block % use doi if present + { new.block % use doi if present format.doi output - fin.npentry + note missing$ + { fin.npentry } + { new.block + note output + fin.npentry + } + if$ } if$ } @@ -551,6 +571,17 @@ FUNCTION {format.incoll.inproc.crossref} " \cite{" * crossref * "}" * } +FUNCTION {format.dataset} % unique "dataset" field for apalike +{ dataset empty$ % prints "[dataset]" for any value besides "0" or "false" + { "" } + { dataset "0" = dataset "l" change.case$ "false" = or + { "" } + { "[dataset]" } + if$ + } + if$ +} + FUNCTION {article} { output.bibitem format.authors "author" output.check @@ -568,7 +599,7 @@ FUNCTION {article} } if$ new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -598,14 +629,12 @@ FUNCTION {book} new.block format.number.series output new.sentence - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% chapter missing$ % adding chapter number for apalike-ejor { publisher output } { publisher " " * format.chapter.pages * output } if$ - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % address output removing publisher address for apalike-ejor } { new.block @@ -613,7 +642,7 @@ FUNCTION {book} } if$ new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -628,7 +657,7 @@ FUNCTION {booklet} howpublished output address output new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -664,7 +693,7 @@ FUNCTION {inbook} if$ format.edition output new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -691,7 +720,7 @@ FUNCTION {incollection} } if$ new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -718,7 +747,7 @@ FUNCTION {inproceedings} } if$ new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -736,7 +765,7 @@ FUNCTION {manual} address output format.edition output new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -750,14 +779,18 @@ FUNCTION {mastersthesis} new.block % "Master's thesis" format.thesis.type output.nonnull remove for apalike-ejor school "school" output.check - address output +% address output % removing address for apalike-ejor new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } FUNCTION {misc} { output.bibitem + format.dataset "" = % unique "dataset" field for apalike-ejor + { skip$ } + { format.dataset " " * write$ } + if$ format.authors output author format.key output % special for output.year.check % apalike @@ -766,7 +799,7 @@ FUNCTION {misc} new.block howpublished output new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -780,9 +813,9 @@ FUNCTION {phdthesis} new.block % "PhD thesis" format.thesis.type output.nonnull remove for apalike-ejor school "school" output.check - address output +% address output % removing address for apalike-ejor new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -800,7 +833,7 @@ FUNCTION {proceedings} organization output % a nonempty organization publisher output % here new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } @@ -816,7 +849,7 @@ FUNCTION {techreport} institution "institution" output.check address output new.block - note output +% note output % note handled in urlending format.urlending % auto-formatted doi/url ending } -- cgit v1.2.3