In the context of what is essentially publication list, I call the following macro:
\newcommand{\makeauthorbold}[1]{%
\DeclareNameFormat{author}{%
\ifthenelse{\value{listcount}=1}
{%
{\expandafter\ifstrequal\expandafter{\namepartfamily}{#1}{\mkbibbold{\namepartfamily\addcomma\addspace \namepartgiveni}}{\namepartfamily\addcomma\addspace \namepartgiveni}}
%
}{\ifnumless{\value{listcount}}{\value{liststop}}
{\expandafter\ifstrequal\expandafter{\namepartfamily}{#1}{\mkbibbold{\addcomma\addspace \namepartfamily\addcomma\addspace \namepartgiveni}}{\addcomma\addspace \namepartfamily\addcomma\addspace \namepartgiveni}}
{\expandafter\ifstrequal\expandafter{\namepartfamily}{#1}{\mkbibbold{\addcomma\addspace \namepartfamily\addcomma\addspace \namepartgiveni\addcomma\isdot}}{\addcomma\addspace \namepartfamily\addcomma\addspace \namepartgiveni\addcomma\isdot}}%
}
\ifthenelse{\value{listcount}<\value{liststop}}
{\addcomma\space}
}
}
which is stored externally in a .tex, referenced in the preamble via \input{<file name>}, and called in the document body by:
\makeauthorbold{<author last name>}
In the publication list, which is actually multiple publication list (imagine one for every member of a working group) the bibliogrpahy is printed in the following way
% point to member a publication list
\newcommand\bibnamea{.../member_a.bib}
% add bib resource and define section title / heading
\addbibresource{\bibnamea}%
\def\sectiona{Member a publications}%
% print publication list for member a
\begin{numberedpublist}{\sectiona}{\bibnamea}{keyword={<keyword(s) to help filter>}}%
\end{numberedpublist}%
where the numberedpublist environment is defined as follows
% define an environment for a numbered publication list
\newenvironment{numberedpublist}[3]
{%
\section*{#1}%
\begin{refsection}[#2]%
\nocite{*}%
\printbibliography[heading=none,env=bibenvnumberedpublist,#3]%
\end{refsection}%
}%
{}%
which also has a corresponding bibenvironment definition given the name `bibenvnumberedpublist' (omitting for sake of simplicity).
One ends up with an environment with 3 arguments: the bib resource, the heading, and any keywords you want the bib items to possess in order for them to be qualified for display. By using the \nocite*{}, one does not have to deal with any bibtexkeys; all entries possessing the right keywords are printed.
The issue is that for some reason, the \makeauthorbold{} call leads to an error such as:
\begin{refsection} on input line 999 ended by \end{numberedpublist}
When I don't use \makeauthorbold{}, no issue. My guesses are the following:
The
\makeauthorbold{}could stand to be made more robust.The way I'm mixing the
numberedpublistenvironment definition,\refsectionand possibly\sectionis wacky.
bibenvnumberedpublistwasn't defined). An MWE makes it much easier for people to get started helping you. An MWE is also the best tool to make sure that we are all talking about the same thing. – moewe Jul 15 '19 at 05:12numberedpublistwould be an environment. The same should be doable with a normal macro. – moewe Jul 15 '19 at 05:16