Skip to content

Commit

Permalink
Update generated documentation [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
markvincze committed Mar 29, 2024
1 parent 8ee9111 commit e16573b
Show file tree
Hide file tree
Showing 3 changed files with 103 additions and 79 deletions.
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,30 @@ message SearchRequest {
(If you include code blocks in a comment, then it's better to use single-line comments (`// ...`) as opposed to block comments (`/* ... */`), because the `protoc` compiler trims all leading whitespace from the lines in block comments, thus the indentation in code blocks gets lost.)
### Customize Jinja templates for primary content
The `template-path` configuration parameter can be used to specify an alternative directory where the Jinja templates that drive the content of Sabledocs can be found.
Copy the contents of the `src/sabledocs/templates/_default` from the current version of Sabledocs to the configured directory then edit the templates as necessary.
```toml
template-path = "templates"
```

### Extra Jinja templates

If you would like to include your own Jinja templates, specify the `extra-template-path` configuration parameter and
all files that end in `template-path-suffix` (default ".html") will be processed and included as a Jinja template in the output
path at a location relative to the `extra-template-path`.

Also processes all subdirectories of `extra-template-path` recursively.

Prefix a subdirectory with `_` to have it ignored.

```toml
template-path = "extra-templates"
template-path-suffix = ".tpl" # default value is ".html"
```

### Using with Docker

For convenient usage in CI builds and other scenarios where a Docker image is preferable, the image [`markvincze/sabledocs`](https://hub.docker.com/r/markvincze/sabledocs) can be used, which has both the `protoc` CLI, and `sabledocs` preinstalled.
Expand Down
98 changes: 49 additions & 49 deletions demo/google.datastore.v1.html
Original file line number Diff line number Diff line change
Expand Up @@ -2890,60 +2890,71 @@ <h4 class="title is-4 type-heading" id="message-google.datastore.v1.Mutation">
<tr class="nohover">
<td class="oneof-heading" colspan="4">
<div class="oneof-heading">
<strong>oneof operation</strong>
<strong>oneof conflict_detection_strategy</strong>
</div>
</td>
</tr>


<tr>
<td>
4
8
</td>
<td>
insert
base_version
</td>
<td>
<code title="google.datastore.v1.Entity">
<code title="int64">

<a href="google.datastore.v1.html#message-google.datastore.v1.Entity"><span title="google.datastore.v1.Entity">google.datastore.v1.Entity</span>
</a>
<span>int64</span>
</code>
</td>
<td class="content"><p>The entity to insert. The entity must not already exist.
The entity key's final path element may be incomplete.</p></td>
<td class="content"><p>The version of the entity that this mutation is being applied
to. If this does not match the current version on the server, the
mutation conflicts.</p></td>

</tr>



<tr>
<td>
5
11
</td>
<td>
update
update_time
</td>
<td>
<code title="google.datastore.v1.Entity">
<code title="google.protobuf.Timestamp">

<a href="google.datastore.v1.html#message-google.datastore.v1.Entity"><span title="google.datastore.v1.Entity">google.datastore.v1.Entity</span>
</a>
<span>google.protobuf.Timestamp</span>
</code>
</td>
<td class="content"><p>The entity to update. The entity must already exist.
Must have a complete key path.</p></td>
<td class="content"><p>The update time of the entity that this mutation is being applied
to. If this does not match the current update time on the server, the
mutation conflicts.</p></td>

</tr>




<tr class="nohover"><td style="border: 0px"></td></tr>
<tr class="nohover">
<td class="oneof-heading" colspan="4">
<div class="oneof-heading">
<strong>oneof operation</strong>
</div>
</td>
</tr>


<tr>
<td>
6
4
</td>
<td>
upsert
insert
</td>
<td>
<code title="google.datastore.v1.Entity">
Expand All @@ -2952,7 +2963,7 @@ <h4 class="title is-4 type-heading" id="message-google.datastore.v1.Mutation">
</a>
</code>
</td>
<td class="content"><p>The entity to upsert. The entity may or may not already exist.
<td class="content"><p>The entity to insert. The entity must not already exist.
The entity key's final path element may be incomplete.</p></td>

</tr>
Expand All @@ -2961,73 +2972,62 @@ <h4 class="title is-4 type-heading" id="message-google.datastore.v1.Mutation">

<tr>
<td>
7
5
</td>
<td>
delete
update
</td>
<td>
<code title="google.datastore.v1.Key">
<code title="google.datastore.v1.Entity">

<a href="google.datastore.v1.html#message-google.datastore.v1.Key"><span title="google.datastore.v1.Key">google.datastore.v1.Key</span>
<a href="google.datastore.v1.html#message-google.datastore.v1.Entity"><span title="google.datastore.v1.Entity">google.datastore.v1.Entity</span>
</a>
</code>
</td>
<td class="content"><p>The key of the entity to delete. The entity may or may not already exist.
Must have a complete key path and must not be reserved/read-only.</p></td>
<td class="content"><p>The entity to update. The entity must already exist.
Must have a complete key path.</p></td>

</tr>




<tr class="nohover"><td style="border: 0px"></td></tr>
<tr class="nohover">
<td class="oneof-heading" colspan="4">
<div class="oneof-heading">
<strong>oneof conflict_detection_strategy</strong>
</div>
</td>
</tr>


<tr>
<td>
8
6
</td>
<td>
base_version
upsert
</td>
<td>
<code title="int64">
<code title="google.datastore.v1.Entity">

<span>int64</span>
<a href="google.datastore.v1.html#message-google.datastore.v1.Entity"><span title="google.datastore.v1.Entity">google.datastore.v1.Entity</span>
</a>
</code>
</td>
<td class="content"><p>The version of the entity that this mutation is being applied
to. If this does not match the current version on the server, the
mutation conflicts.</p></td>
<td class="content"><p>The entity to upsert. The entity may or may not already exist.
The entity key's final path element may be incomplete.</p></td>

</tr>



<tr>
<td>
11
7
</td>
<td>
update_time
delete
</td>
<td>
<code title="google.protobuf.Timestamp">
<code title="google.datastore.v1.Key">

<span>google.protobuf.Timestamp</span>
<a href="google.datastore.v1.html#message-google.datastore.v1.Key"><span title="google.datastore.v1.Key">google.datastore.v1.Key</span>
</a>
</code>
</td>
<td class="content"><p>The update time of the entity that this mutation is being applied
to. If this does not match the current update time on the server, the
mutation conflicts.</p></td>
<td class="content"><p>The key of the entity to delete. The entity may or may not already exist.
Must have a complete key path and must not be reserved/read-only.</p></td>

</tr>

Expand Down
60 changes: 30 additions & 30 deletions demo/google.pubsub.v1.html
Original file line number Diff line number Diff line change
Expand Up @@ -5323,81 +5323,81 @@ <h4 class="title is-4 type-heading" id="message-google.pubsub.v1.PushConfig">
<tr class="nohover">
<td class="oneof-heading" colspan="4">
<div class="oneof-heading">
<strong>oneof wrapper</strong>
<strong>oneof authentication_method</strong>
</div>
</td>
</tr>


<tr>
<td>
4
3
</td>
<td>
pubsub_wrapper
oidc_token
</td>
<td>
<code title="google.pubsub.v1.PushConfig.PubsubWrapper">
<code title="google.pubsub.v1.PushConfig.OidcToken">

<a href="google.pubsub.v1.html#message-google.pubsub.v1.PushConfig.PubsubWrapper"><span title="google.pubsub.v1.PushConfig.PubsubWrapper">google.pubsub.v1.PushConfig.PubsubWrapper</span>
<a href="google.pubsub.v1.html#message-google.pubsub.v1.PushConfig.OidcToken"><span title="google.pubsub.v1.PushConfig.OidcToken">google.pubsub.v1.PushConfig.OidcToken</span>
</a>
</code>
</td>
<td class="content"><p>When set, the payload to the push endpoint is in the form of the JSON
representation of a PubsubMessage
(https://cloud.google.com/pubsub/docs/reference/rpc/google.pubsub.v1#pubsubmessage).</p></td>
<td class="content"><p>If specified, Pub/Sub will generate and attach an OIDC JWT token as an
<code>Authorization</code> header in the HTTP request for every pushed message.</p></td>

</tr>




<tr class="nohover"><td style="border: 0px"></td></tr>
<tr class="nohover">
<td class="oneof-heading" colspan="4">
<div class="oneof-heading">
<strong>oneof wrapper</strong>
</div>
</td>
</tr>


<tr>
<td>
5
4
</td>
<td>
no_wrapper
pubsub_wrapper
</td>
<td>
<code title="google.pubsub.v1.PushConfig.NoWrapper">
<code title="google.pubsub.v1.PushConfig.PubsubWrapper">

<a href="google.pubsub.v1.html#message-google.pubsub.v1.PushConfig.NoWrapper"><span title="google.pubsub.v1.PushConfig.NoWrapper">google.pubsub.v1.PushConfig.NoWrapper</span>
<a href="google.pubsub.v1.html#message-google.pubsub.v1.PushConfig.PubsubWrapper"><span title="google.pubsub.v1.PushConfig.PubsubWrapper">google.pubsub.v1.PushConfig.PubsubWrapper</span>
</a>
</code>
</td>
<td class="content"><p>When set, the payload to the push endpoint is not wrapped.</p></td>
<td class="content"><p>When set, the payload to the push endpoint is in the form of the JSON
representation of a PubsubMessage
(https://cloud.google.com/pubsub/docs/reference/rpc/google.pubsub.v1#pubsubmessage).</p></td>

</tr>




<tr class="nohover"><td style="border: 0px"></td></tr>
<tr class="nohover">
<td class="oneof-heading" colspan="4">
<div class="oneof-heading">
<strong>oneof authentication_method</strong>
</div>
</td>
</tr>


<tr>
<td>
3
5
</td>
<td>
oidc_token
no_wrapper
</td>
<td>
<code title="google.pubsub.v1.PushConfig.OidcToken">
<code title="google.pubsub.v1.PushConfig.NoWrapper">

<a href="google.pubsub.v1.html#message-google.pubsub.v1.PushConfig.OidcToken"><span title="google.pubsub.v1.PushConfig.OidcToken">google.pubsub.v1.PushConfig.OidcToken</span>
<a href="google.pubsub.v1.html#message-google.pubsub.v1.PushConfig.NoWrapper"><span title="google.pubsub.v1.PushConfig.NoWrapper">google.pubsub.v1.PushConfig.NoWrapper</span>
</a>
</code>
</td>
<td class="content"><p>If specified, Pub/Sub will generate and attach an OIDC JWT token as an
<code>Authorization</code> header in the HTTP request for every pushed message.</p></td>
<td class="content"><p>When set, the payload to the push endpoint is not wrapped.</p></td>

</tr>

Expand Down

0 comments on commit e16573b

Please sign in to comment.