flo
October 26, 2024, 6:31pm
1
Hello everyone,
I am using the push command to push my selected source from JabRef to Texstudio.
I have configured the command to push “\autocite[nach][Seite X]{key1,key2}”.
This has worked some months ago but today he always push it wrong as: “\cite{\autocite[nach][Seite X]{Schmith2019}}.”
How to get \cite{ } around my command away?
Thanks!
@flo Which version of JabRef are you using and have you checked your settings?
Did you recently update JabRef?
flo
October 29, 2024, 11:08pm
3
Hi, these are my version information:
JabRef 5.15–2024-07-10–1eb3493
Windows 11 10.0 amd64
Java 21.0.2
JavaFX 22.0.1+7
I think I have updated it.
The settings are correct: \autocite[nach][Seite X]{key1,key2} The result not.
koppor
(Oliver Kopp)
October 30, 2024, 7:18pm
4
I can confirm that it does not work with 5.15 and TeXstudio 4.8.1 (git 4.8.1).
Which of these two tools did you update? JabRef or TeXstudio?
I tried with JabRef 5.14 and JabRef 5.15 with TeXstudio 4.8.1. Did not work.
JabRef 5.14 and TeXsutio 4.8.4 does not work.
JabRef 5.9 and TeXsutio 4.8.4 does not work.
I tried with the development version.
Setting \cite{key1,key2}: works both plain (as new \cite) and adding to an existing \cite
Setting \autocite{key1,key2} works plain
Setting \autocite[nach][Seite X]{key1,key2} does not work.
flo
October 30, 2024, 10:54pm
5
Great finding that my special way of citing is not working. Thanks! I confirm your observation.
I have updated for sure TeXstudio but I believe, JabRef, too. I do not believe it is a problem of TeXstudio because this function looks for my like a copy and paste or autotyping function. TeXstudio is not using any intelligence to process this command. But maybe it does. We might see it in the source code of JabRef how JabRef is addressing TeXstudio. Is it visible in the source code?
koppor
(Oliver Kopp)
November 2, 2024, 1:09pm
7
@flo What Christoph meant: It would help if you yould open a cmd.exe and execute the --insert-cite
command manually and check whether it works.
It should be --insert-cite \autocite[nach][Seite X]{key1,key2}
.
I tried it
"C:\Program Files\texstudio\texstudio.exe" --insert-cite "\autocite[nach][Seite X]{key1,key2}"
Result:
\cite{\autocite[nach][Seite X]{key1,key2}}
I checked
https://htmlpreview.github.io/?https://github.com/texstudio-org/texstudio/master/utilities/manual/usermanual_en.html
"C:\Program Files\texstudio\texstudio.exe" --insert-cite "\mycite{key2}"
Works
"C:\Program Files\texstudio\texstudio.exe" --insert-cite "\mycite[nach]{key2}"
Does not.
Thus, please, open an issue at issue tracker of TeXStudio (Issues · texstudio-org/texstudio · GitHub ).
I searched for “–insert-cite” there - and no relevent issues popped up.
flo
November 3, 2024, 12:02am
8
Hi, ok, CMD is the same situation. Then it might be a problem of TeXstudio?
1 Like
Siedlerchr
(Christoph)
November 3, 2024, 10:24am
9
It might be related to the square brackets, they need to be escaped as well at least this would explain it:
[ \[
] \]
https://www.robvanderwoude.com/escapechars.php
Can you try this on the command line?
@koppor
koppor
(Oliver Kopp)
November 3, 2024, 11:28am
10
@Siedlerchr You mean
"C:\Program Files\texstudio\texstudio.exe" --insert-cite "\mycite\[nach\]{key2}"
Result:
\cite{\mycite\[nach\]{key2}}