-
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
Feature request: Automated generation of inst/CITATION
#79
Comments
Hello! Just seconding that this would be really handy :) |
Hi: I still have to think about it, since the main purpose of cffr is to provide tools for aa <- cffr::cff_create()
cffr::cff_write(aa)
unlink("inst/CITATION") # Remove already present file
cffr::cff_write_citation(aa, file = "inst/CITATION") And in a github action (see example): - name: Update CITATION.cff
run: |
# Customize with your own code
# See https://docs.ropensci.org/cffr/articles/cffr.html
# Write your own keys
mykeys <- list()
# The object
cffobj <- cffr::cff_create(keys = mykeys)
# Create your CITATION.cff file
cffr::cff_write(cffobj)
# Update inst/CITATION
unlink("inst/CITATION")
cffr::cff_write_citation(cffobj, file = "inst/CITATION")
shell: Rscript {0} |
Ideally, I would also prefer this to be handled by usethis (see r-lib/usethis#2081), as I see that package as one that takes care of package development as a whole. I guess the argument for implementing something like this is that the current state adds friction because it adds extra work for devs having to curate package version in 4 places now ( |
It would be great to have the option to only maintain the
DESCRIPTION
file and then both theCITATION.cff
and theinst/CITATION
files being updated as part of the workflow. As far as I can tell, one will manually have to re-createinst/CITATION
every time theCITATION.cff
file is updated. Maybe it is already possible, in which case ignore this.Also, along the same lines, it might be helpful having an example of the automated generation solutions in the docs. :-)
The text was updated successfully, but these errors were encountered: