Skip to content

Commit 0386a32

Browse files
committed
Improve naming
1 parent 27f4453 commit 0386a32

File tree

10 files changed

+220
-222
lines changed

10 files changed

+220
-222
lines changed

content/api/cli.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -14,50 +14,50 @@ In these commands:
1414

1515
## Tracking terms
1616

17-
{{< configOption name="ota track" description="Track the current terms of services according to provided declarations. The declarations, snapshots and versions paths are defined in the configuration." example="npx ota track" />}}
17+
{{< refItem name="ota track" description="Track the current terms of services according to provided declarations. The declarations, snapshots and versions paths are defined in the configuration." example="npx ota track" />}}
1818

1919
> Note that the snapshots and versions will be recorded at the moment the command is executed, on top of the existing local history. If a shared history already exists and the goal is to add on top of it, that history has to be downloaded before executing that command.
2020
21-
{{< configOption name="ota track --help" description="Show help and available options for track command" example="npx ota track --help" />}}
21+
{{< refItem name="ota track --help" description="Show help and available options for track command" example="npx ota track --help" />}}
2222

23-
{{< configOption name="ota track [--services <service_id>...]" description="Track terms of specific services only" example="npx ota track --services \"Facebook\" \"LinkedIn\"" />}}
23+
{{< refItem name="ota track [--services <service_id>...]" description="Track terms of specific services only" example="npx ota track --services \"Facebook\" \"LinkedIn\"" />}}
2424

25-
{{< configOption name="ota track [--services <service_id>...] [--types <terms_type>...]" description="Track specific terms types of specific services only" example="npx ota track --services \"Facebook\" \"LinkedIn\" --types \"Privacy Policy\" \"Terms of Service\"" />}}
25+
{{< refItem name="ota track [--services <service_id>...] [--types <terms_type>...]" description="Track specific terms types of specific services only" example="npx ota track --services \"Facebook\" \"LinkedIn\" --types \"Privacy Policy\" \"Terms of Service\"" />}}
2626

27-
{{< configOption name="ota track --schedule [--services <service_id>...] [--types <terms_type>...]" description="Track terms on the schedule defined in the configuration" example="npx ota track --schedule" />}}
27+
{{< refItem name="ota track --schedule [--services <service_id>...] [--types <terms_type>...]" description="Track terms on the schedule defined in the configuration" example="npx ota track --schedule" />}}
2828

2929
## Validating declarations
3030

31-
{{< configOption name="ota validate [--services <service_id>...] [--types <terms_type>...]" description="Check that all declarations allow recording a snapshot and a version properly. If service IDs are provided, check only those services." example="npx ota validate --services \"Facebook\" \"LinkedIn\" --types \"Privacy Policy\" \"Terms of Service\"" />}}
31+
{{< refItem name="ota validate [--services <service_id>...] [--types <terms_type>...]" description="Check that all declarations allow recording a snapshot and a version properly. If service IDs are provided, check only those services." example="npx ota validate --services \"Facebook\" \"LinkedIn\" --types \"Privacy Policy\" \"Terms of Service\"" />}}
3232

33-
{{< configOption name="ota validate --schema-only [--services <service_id>...] [--types <terms_type>...]" description="Check that all declarations are readable by the engine. Allows for a much faster check of declarations, but does not check that the terms are actually accessible." example="npx ota validate --schema-only --services \"Facebook\" \"LinkedIn\" --types \"Privacy Policy\" \"Terms of Service\"" />}}
33+
{{< refItem name="ota validate --schema-only [--services <service_id>...] [--types <terms_type>...]" description="Check that all declarations are readable by the engine. Allows for a much faster check of declarations, but does not check that the terms are actually accessible." example="npx ota validate --schema-only --services \"Facebook\" \"LinkedIn\" --types \"Privacy Policy\" \"Terms of Service\"" />}}
3434

35-
{{< configOption name="ota validate --modified" description="Run ota validate only on files that have been modified in Git" example="npx ota validate --modified" />}}
35+
{{< refItem name="ota validate --modified" description="Run ota validate only on files that have been modified in Git" example="npx ota validate --modified" />}}
3636

3737
## Linting declarations
3838

39-
{{< configOption name="ota lint [--services <service_id>...]" description="Test the format of declarations' normalisation." example="npx ota lint --services \"Facebook\" \"LinkedIn\"" />}}
39+
{{< refItem name="ota lint [--services <service_id>...]" description="Test the format of declarations' normalisation." example="npx ota lint --services \"Facebook\" \"LinkedIn\"" />}}
4040

41-
{{< configOption name="ota lint --fix [--services <service_id>...]" description="Automatically correct formatting mistakes and ensure that all declarations are standardised" example="npx ota lint --fix" />}}
41+
{{< refItem name="ota lint --fix [--services <service_id>...]" description="Automatically correct formatting mistakes and ensure that all declarations are standardised" example="npx ota lint --fix" />}}
4242

43-
{{< configOption name="ota lint --modified" description="Run ota lint only on files that have been modified in Git" example="npx ota lint --modified" />}}
43+
{{< refItem name="ota lint --modified" description="Run ota lint only on files that have been modified in Git" example="npx ota lint --modified" />}}
4444

4545
## Publishing dataset
4646

47-
{{< configOption name="ota dataset [--file <filename>]" description="Export the versions dataset into a ZIP file and publish it to GitHub releases. The dataset title and the URL of the versions repository are defined in the configuration." example="npx ota dataset --file dataset.zip" />}}
47+
{{< refItem name="ota dataset [--file <filename>]" description="Export the versions dataset into a ZIP file and publish it to GitHub releases. The dataset title and the URL of the versions repository are defined in the configuration." example="npx ota dataset --file dataset.zip" />}}
4848

4949
To export the dataset into a ZIP file and publish it on GitHub releases:
5050

51-
{{< configOption name="ota dataset --publish [--file <filename>]" description="Export and publish dataset to GitHub releases" example="GITHUB_TOKEN=ghp_XXXXXXXXX npx ota dataset --publish" />}}
51+
{{< refItem name="ota dataset --publish [--file <filename>]" description="Export and publish dataset to GitHub releases" example="GITHUB_TOKEN=ghp_XXXXXXXXX npx ota dataset --publish" />}}
5252

5353
The `GITHUB_TOKEN` can also be defined in a [`.env` file]({{< relref "collections/references/environment-variables" >}}).
5454

5555
To export, publish the dataset and remove the local copy that was created after it has been uploaded:
5656

57-
{{< configOption name="ota dataset --publish --remove-local-copy [--file <filename>]" description="Export, publish dataset and remove local copy after upload" example="GITHUB_TOKEN=ghp_XXXXXXXXX npx ota dataset --publish --remove-local-copy" />}}
57+
{{< refItem name="ota dataset --publish --remove-local-copy [--file <filename>]" description="Export, publish dataset and remove local copy after upload" example="GITHUB_TOKEN=ghp_XXXXXXXXX npx ota dataset --publish --remove-local-copy" />}}
5858

59-
{{< configOption name="ota dataset --schedule [--file <filename>]" description="Schedule export, publishing and local copy removal" example="GITHUB_TOKEN=ghp_XXXXXXXXX npx ota dataset --schedule --publish --remove-local-copy" />}}
59+
{{< refItem name="ota dataset --schedule [--file <filename>]" description="Schedule export, publishing and local copy removal" example="GITHUB_TOKEN=ghp_XXXXXXXXX npx ota dataset --schedule --publish --remove-local-copy" />}}
6060

6161
## Exposing the collection API
6262

63-
{{< configOption name="ota serve" description="Start the collection Web API server. The Web API will be available under `<http://localhost>:<port>/<basePath>/<apiVersion>/<resource>`. The server port and base path are defined in the configuration." example="npx ota serve" />}}
63+
{{< refItem name="ota serve" description="Start the collection Web API server. The Web API will be available under `<http://localhost>:<port>/<basePath>/<apiVersion>/<resource>`. The server port and base path are defined in the configuration." example="npx ota serve" />}}

content/collections/references/configuration.md

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,14 @@ As an example, see the [production configuration file](https://github.com/OpenTe
1111

1212
## Options
1313

14-
{{< configOption
14+
{{< refItem
1515
name="trackingSchedule"
1616
type="string"
1717
description="Defines how often the engine should check for changes in terms. Uses standard cron syntax to set the schedule. By default, it runs every 12 hours at minute 30."
1818
default="30 */12 * * *"
1919
/>}}
2020

21-
{{< configOption
21+
{{< refItem
2222
name="collectionPath"
2323
type="string"
2424
description="Path to the collection's directory containing declarations directory and metadata file, relative to the engine execution location"
@@ -30,13 +30,13 @@ As an example, see the [production configuration file](https://github.com/OpenTe
3030

3131
The recorder section manages how versions and snapshots of terms are stored, supporting multiple storage backends.
3232

33-
{{< configOption
33+
{{< refItem
3434
name="recorder.versions.storage"
3535
type="object"
3636
description="Configuration for storing versions. Supports Git and MongoDB. See [Storage Repositories](#storage-repositories) for more information."
3737
/>}}
3838

39-
{{< configOption
39+
{{< refItem
4040
name="recorder.snapshots.storage"
4141
type="object"
4242
description="Configuration for storing snapshots. Supports Git and MongoDB. See [Storage Repositories](#storage-repositories) for more information."
@@ -46,21 +46,21 @@ The recorder section manages how versions and snapshots of terms are stored, sup
4646

4747
The fetcher section configures how the engine retrieves documents from the web.
4848

49-
{{< configOption
49+
{{< refItem
5050
name="fetcher.waitForElementsTimeout"
5151
type="number"
5252
description="Maximum wait time for elements to appear in a page (milliseconds)."
5353
default="10000"
5454
/>}}
5555

56-
{{< configOption
56+
{{< refItem
5757
name="fetcher.navigationTimeout"
5858
type="number"
5959
description="Maximum wait time for a page to load (milliseconds)."
6060
default="30000"
6161
/>}}
6262

63-
{{< configOption
63+
{{< refItem
6464
name="fetcher.language"
6565
type="string"
6666
description="Language code (ISO 639-1) for request headers."
@@ -71,14 +71,14 @@ The fetcher section configures how the engine retrieves documents from the web.
7171

7272
The notifier section sets up how notifications are sent when new versions of terms are recorded.
7373

74-
{{< configOption
74+
{{< refItem
7575
name="notifier.sendInBlue.updatesListId"
7676
type="string"
7777
description="SendInBlue contacts list ID of persons to notify on terms updates."
7878
default="850"
7979
/>}}
8080

81-
{{< configOption
81+
{{< refItem
8282
name="notifier.sendInBlue.updateTemplateId"
8383
type="string"
8484
description="SendInBlue email template ID used for updates notifications."
@@ -89,42 +89,42 @@ The notifier section sets up how notifications are sent when new versions of ter
8989

9090
The logger section configures logging and error notification settings.
9191

92-
{{< configOption
92+
{{< refItem
9393
name="logger.smtp.host"
9494
type="string"
9595
description="SMTP server hostname."
9696
default="smtp-relay.sendinblue.com"
9797
/>}}
9898

99-
{{< configOption
99+
{{< refItem
100100
name="logger.smtp.username"
101101
type="string"
102102
description="Username for SMTP server authentication."
103103
104104
/>}}
105105

106-
{{< configOption
106+
{{< refItem
107107
name="logger.sendMailOnError.to"
108108
type="string"
109109
description="Email address for error notifications."
110110
111111
/>}}
112112

113-
{{< configOption
113+
{{< refItem
114114
name="logger.sendMailOnError.from"
115115
type="string"
116116
description="Sender email address for error notifications."
117117
118118
/>}}
119119

120-
{{< configOption
120+
{{< refItem
121121
name="logger.sendMailOnError.sendWarnings"
122122
type="boolean"
123123
description="Set to true to also send email in case of warning."
124124
default="false"
125125
/>}}
126126

127-
{{< configOption
127+
{{< refItem
128128
name="logger.timestampPrefix"
129129
type="boolean"
130130
description="Set to false to avoid duplicate timestamps if logs are managed by a process manager."
@@ -135,43 +135,43 @@ The logger section configures logging and error notification settings.
135135

136136
The reporter section manages how issues are reported when terms content is inaccessible, supporting GitHub and GitLab.
137137

138-
{{< configOption
138+
{{< refItem
139139
name="reporter.type"
140140
type="string"
141141
description="Type of reporter"
142142
example="github"
143143
allowedValues="github, gitlab"
144144
/>}}
145145

146-
{{< configOption
146+
{{< refItem
147147
name="reporter.repositories.declarations"
148148
type="string"
149149
description="Repository for creating issues."
150150
example="OpenTermsArchive/demo-declarations"
151151
/>}}
152152

153-
{{< configOption
153+
{{< refItem
154154
name="reporter.repositories.versions"
155155
type="string"
156156
description="Repository for versions."
157157
example="OpenTermsArchive/demo-versions"
158158
/>}}
159159

160-
{{< configOption
160+
{{< refItem
161161
name="reporter.repositories.snapshots"
162162
type="string"
163163
description="Repository for snapshots."
164164
example="OpenTermsArchive/demo-snapshots"
165165
/>}}
166166

167-
{{< configOption
167+
{{< refItem
168168
name="reporter.baseURL"
169169
type="string"
170170
description="Base URL for GitLab (if applicable)."
171171
example="https://gitlab.example.com"
172172
/>}}
173173

174-
{{< configOption
174+
{{< refItem
175175
name="reporter.apiBaseURL"
176176
type="string"
177177
description="API base URL for GitLab (if applicable)."
@@ -182,21 +182,21 @@ The reporter section manages how issues are reported when terms content is inacc
182182

183183
The dataset section configures how datasets are published.
184184

185-
{{< configOption
185+
{{< refItem
186186
name="dataset.title"
187187
type="string"
188188
description="Title of the dataset."
189189
default="sandbox"
190190
/>}}
191191

192-
{{< configOption
192+
{{< refItem
193193
name="dataset.versionsRepositoryURL"
194194
type="string"
195195
description="Repository URL for dataset releases."
196196
default="https://github.com/OpenTermsArchive/sandbox"
197197
/>}}
198198

199-
{{< configOption
199+
{{< refItem
200200
name="dataset.publishingSchedule"
201201
type="string"
202202
description="Cron expression for dataset publishing. By default, it runs every Monday at 8:30 AM."
@@ -207,15 +207,15 @@ The dataset section configures how datasets are published.
207207

208208
The collection API section sets the parameters for the API server.
209209

210-
{{< configOption
210+
{{< refItem
211211
name="collection-api.api.port"
212212
type="number"
213213
description="Port number for the API server."
214214
example="8080"
215215
required=true
216216
/>}}
217217

218-
{{< configOption
218+
{{< refItem
219219
name="collection-api.api.basePath"
220220
type="string"
221221
description="Base path for API endpoints."
@@ -229,7 +229,7 @@ The collection API section sets the parameters for the API server.
229229

230230
The storage repositories section set the parameters for supported backends for storing versions and snapshots, supporting Git and MongoDB.
231231

232-
{{< configOption
232+
{{< refItem
233233
name="storage.type"
234234
type="string"
235235
description="Type of storage backend."
@@ -241,35 +241,35 @@ The storage repositories section set the parameters for supported backends for s
241241

242242
The Git storage configuration allows to store versions in a Git repository.
243243

244-
{{< configOption
244+
{{< refItem
245245
name="storage.git.path"
246246
type="string"
247247
description="Path to the versions database directory."
248248
default="./data/versions"
249249
/>}}
250250

251-
{{< configOption
251+
{{< refItem
252252
name="storage.git.publish"
253253
type="boolean"
254254
description="Boolean to push changes to the origin."
255255
default="false"
256256
/>}}
257257

258-
{{< configOption
258+
{{< refItem
259259
name="storage.git.snapshotIdentiferTemplate"
260260
type="string"
261261
description="Template for snapshot ID reference. `%SNAPSHOT_ID` will be replaced with the actual snapshot ID."
262262
default="./data/snapshots/%SNAPSHOT_ID"
263263
/>}}
264264

265-
{{< configOption
265+
{{< refItem
266266
name="storage.git.author.name"
267267
type="string"
268268
description="Author name for changes."
269269
default="Open Terms Archive Bot"
270270
/>}}
271271

272-
{{< configOption
272+
{{< refItem
273273
name="storage.git.author.email"
274274
type="string"
275275
description="Author email for changes."
@@ -280,21 +280,21 @@ The Git storage configuration allows to store versions in a Git repository.
280280

281281
The MongoDB storage configuration allows to store versions in a MongoDB database.
282282

283-
{{< configOption
283+
{{< refItem
284284
name="storage.mongo.connectionURI"
285285
type="string"
286286
description="MongoDB connection URI."
287287
default="mongodb://127.0.0.1:27017"
288288
/>}}
289289

290-
{{< configOption
290+
{{< refItem
291291
name="storage.mongo.database"
292292
type="string"
293293
description="Database name."
294294
default="open-terms-archive"
295295
/>}}
296296

297-
{{< configOption
297+
{{< refItem
298298
name="storage.mongo.collection"
299299
type="string"
300300
description="Collection name."

content/collections/references/environment-variables.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,18 @@ This reference documentation details all available environment variables that ca
99

1010
### Engine
1111

12-
{{< configOption name="OTA_ENGINE_SMTP_PASSWORD" type="string" description="SMTP password for email error notifications." />}}
12+
{{< refItem name="OTA_ENGINE_SMTP_PASSWORD" type="string" description="SMTP password for email error notifications." />}}
1313

14-
{{< configOption name="OTA_ENGINE_SENDINBLUE_API_KEY" type="string" description="API key for SendInBlue." />}}
14+
{{< refItem name="OTA_ENGINE_SENDINBLUE_API_KEY" type="string" description="API key for SendInBlue." />}}
1515

16-
{{< configOption name="OTA_ENGINE_GITHUB_TOKEN" type="string" description="GitHub token for API access." />}}
16+
{{< refItem name="OTA_ENGINE_GITHUB_TOKEN" type="string" description="GitHub token for API access." />}}
1717

18-
{{< configOption name="OTA_ENGINE_GITLAB_TOKEN" type="string" description="GitLab token for API access." />}}
18+
{{< refItem name="OTA_ENGINE_GITLAB_TOKEN" type="string" description="GitLab token for API access." />}}
1919

20-
{{< configOption name="OTA_ENGINE_GITLAB_RELEASES_TOKEN" type="string" description="GitLab token for dataset releases." />}}
20+
{{< refItem name="OTA_ENGINE_GITLAB_RELEASES_TOKEN" type="string" description="GitLab token for dataset releases." />}}
2121

2222
---
2323

2424
### Federation API
2525

26-
{{< configOption name="OTA_FEDERATION_API_SMTP_PASSWORD" type="string" description="SMTP password for email error notifications." />}}
26+
{{< refItem name="OTA_FEDERATION_API_SMTP_PASSWORD" type="string" description="SMTP password for email error notifications." />}}

0 commit comments

Comments
 (0)