2013/8/9 jjbrioist <[email protected]>: > Le vendredi 09 août 2013 à 17:35 +0200, Robin Haberkorn a écrit : > Hello Robin, > > I was facing the same issue as you, although I am using -ms for the time. > I use the -S option to get inline references. > > Assume you have the following entry in your > xxx.bib file : > > %A John Robert > %T Measuring steel bar tension using X-rays > %D 1993 > %K X-rays dynamometer steel > %L Steel Res. 35 > %R Steel Res. > %N 35 > %I Springer > %C Cleveland > > > and your text reads something like > > .BD > Lately my life > .[[ > Robert > .]] > has become more complicated. > .R > .DE > .LP > > (take care of the double brackets). Compile this with > >> refer -pxxx.bib -e -S thesis.ms > aux.ms >> groff -ms aux.ms > thesis.ps >
Hello Jean, I wonder how this could work. Perhaps -ms implementations of ]- and ][ do the label insertion appropriately. The manual refer preprocessing however is definitely not necessary since refer -S is just a short cut to defining a label string (you could embed that in .R1/.R2 sections). I have now found an ugly solution that works with -mom. I use something like this near the top of my document: .R1 # this extracts the last name of the first author and the publication date label A.nD.y database biblio.ref .R2 \# Save Mom's version of ]- and ][ .rn ]- MOM-REFER-BEGIN \# Provide my own versions: the brackets are inserted automatically so you don't need \# .[[ and .]] or "[]" in the flags field \# \f(SC merely sets a small-caps font \# [F contains the label as generated by refer .ds ]- [\f(SC\\*([F\fP]\c .rn ][ MOM-REFER-END .ds ][ References can then be inserted without mom's .REF macros: .[ whatever .] And to generate the bibliography I do: \# restore mom's ]- and ][ .rn MOM-REFER-BEGIN ]- .rn MOM-REFER-END ][ . .BIBLIOGRAPHY .BIBLIOGRAPHY_TYPE LIST .R1 no-label-in-text no-label-in-reference sort A1Q1T1B1E1 reverse A1 bibliography biblio.ref .R2 .BIBLIOGRAPHY OFF So while for ordinary inline references I did the formatting with custom macros, in the bibliography I let mom do it. The entire database (biblio.ref) is inserted by refer, which is fine as long as I do not have a real database (with lots of entries) but one that contains only the publications I have ever referred to in the main body of the text. regards, Robin
