Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
Signed-off-by: Dennis Meister <[email protected]>
  • Loading branch information
dennismeister93 committed Jun 9, 2024
1 parent 6ba97ad commit ba5f62b
Show file tree
Hide file tree
Showing 7 changed files with 348 additions and 12 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ build
logs
results
.pytest_cache
.coverage

mkdocs.yml
.generated-files.txt
2 changes: 1 addition & 1 deletion NOTICE-3RD-PARTY-CONTENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Python
| Dependency | Version | License |
|:-----------|:-------:|--------:|
|types-requests|2.32.0.20240521|Apache 2.0|
|types-requests|2.32.0.20240602|Apache 2.0|
|urllib3|2.2.1|MIT|
## Workflows
| Dependency | Version | License |
Expand Down
13 changes: 13 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,27 @@
## Modules

- [`velocitas_lib`](./velocitas_lib.md#module-velocitas_lib)
- [`velocitas_lib.conan_helper`](./velocitas_lib.conan_helper.md#module-velocitas_libconan_helper)
- [`velocitas_lib.docker`](./velocitas_lib.docker.md#module-velocitas_libdocker)
- [`velocitas_lib.functional_interface`](./velocitas_lib.functional_interface.md#module-velocitas_libfunctional_interface)
- [`velocitas_lib.middleware`](./velocitas_lib.middleware.md#module-velocitas_libmiddleware)
- [`velocitas_lib.services`](./velocitas_lib.services.md#module-velocitas_libservices)
- [`velocitas_lib.templates`](./velocitas_lib.templates.md#module-velocitas_libtemplates)
- [`velocitas_lib.variables`](./velocitas_lib.variables.md#module-velocitas_libvariables)

## Classes

- [`middleware.MiddlewareType`](./velocitas_lib.middleware.md#class-middlewaretype): Enumeration containing all possible middleware types.
- [`services.Service`](./velocitas_lib.services.md#class-service): Service(id, config)
- [`services.ServiceSpecConfig`](./velocitas_lib.services.md#class-servicespecconfig): ServiceSpecConfig(image, is_enabled, env_vars, args, ports, port_forwards, mounts, startup_log_patterns)
- [`templates.CopySpec`](./velocitas_lib.templates.md#class-copyspec): Copy specification of a single file or directory.
- [`variables.ProjectVariables`](./velocitas_lib.variables.md#class-projectvariables)

## Functions

- [`velocitas_lib.capture_textfile_area`](./velocitas_lib.md#function-capture_textfile_area): Capture an area of a textfile between a matching start line (exclusive) and the first line matching end_line (exclusive).
- [`velocitas_lib.create_log_file`](./velocitas_lib.md#function-create_log_file): Create a log file for the given service and runtime.
- [`velocitas_lib.create_truncated_string`](./velocitas_lib.md#function-create_truncated_string): Create a truncated version of input if it is longer than length.
- [`velocitas_lib.download_file`](./velocitas_lib.md#function-download_file)
- [`velocitas_lib.get_app_manifest`](./velocitas_lib.md#function-get_app_manifest)
- [`velocitas_lib.get_cache_data`](./velocitas_lib.md#function-get_cache_data): Return the data of the cache as Python object.
Expand All @@ -29,8 +34,15 @@
- [`velocitas_lib.get_programming_language`](./velocitas_lib.md#function-get_programming_language): Return the programming language of the project.
- [`velocitas_lib.get_project_cache_dir`](./velocitas_lib.md#function-get_project_cache_dir): Return the project's cache directory.
- [`velocitas_lib.get_script_path`](./velocitas_lib.md#function-get_script_path): Return the absolute path to the directory the invoked Python script
- [`velocitas_lib.get_valid_arch`](./velocitas_lib.md#function-get_valid_arch): Return a known architecture for the given `arch`.
- [`velocitas_lib.get_workspace_dir`](./velocitas_lib.md#function-get_workspace_dir): Return the workspace directory.
- [`velocitas_lib.replace_in_file`](./velocitas_lib.md#function-replace_in_file): Replace all occurrences of text in a file with a replacement.
- [`velocitas_lib.require_env`](./velocitas_lib.md#function-require_env): Require and return an environment variable.
- [`velocitas_lib.to_camel_case`](./velocitas_lib.md#function-to_camel_case): Return a camel case version of a snake case string.
- [`conan_helper.add_dependency_to_conanfile`](./velocitas_lib.conan_helper.md#function-add_dependency_to_conanfile): Add the dependency name to the project's list of dependencies.
- [`conan_helper.export_conan_project`](./velocitas_lib.conan_helper.md#function-export_conan_project): Export a conan project to the local conan cache.
- [`conan_helper.get_required_sdk_version`](./velocitas_lib.conan_helper.md#function-get_required_sdk_version): Return the required version of the core SDK.
- [`conan_helper.move_generated_sources`](./velocitas_lib.conan_helper.md#function-move_generated_sources): Move generated source code from the generation dir into
- [`docker.build_vehicleapp_image`](./velocitas_lib.docker.md#function-build_vehicleapp_image): Build VehicleApp docker image and display the progress using a spinner.
- [`docker.container_exists`](./velocitas_lib.docker.md#function-container_exists): Check if a container with a given name exists.
- [`docker.is_docker_image_build_locally`](./velocitas_lib.docker.md#function-is_docker_image_build_locally): Check if vehicle app docker image is locally available
Expand All @@ -42,6 +54,7 @@
- [`services.get_specific_service`](./velocitas_lib.services.md#function-get_specific_service): Return the specified service as Python object.
- [`services.parse_service_config`](./velocitas_lib.services.md#function-parse_service_config): Parse service spec configuration and return it as an named tuple.
- [`services.resolve_functions`](./velocitas_lib.services.md#function-resolve_functions)
- [`templates.copy_templates`](./velocitas_lib.templates.md#function-copy_templates): Copy templates from the template dir to the target dir.
- [`variables.json_obj_to_flat_map`](./velocitas_lib.variables.md#function-json_obj_to_flat_map): Flatten a JSON Object into a one dimensional dict by joining the keys


Expand Down
109 changes: 109 additions & 0 deletions docs/velocitas_lib.conan_helper.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
<!-- markdownlint-disable -->

<a href="../velocitas_lib/conan_helper.py#L0"><img align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square"></a>

# <kbd>module</kbd> `velocitas_lib.conan_helper`





---

<a href="../velocitas_lib/conan_helper.py#L24"><img align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square"></a>

## <kbd>function</kbd> `get_required_sdk_version`

```python
get_required_sdk_version() → Optional[str]
```

Return the required version of the core SDK.



**Returns:**

- <b>`Optional[str]`</b>: The required version or None in case SDK is not a dependency.


---

<a href="../velocitas_lib/conan_helper.py#L41"><img align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square"></a>

## <kbd>function</kbd> `move_generated_sources`

```python
move_generated_sources(
generated_source_dir: str,
output_dir: str,
include_dir_rel: str,
src_dir_rel: str
) → Tuple[List[str], List[str]]
```

Move generated source code from the generation dir into headers: <output_dir>/<include_dir_rel> sources: <output_dir>/<src_dir_rel>



**Args:**

- <b>`generated_source_dir`</b> (str): The directory containing the generated sources.
- <b>`output_dir`</b> (str): The root directory to move the generated files to.
- <b>`include_dir_rel`</b> (str): Path relative to output_dir where to move the headers to.
- <b>`src_dir_rel`</b> (str): Path relative to the output_dir where to move the sources to.



**Returns:**

- <b>`Tuple[List[str], List[str]]`</b>: A tuple containing [0] = a list of the paths to all headers [1] = a list of the paths to all sources


---

<a href="../velocitas_lib/conan_helper.py#L80"><img align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square"></a>

## <kbd>function</kbd> `export_conan_project`

```python
export_conan_project(conan_project_path: str) → None
```

Export a conan project to the local conan cache.



**Args:**

- <b>`conan_project_path`</b> (str): The path to directory containing the project.


---

<a href="../velocitas_lib/conan_helper.py#L139"><img align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square"></a>

## <kbd>function</kbd> `add_dependency_to_conanfile`

```python
add_dependency_to_conanfile(
dependency_name: str,
dependency_version: str
) → None
```

Add the dependency name to the project's list of dependencies.



**Args:**

- <b>`dependency_name`</b> (str): The dependency to add e.g. grpc
- <b>`dependency_version`</b> (str): The version of the dependency to add e.g. 1.50.1




---

_This file was automatically generated via [lazydocs](https://github.com/ml-tooling/lazydocs)._
Loading

0 comments on commit ba5f62b

Please sign in to comment.