Skip to content

Commit

Permalink
Fix previous commit so it is backwards compatible. See the comments i…
Browse files Browse the repository at this point in the history
…n the code changed

* Add SR isbn_french and isbn_cat_no
* Finally figured out how to do an if statement for existence of a
YAML tag in the Latex tex template
  • Loading branch information
cgrandin committed Sep 24, 2024
1 parent 61c2f15 commit 9a9f4e7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions inst/csas-tex/res-doc-french.tex
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,10 @@
% Title
\newcommand{\rdTitle}{$title$}

\newcommand{\rdISBN}{$isbn_french$}
\newcommand{\rdCatNo}{$cat_no_french$}
% Use isbn_french and cat_no_french if they exist, if they don't use isbn and cat_no
% This preserves backwards compatibility for those without the french tags
\newcommand{\rdISBN}{\ifx&$isbn_french$& $isbn$ \else $isbn_french$ \fi}
\newcommand{\rdCatNo}{\ifx&$cat_no_french$& $cat_no$ \else $cat_no_french$ \fi}

% Author names separated by commas and ', and' for the last author in the format 'M.H. Grinnell' (use \textsuperscript{n} for addresses)
\newcommand{\rdAuth}{$author$}
Expand Down
6 changes: 4 additions & 2 deletions inst/csas-tex/sr-french.tex
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,10 @@
% Region
\newcommand{\rdRegion}{$region$}

\newcommand{\rdISBN}{$isbn$}
\newcommand{\rdCatNo}{$cat_no$}
% Use isbn_french and cat_no_french if they exist, if they don't use isbn and cat_no
% This preserves backwards compatibility for those without the french tags
\newcommand{\rdISBN}{\ifx&$isbn_french$& $isbn$ \else $isbn_french$ \fi}
\newcommand{\rdCatNo}{\ifx&$cat_no_french$& $cat_no$ \else $cat_no_french$ \fi}

%%%% End of title page commands %%%%%

Expand Down

0 comments on commit 9a9f4e7

Please sign in to comment.