2

I have just created a bibliography style file using makebst, but I am unhappy with the style of one of the fields that was created. Here is what I mean: enter image description here

Problem: The Publisher field and the Year are not separated by a space. How do I make it such that I have Cambridge University Press 2006? Preferable solutions would include:

  • Pointing out which option in makebst I should change / choose differently, or
  • Adding / Modifying a few lines in the bst file

If it helps, these are the options I used with makebst:

seq-no,nm-init,ed-au,mcite,mct-1,mct-x2,yr-par,xmth,tit-it,jttl-rm,vol-2bf,volp-com,jpg-1,jwdpg,num-xser,pub-date,edpar,bkedcap,blk-com,blknt,pp,ed,xedn,jabr,and-xcom,etal-xc,etal-it,nfss

A MWE:

\documentclass[a4paper,11pt,twoside]{scrreprt}
\usepackage{cite}

\begin{document}

Some text here\cite{test1}

\bibliographystyle{mystdbst_v2}
\bibliography{mybibfile}

\end{document}

Here is my bib entry:

@book{test1, 
    title={Geometrical Frustration},
    author={Sadoc, J.-F.S. and Mosseri, R.},
    publisher={Cambridge University Press},
    year={2006}
}

I could upload the bst code, but it's a little long, and would prefer not to clog up my post if possible. If it is required though, let me know in the comments. Thank you very much!

EDIT

So I still have not solved my problem, just thought I could share a bit more information. I think I can narrow it down to the format.publisher.address and format.date strings, together with the book string.

FUNCTION {format.publisher.address}
{ publisher "publisher" bibinfo.warn format.org.or.pub
}

%

FUNCTION {format.date}
{
  ""
  duplicate$ empty$
  year  "year"  bibinfo.check duplicate$ empty$
    { swap$ 'skip$
        { "there's a month but no year in " cite$ * warning$ }
      if$
      *
    }
    { swap$ 'skip$
        {
          swap$
          " " * swap$
        }
      if$
      *
    }
  if$
  duplicate$ empty$
    'skip$
    {
      before.all 'output.state :=
    " ("  swap$ * ")" *
    }
  if$
}

%

FUNCTION {book}
{ output.bibitem
  author empty$
    { format.editors "author and editor" output.check
    }
    { format.authors output.nonnull
      crossref missing$
        { "author and editor" editor either.or.check }
        'skip$
      if$
    }
  if$
  format.btitle "title" output.check
  crossref missing$
    { format.bvolume output
      format.number.series output
      format.publisher.address output
    }
    {
      format.book.crossref output.nonnull
      format.date "year" output.check
    }
  if$
  format.edition output
  new.sentence
  format.note output
  fin.entry
}

Still hope someone will be kind enough to assist, as I would prefer not to attach a { } at the end of every publisher field in my bib entries to force a space between the publisher and the year.

Troy
  • 13,741
  • 1
    Since you are not using biblatex but traditional BibTeX (.bst) styles, I hare retagged your question. You might get more help from people if you could provide a full MWE. It could be that the problem comes from your .bib entry. – moewe Dec 27 '16 at 07:05
  • @moewe Okay, already uploaded a MWE, thanks. If there is a way to upload mystdbst_v2, I would do it as well. – Troy Dec 27 '16 at 07:26
  • Thank you. If the sequence of commands from above is sufficient to recreate your mystdbst_v2.bst that should be fine. But if your file is a bit different because you have already modified it, you should find a way to show it to us. Unfortunately, you can't upload files here, so you will have to find another way. – moewe Dec 27 '16 at 07:33
  • @moewe Great. In that case, the options above should reflect what I have on my mystdbst_v2.bst file. I don't believe further changes were made to the bst file. – Troy Dec 27 '16 at 07:36
  • Is there any news here? – Johannes_B Jul 30 '17 at 13:59
  • @Johannes_B Thanks for reminding me about this. It's a duplicate of another question, (though it doesn't look like it), but the solution and source of the problem is exactly the same. – Troy Jul 30 '17 at 14:19
  • @Troy Good, another question is off the unanswered list :-) – Johannes_B Jul 30 '17 at 14:22

0 Answers0