Closed ikashnitsky closed 5 years ago
Hm. Interesting. I guess right now we only have Author, Title, Affiliation. I am sure something can be worked out -- similarly we could offer an override text for 'This version ...'. Do you want to try to work out a PR?
I will try. ~Can you give me a hint where to dig?~
Ok, got it: ...\pinp\inst\rmarkdown\templates\pdf\resources\template.tex
Ah. Sorry. Was/am tied up. That is one of two steps, the other is how to pick up a value from YAML and pass it down to the template. You may be able to infer how it's done (and I have three related markdown packages so you could search in all three).
Yes, the implementation (maybe very crude one) of a custom "This version..." line was easy. Basically, I followed the suggestion from @coatless, provided in a comment here #60.
in ...\pinp\inst\rmarkdown\templates\pdf\resources\template.tex
I changed the line 64 for
$if(infoline)$
\dates{$infoline$}
$else$
\dates{This version was compiled on \today}
$endif$
Any preferences for the name of the YAML option (infoline) if I PR?
I cannot figure out where to specify the compilation date that goes in the running footer. I guess, it sits somewhere in \pinpfootercontents
@ikashnitsky feel free to submit a PR for infoline
change. Please include the new YAML key under options
in the pinp
vignette. c.f. https://github.com/eddelbuettel/pinp/blob/master/vignettes/pinp.Rmd#L157
Yes, infoline
is a bad name. "vintage"? "compilationdate"? "productiondate"? "datestamp"? "datefooter"?
How about subtitle_date
?
I make this suggestion since it isn't influencing the date in the footer. Plus, we already have footer_contents
. (hence the _
)
Uggh. Evil underscores. Is date_subtitle
better?
Uggh. Evil underscores. Is
date_subtitle
better?
I'll use date_subtitle
then, will PR soon.
I haven't found the solution for the footer date yet
I haven't found the solution for the footer date yet
I have vague memories of hardcoding this / thinking it works like watermark: "built on x-y-z". I am sure we can generalize if need be. One brick at a time.
Fixed in #64.
Hi! It's me again =) How about allowing a custom date in the footer? My use case is compiling the PhD thesis book, and it would be nice to set the footer date to the planned date of the defense. What do you think @eddelbuettel @coatless?
Could do though I am a little wary that pinp
already converges towards "too many options". Isn't the field on the lower left (of dual pages) already free form as a generalization of the DOI/URI/... ?
That's a very valid concern. But it seems there is no way of removing the footer date, in order to provide a custom date in the DOI/URL field
Now, your dissertation is a one-off. How about you locally fork pinp
and do what you need to do?
Otherwise, if you have the urge to spend time on this, maybe a new option to be used if set and otherwise the current date format comes back in?
Yes, the behaviour that you outlined sounds perfect. I'll try to implement it.
A more general use case: for pre/post-prints set the date of the actual publication
Yep, that's a good feature to have.
It would be very useful to have an option to set the date of the document (running in the footer throughout the document) rather than hard-coded default of
\today
. It seems that {pinp} ingnoresdate: "..."
in YAML.Also, it seems very nice to use custom text for the line "This version was compiled on ...". One use case that I see super attractive is to give full bibliographic info for the published post-prints. Any ideas?