0

i found this article and gave me a huge boost in building my own custom bibliography. It looks pretty good so far, but it is not perfect for me. I need to make some changes. I read this answer and used the first code example for my bibliography. My bibliography should look like this:

And it looks like that.

Changes i need to make:

  1. Change the order of the different bibtex items

  2. Change format (no use of "", generate my own abbreviations, no use of italic style)

  3. Remove the dot at the end of each entry

    \documentclass[a4paper,12pt]{report}
    \usepackage[ngerman]{babel}
    \usepackage[utf8]{inputenc}
    

    \usepackage[backend=biber,,citestyle=authoryear,hyperref=true,autocite=inline,sortlocale=de_DE,maxnames=99]{biblatex} \addbibresource{\jobname.bib} \DeclareDelimFormat[bib,biblist]{nametitledelim}{\addcolon\space} \renewcommand{\newunitpunct}{\addcomma\space} \DeclareDelimFormat{multinamedelim}{\addsemicolon\space} \DeclareDelimAlias{finalnamedelim}{multinamedelim}

    \DeclareNameAlias{sortname}{family-given}

    \DeclareFieldFormat*{shorttitle}{\mkbibparens{#1}} \DeclareFieldFormat{url}{\url{#1}}

    \renewbibmacro*{date}{% \iffieldundef{year} {\printtext{\bibstring{nodate}}} {\printdate}}

    \makeatletter

    \usepackage{biblatex-ext-tabular}

    % sortname labels (a robust style should add provision for missing labelnames) \newbibmacro*{sortname}{% \ifnameundef{labelname} {\printtext{No name given.} \PackageWarning{biblatex}{No labelname for entry \thefield{entrykey},\MessageBreak we need to think of something else}} {\printnames[sortname]{labelname}% \iffieldequalstr{labelnamesource}{editor} {\setunit{\printdelim{editortypedelim}}% \usebibmacro{editor+othersstrg}} {\iffieldequalstr{labelnamesource}{translator} {\setunit{\printdelim{translatortypedelim}}% \usebibmacro{translator+othersstrg}} {}}}}

    \usepackage{array} \newcolumntype{L}[1]{>{\raggedright\let\newline\\arraybackslash\hspace{0pt}}p{#1}} \newcolumntype{C}[1]{>{\centering\let\newline\\arraybackslash\hspace{0pt}}p{#1}} \newcolumntype{R}[1]{>{\raggedleft\let\newline\\arraybackslash\hspace{0pt}}p{#1}}

    \usepackage{longtable} % demo new tabular bibliography format % I strongly prefer left-aligned with fixed width (L) % over justified (p) here % longtable for tables that break over pages \defbibtabular{bibtabular} {\def\arraystretch{2}% \begin{longtable}{@{}L{\dimexpr0.3\textwidth-\tabcolsep\relax}L{\dimexpr0.7\textwidth-\tabcolsep\relax}@{}}} {\end{longtable}} {\anchorlang{\usebibmacro{sortname}} & \driver{\usebibmacro{tabular:omitsortname}} \}

    \renewbibmacro{begentry}{% \printfield{shorttitle}% \printunit{\addspace}} % End Custom Bibliography

    \usepackage{filecontents}

    \begin{filecontents}{\jobname.bib} @online{testonline, title = {Titel}, subtitle = {Untertitel}, shorttitle = {Stichwort}, author = {{N}achname, {V}orname}, url = {protokoll://serveradresse/dokumentenpfad/dokument}, year = {Jahr}, urldate = {01.01.2021} note = "(Kommentar)" }

    @ARTICLE{testarticle, title = {Titel}, subtitle = {Untertitel}, shorttitle = {Stichwort}, author = {{N}achname, {V}orname}, journal = {Name der Zeitschrift}, year = {Jahr}, volume = {Band}, pages = {erste Seite - letzte Seite}, number = {Nummer}, month = {March}, publisher = {Verlag} }

    @BOOK{testbook, title = {Titel}, subtitle = {Untertitel}, shorttitle = {Stichwort}, author = {{N}achname, {V}orname}, year = {Erscheinungsjahr}, location = {Erscheinungsort}, volume = {Band}, edition = {Auflage}, year = {Jahr}, } \end{filecontents}

    \begin{document}

    \autocite{testonline} \ \textcite{testonline} \ \autocite{testarticle} \ \textcite{testarticle} \ \autocite{testbook} \ \textcite{testbook} \

    \printbibtabular \end{document}

Could you please give me some recommandations?

Thank you in advance

Cypher

Cypher
  • 1
  • I'd remove hyperref=true, the option is generally no better than the default hyperref=auto,. Both options produce links if and only if hyperref is loaded. The only difference is that hyperref=true, throws a warning if hyperref is not loaded. sortlocale=de_DE, should automatically be detected from your language settings, so need not be given explicitly. urldate = {01.01.2021} is invalid for two reasons: (1) ...date field must be filled in ISO8601 (YYYY-MM-DD) format regardless of the desired output format. ... – moewe May 17 '21 at 16:11
  • ... (2) If more fields follow this declaration, there must be a comma after the field value. urldate = {2021-01-01}, would be correct. Normally, there is no reason to add curly braces around the first letter of the family or given name of a person as in author = {{N}achname, {V}orname},. I would not do that unless there is a good reason for that (presumably to work around some quirks of the name parsing). (Generally people tend to overuse protecting braces.) – moewe May 17 '21 at 16:13
  • For question 2 see https://tex.stackexchange.com/q/462133/35864. For question 3 use \renewcommand*{\finentrypunct}{} (see https://tex.stackexchange.com/q/187443/35864). What exactly do you mean in 1. – moewe May 17 '21 at 16:22
  • Sorry. I will clarify point 1.

    It would be nice to change the order of the different bibtex items in my bibliography for the online link. It should be: (shorttitle) title, subtitle, urldate, url (comment/last visited on 2021-05-17) How can i change it?

    – Cypher May 17 '21 at 20:22
  • I have loaded hyperref in my actual document. I removed it because i didnt thought it was neccessary here. I didnt saw my mistakes in the bibfile. I fixed question 1 and 2 with your links. Thank you very much. – Cypher May 17 '21 at 21:14
  • I solved question 1. I just didn't have the right fields populated in my .bib file. – Cypher May 18 '21 at 08:38
  • If you could solve your problem, please consider posting a self answer and accepting it to show that the issue is resolved. – moewe May 18 '21 at 16:18
  • Sorry to see that your one-line answer was deleted. It would be very much appreciated if you could write a slightly more extensive answer that explains how you solved your issues. Ideally you'd just add your new code/changes to the MWE and if appropriate briefly explain how/why that works. That way your question also helps future visitors to the site. Plus if you accept your own answer, the question will be marked as answered and so people won't waste their time writing an answer to a question that is already resolved. – moewe May 26 '21 at 13:12

0 Answers0