Skip to content
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: Update version of citation files with use_version #2081

Closed
roaldarbol opened this issue Nov 13, 2024 · 3 comments
Closed

Feature request: Update version of citation files with use_version #2081

roaldarbol opened this issue Nov 13, 2024 · 3 comments

Comments

@roaldarbol
Copy link

use_version is super convenient for updating the the version in both DESCRIPTION and NEWS.md, however, one still has to manually edit the inst/CITATION (and CITATION.cff) file(s). It would be great it use_version could check whether such file(s) were present, and if they are, update the version within them.

@jennybc
Copy link
Member

jennybc commented Jan 31, 2025

I just did a GitHub search for inst/CITATION files and the diversity of what I'm seeing in these files suggests this is not really amenable to automation.

If your own practices are consistent enough that you think this could be automated for your packages, it sounds like a good fit for a custom release bullet:

https://usethis.r-lib.org/reference/use_release_issue.html

If you want to consistently add extra bullets for every release, you can include your own custom bullets by providing an (unexported) release_bullets() function that returns a character vector. (For historical reasons, release_questions() is also supported).

@jennybc jennybc closed this as completed Jan 31, 2025
@roaldarbol
Copy link
Author

Is there any more documentation of the function? It sounds like it's just an issue that's generated, not an action that updates files - am I understanding that wrong?

It can definitely be automated, cffr does it; maybe it could be a parameter that defaults to FALSE?

@jennybc
Copy link
Member

jennybc commented Feb 3, 2025

There's not a lot of documentation around the custom release bullets and, yes, it's a reminder to update something, not an automation of it. The best way to see examples of it would be to do a GitHub search of CRAN packages for release_bullets in the R directory.

I'm guessing that cffr can assume certain practices in the CITATION file, which then makes those files predictable and more favorable for automatic editing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@jennybc @roaldarbol and others