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
override tex-file without asking #1123
Comments
|
Sorry to hear about that. It is the first time over the four years of knitr's history that I have heard about it, though. I guess it would be too much trouble if knitr asks every single time before it writes the output file. It cannot tell if a foo.tex is the output of foo.Rnw or just a completely different tex file. I understand it was a very expensive lesson for you to learn (don't name two files with the same base filename if they are supposed to be different files after all), but I guess there isn't much I can do here. Sorry. |
|
You as the dev have a lot of options:
Me as a developer I would never implement such an unpolite behaviour in one of my programms. |
|
The documentation
foo.tex is the output of foo.Rnw, and users are supposed to work with (and only with) the source document foo.Rnw. I think the vast majority of users start with foo.Rnw, and you happen to have started backwards on this way. It is so rare, but I agree it is unfortunate and super annoying when it happens. I'm not sure if this is an appropriate analogy: one can do Let's try not to bring politeness into the argument. It is hard to continue the discussion when we start evaluating morality of other people. I may well say it is not polite to blame the author after calling a command when you don't understand its consequence, but that is meaningless and does nobody any favors. Yes, I can add the options you mentioned, and they make a lot of sense to this specific case. The question is how much weight I should put on this case. I tend to believe I do not need to change the default behavior. I understand it does not appear to be fair from your point of view. Again, sorry about your loss of hours of work. |
|
I see your point and of course you can close this bug-report without fixing it because you are the maintainer. And I see that my solutions of this bug are against the knitr-concept.
|
|
I would have to disagree here. Having worked with |
|
I was not comparing |
|
The knitr-manual is only 11 pages with a toc. And with a string search I can not find "Rtex" in there. Where can I read something official about "Rtex" and how this can work? |
|
I don't think Rtex is widely used (most people use Rmd or Rnw). A google search of Anyway, Rtex is just different in the syntax of writing R code chunks. It does not prevent your tex file from being overwritten, either. |
|
I wonder what |
|
Closing this issue since this is by design (you go from .Rnw to .tex; not the other way around). Sorry. |
|
This old thread has been automatically locked. If you think you have found something related to this, please open a new issue by following the issue guide (https://yihui.org/issue/), and link to this old issue if necessary. |
I tested something around and used that line to generate the tex-file
But the problem is that
myfile.texwas still there and it was a very nice weeks of work document that is now overriden. There was no error no warning.Of course I have backups but I lost some hours of work.
The text was updated successfully, but these errors were encountered: