Only define plural acronym if command is not defined yet

This commit is contained in:
2024-08-12 09:54:48 +02:00
parent e825f5518b
commit e8e9f61251
2 changed files with 3 additions and 3 deletions

View File

@@ -27,7 +27,7 @@
\expandafter\newcommand\csname #1\endcsname{% Create a command named after the acronym (call \#1) \expandafter\newcommand\csname #1\endcsname{% Create a command named after the acronym (call \#1)
\gls{#1}\xspace% \gls{#1}\xspace%
}% }%
\expandafter\newcommand\csname #1s\endcsname{% \expandafter\providecommand\csname #1s\endcsname{% Create a plural command (call \#1s) if not already defined
\glspl{#1}\xspace% \glspl{#1}\xspace%
}% }%
} }

View File

@@ -21,12 +21,12 @@
pdfkeywords = {}, pdfkeywords = {},
} }
\input{config/acronyms}
% Custom commands % Custom commands
\input{utils/commands} \input{utils/commands}
\input{config/thesis_commands} \input{config/thesis_commands}
\input{config/acronyms}
% Full or partial compilation % Full or partial compilation
\newcommand{\importcover}[2]{\import{#1}{#2}} \newcommand{\importcover}[2]{\import{#1}{#2}}
\iftrue \iftrue