-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changed \newcommand for \providecommand to avoid problems with latex-… #3
base: master
Are you sure you want to change the base?
Conversation
Hallo @susuhahnml , I guess it's a reasonable fix but perhaps its time do redesign our macros rather than patching them. |
It might actually be better to see that there is a redefinition. Because the name clash might be due to completely different commands. next is also a pretty generic name. Maybe temporalnext or similar might be better to avoid clashes. I also tend to start commands with an upper case letter. This avoids clashes with a lot of packages. One can also manually workaround such issues with Edit: Here some reference: https://tex.stackexchange.com/questions/18541/two-conflicting-packages-in-one-document-doable. |
After reading the stackexchange, I would prefer name clashes and fixes rather than an implicit solution. However, adding BTW, this is not the only clash, viz |
Have you tried EDIT: The etoolbox package also has an |
Yes, this was even my first choice 😞
Yeah, but this would buy me another package |
After all, it might be easier to offer all these commands via |
Just be aware that you won't be able to use them if you use the "wrong" packages. Better rename the commands instead of using |
I guess, we had to look at our macros as convenience packages and also load them last |
I would not do it like this. But it's your project... 😄 |
We could use the prefix |
Well I just checked we offer 233 macros, and renaming them all would need a unique prefix like potassco or whatever |
I would do exactly this. Since you are using submodules, you can just do it. It won't break any existing projects. |
I think the prefix would have been good at the start, but right now ` \providecomand` would be a fix whitout breaking existing projects. I also agree that it can cause some hidden errors due to a redefinition we won’t be aware of… But I guess we cant have it all.
Since the clash was with `\next` it took me longer to find it because I was blaming the tikz library as well, but when the class changed it worked. I guess tikz also uses something like` \providecomand` to avoid this issue with this common command and that is why we needed to load our `dtel` as-macro before since it currently uses `\newcomand`.
… On 11. Jul 2021, at 03:33, Roland Kaminski ***@***.***> wrote:
Just be aware that you won't be able to use them if you use the "wrong" packages. Better rename the commands instead of using \providecomand.
Well I just checked we offer 233 macros, and renaming them all would need a unique prefix like potassco or whatever
Hnce I'd sitll go for \providecommand as we do in comments.sty already
I would do exactly this. Since you are using submodules, you can just do it. It won't break any existing projects.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Here is one workaround. I also tried to patch the \documentclass{ceurart}
\let\oldnext\next
\let\next\undefined
\include{dtel}
\let\ASPnext\next
\let\next\oldnext
\begin{document}
\begin{itemize}
\item \(\ASPnext\) test1
\item test2
\end{itemize}
\end{document} |
This fixes the clash, with |
Sorry, I always mix this up when writing things from scratch. It has to be PS: Since the macros only contain commands, they could actually become a style. |
…class-ceurart