# \renewcommand being ignored when babel is loaded [duplicate]

my Problem is, as will be shown in the following 2 MWEs, that the custom column names i specified for my glossary, will be overwritten when babel ist loaded. The associated .bib file can be found at the end.

How can i prevent this behaviour? I already treid altering the position of the \renewcommand prompts.

\documentclass[english, a4paper, 11pt, DIV=calc, headsepline, titlepage, bibliography=totocnumbered]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{siunitx}
\usepackage[record, abbreviations, symbols, nonumberlist, hyperfirst=false, toc=false, stylemods={longextra}]{glossaries-extra}

src={bibfiles/symbols}, % data in symbols.bib
sort-field={name}, % sort by name field
sort={letter-nocase}, % case-insensitive letter sort
type=symbols, % put these terms in the symbols list
field-aliases={unit=symbol},% convert unit key to symbol
save-locations=false % don't save location lists
]
\renewcommand{\entryname}{Symbol}
\renewcommand{\symbolname}{Unit}
\renewcommand{\glslongextraSymbolAlign}{l}

\begin{document}

\printunsrtglossary[type=symbols, style={long-name-sym-desc}]

\end{document}


The result is exactly how i want it to be:

Now when babel is activated as so:

\documentclass[english, a4paper, 11pt, DIV=calc, headsepline, titlepage, bibliography=totocnumbered]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{siunitx}
\usepackage[record, abbreviations, symbols, nonumberlist, hyperfirst=false, toc=false, stylemods={longextra}]{glossaries-extra}

src={bibfiles/symbols}, % data in symbols.bib
sort-field={name}, % sort by name field
sort={letter-nocase}, % case-insensitive letter sort
type=symbols, % put these terms in the symbols list
field-aliases={unit=symbol},% convert unit key to symbol
save-locations=false % don't save location lists
]
\renewcommand{\entryname}{Symbol}
\renewcommand{\symbolname}{Unit}
\renewcommand{\glslongextraSymbolAlign}{l}

\begin{document}

\printunsrtglossary[type=symbols, style={long-name-sym-desc}]

\end{document}


i will get the following:

Associated bib file:

% Encoding: UTF-8

@symbol{alpha,
name = {\ensuremath{\alpha}},
description = {angular acceleration}
}

@symbol{x,
unit = {\si{m}},
name = {\ensuremath{x}},
description = {position}
}

@symbol{v,
unit = {\si{\metre\per\second}},
name = {\ensuremath{v}},
description = {velocity}
}

@symbol{a,
unit = {\si{\metre\per\second\squared}},
name = {\ensuremath{a}},
description = {acceleration}
}

@symbol{t,
unit = {\si{s}},
name = {\ensuremath{t}},
description = {time}
}

@symbol{F,
unit = {\si{N}},
name = {\ensuremath{F}},
description = {force}
}

• babel overwrites at begin document. The proper method is to add your changes to the babel languagage via \addto\captionsenglish{ add your redefs here } Apr 8, 2021 at 13:15
• Here is a relevant example: tex.stackexchange.com/a/373816/3929 Apr 8, 2021 at 13:16
• @daleif thanks a lot, that solved the Problem for me! I wish i could find the problem myself but at least i could narrow it down to babel. Apr 8, 2021 at 14:18
• Note that it is more polite to ask a commenter to write an answer if it solved your problem. Here I'd rather mark it as a duplicate of we can find the right one. Apr 8, 2021 at 14:19