| 1 | ## The Problem Being Solved |
| 2 | |
| 3 | Some journals accept the reference list only as `\bibitem`s. |
| 4 | If you use BibTeX, there is no problem: |
| 5 | just paste the content of the `.bbl` file into your document. |
| 6 | However, there were no out-of-the-box way to do the same for `biblatex`, |
| 7 | and you had to struggle with searching appropriate `.bst` files, |
| 8 | or formatting your reference list by hand, |
| 9 | or something like that. |
| 10 | |
| 11 | Now you haven't to. |
| 12 | |
| 13 | ## Usage |
| 14 | In preamble, after the `biblatex` package is loaded via `\usepackage[...]{biblatex}`: |
| 15 | ```latex |
| 16 | \usepackage{biblatex2bibitem} |
| 17 | ``` |
| 18 | |
| 19 | At the very end of document: |
| 20 | ```latex |
| 21 | \printbibitembibliography |
| 22 | ``` |
| 23 | |
| 24 | The desired `bibitem`s will be written directly to the PDF file. |
| 25 | |
| 26 | When it's time to switch to `bibitem`s (e.g. before sending the paper to the journal), |
| 27 | just copy them directly from the pdf into your `.tex` file, remove |
| 28 | `biblatex` commands and (probably) load the `cite` package. |
| 29 | |
| 30 | ### Disclaimer |
| 31 | |
| 32 | This package itself is a hack. |
| 33 | Moreover, it is (as for 02 March 2020) under rather an active development. |
| 34 | New features may appear and disappear, and the API may be unstable. |
| 35 | Thus, you may want to download `biblatex2bibitem.sty` and keep it near your article |
| 36 | instead of (or in addition to) having installing it system-wide. |
| 37 | |
| 38 | ## Tips |
| 39 | |
| 40 | ### Linebreaks in generated bibliography |
| 41 | |
| 42 | You can pass `block=par` option to `biblatex` like that: |
| 43 | |
| 44 | ```latex |
| 45 | \usepackage[block=par,...]{biblatex} |
| 46 | ``` |
| 47 | but not like that (see also https://github.com/plk/biblatex/issues/968): |
| 48 | ```latex |
| 49 | \printbibliography[block=par,env=bibitembibliography] |
| 50 | ``` |
| 51 | |
| 52 | It will add linebreaks in generated `bibitem`s and make the code a bit more beautiful :) |
| 53 | |
| 54 | ### (Un)desired spaces |
| 55 | |
| 56 | If you really want to have a space after the title of an e.g. an article, just |
| 57 | ```latex |
| 58 | \renewcommand{\ignorespacesaftertitlecase}{} |
| 59 | ``` |
| 60 | |
| 61 | ### `bibitem` separators |
| 62 | |
| 63 | By default, generated `bibitem`s are separated by a line with an empty pair of curly braces on it to make the reading of the code easier. |
| 64 | You can tweak this by e.g. |
| 65 | ```latex |
| 66 | \renewcommand{\printgeneratedbibitemseparator}{\ttfamily\{\}\\} |
| 67 | ``` |
| 68 | (for putting all the `bibitem`s into monotype font) or e.g. |
| 69 | ```latex |
| 70 | \renewcommand{\printgeneratedbibitemseparator}{} |
| 71 | ``` |
| 72 | (for disabling "blank" lines but not linebreaks when copying). |
| 73 | |
| 74 | ### Other redefinable commands |
| 75 | |
| 76 | Don't forget about `\makeatletter` and `\makeatother`! |
| 77 | |
| 78 | + `\print@begin@thebibliography` - default: `\textbackslash begin\{thebibliography\}\{99\}` |
| 79 | |
| 80 | + `\print@end@thebibliography` - default: `\textbackslash end\{thebibliography\} ` |
| 81 | |
| 82 | + `\print@bibitem@command` - default: `\textbackslash bibitem` |
| 83 | |
| 84 | ## See also |
| 85 | |
| 86 | + https://github.com/plk/biblatex/issues/783 |
| 87 | |
| 88 | + https://github.com/plk/biblatex/issues/292 |
| 89 | |
| 90 | + https://tex.stackexchange.com/questions/12175/biblatex-submitting-to-a-journal (a hopeless discussion) |
| 91 | |
| 92 | + https://github.com/odomanov/biblatex-gost/issues/20 (in Russian) |
| 93 | |
| 94 | ## Repostories |
| 95 | |
| 96 | + [CTAN](https://ctan.org/pkg/biblatex2bibitem) |
| 97 | |
| 98 | + [GitLab](https://gitlab.com/Nickkolok/biblatex2bibitem) |
| 99 | |
| 100 | ## License |
| 101 | |
| 102 | LPPL - LaTeX Project Public License v1.3c+, DFSG compat. |
| 103 | |
| 104 | ## Authors |
| 105 | |
| 106 | + Nikolai Avdeev aka @nickkolok |
| 107 | |
| 108 | + [@odomanov](https://github.com/odomanov/) |