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

docs: Add CITATION.cff Citation File Format file #243

Merged
merged 1 commit into from
Aug 29, 2022

Conversation

matthewfeickert
Copy link
Member

Resolves #238

Add Citation File Format file to repo to get repository cite button on GitHub and citation support on Zenodo.

The schema used is validated by cffconvert

$ pipx install cffconvert
$ cffconvert --validate --infile CITATION.cff 
Citation metadata are valid according to schema version 1.2.0.

@matthewfeickert matthewfeickert added the docs Improvements or additions to documentation label Aug 17, 2022
@matthewfeickert matthewfeickert self-assigned this Aug 17, 2022
@matthewfeickert
Copy link
Member Author

In scikit-hep/hist#416 the CITATION.cff had to be excluded from the MANIFEST.in, but I don't know if anything like that needs to be done with hatchling.

@matthewfeickert
Copy link
Member Author

Small reminder ping to @henryiii @jpivarski.

CITATION.cff Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Aug 24, 2022

Codecov Report

Merging #243 (a936cc7) into main (b4531ed) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #243   +/-   ##
=======================================
  Coverage   82.63%   82.63%           
=======================================
  Files          96       96           
  Lines       10524    10524           
=======================================
  Hits         8697     8697           
  Misses       1827     1827           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@henryiii
Copy link
Member

the CITATION.cff had to be excluded from the MANIFEST.in

It should be in the SDist by default but not the wheel. Don't see harm in having it in the SDist, though it could be manually excluded if we want to. It's tool.hatch.sdist.exclude or something of that sort.

@Saransh-cpp
Copy link
Member

It's tool.hatch.sdist.exclude or something of that sort.

[tool.hatch.build.targets.sdist]
exclude = [
  "./CITATION.cff"
]

should work!

https://hatch.pypa.io/latest/build/#configuration

* Add Citation File Format file to repo to get repository cite button on GitHub
and citation support on Zenodo.
   - c.f. https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/creating-a-repository-on-github/about-citation-files
@matthewfeickert matthewfeickert force-pushed the docs/add-citation-cff branch 2 times, most recently from a936cc7 to f3800e1 Compare August 25, 2022 05:43
@matthewfeickert
Copy link
Member Author

While

[tool.hatch.build.targets.sdist]
exclude = [
  "/CITATION.cff"
]

does work to ignore it from the sdist

$ python -m build . && python -m tarfile --list dist/*.tar.gz | grep "CITATION.cff"
$ echo $?
1

I see that vector isn't ignoring any other files in the repo, and so for a single text file I don't think it is worth it to ignore the CITATION.cff. So I'll just leave this PR as adding the CITATION.cff only.

This should be ready for review from the 3 of you now.

@matthewfeickert
Copy link
Member Author

As 2 of the authors have approved this I'm going to merge this.

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

Successfully merging this pull request may close these issues.

Add CITATION.cff file
5 participants