Skip to content

Commit

Permalink
Move the installation and development section into spoilers
Browse files Browse the repository at this point in the history
  • Loading branch information
ll-nick committed Nov 29, 2024
1 parent 13966e4 commit 33f2c9c
Showing 1 changed file with 23 additions and 6 deletions.
29 changes: 23 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ or by specifying one comparison policy and threshold (100ms for example), and re

## Installation

### Using Debian package (recommended)
<details>
<summary>Using Debian package (recommended)</summary>

We provide a Debian package for easy installation on Debian-based distributions.
Download the [latest `.deb` package](https://github.com/KIT-MRT/util_caching/releases/latest/download/libutil-caching-dev.deb) and install it with `dpkg`:
Expand All @@ -114,7 +115,10 @@ Download the [latest `.deb` package](https://github.com/KIT-MRT/util_caching/rel
sudo dpkg -i libutil-caching-dev.deb
```

### Using Docker image
</details>

<details>
<summary>Using Docker image</summary>

We provide a [`Dockerfile`](./Dockerfile) with the library already installed globally.

Expand All @@ -133,8 +137,10 @@ So, it can be easily loaded with CMake:
find_package(util_caching REQUIRED)
```

</details>

### Building from source using CMake
<details>
<summary>Building from source using CMake</summary>

First make sure all dependencies are installed:
- [Googletest](https://github.com/google/googletest) (only if you want to build unit tests)
Expand All @@ -151,10 +157,13 @@ cmake --build .
sudo cmake --install .
```

</details>


## Development

### Using Docker image
<details>
<summary>Using Docker image</summary>

Follow the steps above to setup the Docker image.
Then, run the development image.
Expand All @@ -166,8 +175,11 @@ docker compose run --rm --build util_caching_devel
This mounts the source into the container's `/home/blinky/util_caching` folder.
There, you can edit the source code, compile and run the tests etc.

</details>


### Compiling unit tests using CMake
<details>
<summary>Compiling unit tests using CMake</summary>

In order to compile with tests define `BUILD_TESTS=true`
```bash
Expand All @@ -183,8 +195,11 @@ Run all unit tests:
cmake --build . --target test
```

</details>


### Using ROS 1 and catkin
<details>
<summary>Using ROS 1 and catkin</summary>

The [`demo/Dockerfile_ros`](./demo/Dockerfile_ros) shows that how util_caching can be used in a catkin project (it uses CMake under the hood anyways):

Expand All @@ -194,3 +209,5 @@ docker compose -f demo/docker-compose.ros.yaml run --rm util_caching_ros
```

See [demo/README.md](demo/README.md) for how to run the demo, showcasing the use of `util_caching` in a ROS node.

</details>

0 comments on commit 33f2c9c

Please sign in to comment.