You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you happen to work on a Python project and use a `pyproject.toml`, you can also put this information there and avoid having another separate file. In that case, simply prepend `tool.somesy` to the names of all sections (i.e. `[project]` becomes `[tool.somesy.project]`).
61
+
To get started, create a file named `somesy.toml`:
62
+
63
+
<!-- --8<-- [start:somesytoml] -->
64
+
```toml
65
+
[project]
66
+
name = "my-amazing-project"
67
+
version = "0.1.0"
68
+
description = "Brief description of my amazing software."
author = true# is a full author of the project (i.e. appears in citations)
81
+
maintainer = true# currently maintains the project (i.e. is a contact person)
82
+
83
+
# this person is a acknowledged contributor, but not author or maintainer:
84
+
[[project.people]]
85
+
given-names = "Another"
86
+
family-names = "Contributor"
87
+
email = "a.contributor@example.com"
88
+
orcid = "https://orcid.org/0000-0000-0000-0002"
89
+
90
+
[config]
91
+
verbose = true# show detailed information about what somesy is doing
92
+
```
93
+
<!-- --8<-- [end:somesytoml] -->
94
+
95
+
Alternatively, you can also add the somesy configuration to an existing
96
+
`pyproject.toml` or `package.json` file. The somesy [manual](https://materials-data-science-and-informatics.github.io/somesy/main/manual/#somesy-input-file) contains examples showing how to do that.
172
97
173
98
### Using somesy
174
99
@@ -189,7 +114,9 @@ By default, `somesy` will create (if they did not exist) or update `CITATION.cff
189
114
You can see call available options with `somesy --help`,
190
115
all of these can also be conveniently set in your `somesy.toml` file.
191
116
192
-
### Setting up somesy as a pre-commit hook
117
+
### Somesy as a pre-commit hook
118
+
119
+
<!-- --8<-- [start:precommit] -->
193
120
194
121
We highly recommend to use `somesy` as a [pre-commit hook](https://pre-commit.com/).
195
122
A pre-commit hook runs on every commit to automatically point out issues or fix them on the spot,
@@ -215,25 +142,26 @@ so when using `somesy` with pre-commit, keep in mind that
215
142
* if `somesy` changed some files, you need to `git add` them again (and rerun pre-commit)
216
143
* if you explicitly run `pre-commit`, make sure to `git add` all changed files (just like before a commit)
217
144
145
+
<!-- --8<-- [end:precommit] -->
146
+
218
147
## Supported File Formats
219
148
220
149
Here is an overview of all the currently supported files and formats.
221
150
222
151
| Input Formats | Status | | Target Formats | Status |
1. information must be placed inside a `tool.somesy` section (as explained above)
234
162
2. note that `somesy` does not support setuptools *dynamic fields*
235
-
3. `package.json` author field allows only one author information. Therefore, somesy sets the first person with author field, in the people definition, as the author.
236
-
4. unlike other targets, `somesy` will *re-create* the `codemeta.json` (i.e. you should not edit it by hand!)
163
+
3. `package.json` only supports one author, so `somesy` will pick the *first* listed author
164
+
4. unlike other targets, `somesy` will *re-create* the `codemeta.json` (i.e. do not edit it by hand!)
0 commit comments