Skip to content
Snippets Groups Projects
Commit c7f56306 authored by Vuillaume's avatar Vuillaume
Browse files

Merge branch 'vuillaume-master-patch-63650' into 'master'

Update documentation about GitHub-Zenodo integration and testing zenodo file

See merge request !189
parents 697aa34e d987535d
No related branches found
No related tags found
1 merge request!189Update documentation about GitHub-Zenodo integration and testing zenodo file
Pipeline #169588 passed with warnings
...@@ -47,10 +47,17 @@ test_codemeta_ingestion: ...@@ -47,10 +47,17 @@ test_codemeta_ingestion:
## GitHub ## GitHub
If you are hosting your developments on GitHub, you will need to convert your `codemeta.json` file If you are hosting your developments on GitHub, you are probably using [the GitHub-Zenodo integration](https://docs.github.com/en/repositories/archiving-a-github-repository/referencing-and-citing-content) to upload your code to Zenodo when making a GitHub release.
to a `.zenodo.json` using [the `ossr-codemeta2zenodo` CLI](../docstring_sources/eossr_cli/eossr-codemeta2zenodo) to be able to use
[the GitHub-Zenodo integration](https://docs.github.com/en/repositories/archiving-a-github-repository/referencing-and-citing-content).
The GitHub-Zenodo integration can use three sources for its metadata:
1. GitHub - if no other source of metadata exist, information such as release title and notes, versioning, contributors, etc... will be provided by GitHub metadata. Metadata from former releases or edited on the Zenodo web portal are **updated**.
2. `CITATION.cff` - if a `CITATION.cff` file lives at the root of your repository, it will be used by Zenodo to **update** existing metadata (from a former release or from GitHub)
3. `.zenodo.json` - if a `.zenodo.json` file lives at the root of your repository, it will be used by Zenodo as **unique** source of metadata and will **replace** all existing metadata
In order to have a unique source of metadata for your project and depending on your workflow, you _might_ want to to convert your `codemeta.json` file to a `.zenodo.json` file before releases using [the `ossr-codemeta2zenodo` CLI](../docstring_sources/eossr_cli/eossr-codemeta2zenodo).
### Test your `.zenodo.json` file
First, you will need to: First, you will need to:
- [create an access token in Zenodo](https://zenodo.org/account/settings/applications/tokens/new/) - [create an access token in Zenodo](https://zenodo.org/account/settings/applications/tokens/new/)
...@@ -58,11 +65,8 @@ First, you will need to: ...@@ -58,11 +65,8 @@ First, you will need to:
- add it to [your repository secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets) - add it to [your repository secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets)
under the name `ZENODO_TOKEN`. under the name `ZENODO_TOKEN`.
Then, you can use the following GitHub action snippet to check the validity of your `.zenodo.json` file: Then, you can use the following GitHub action snippet to check the validity of your `.zenodo.json` file.
To do so, add this code snippet in a file `.github/workflows/check_zenodo.yml` in your repository:
### Test your `.zenodo.json` file
Add this code snippet in a file `.github/workflows/check_zenodo.yml` in your repository:
```yaml ```yaml
name: check zenodo name: check zenodo
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment