mirror of
https://github.com/threeal/cmake-action.git
synced 2026-02-01 19:40:49 +00:00
feat: remove support for testing CMake projects (#256)
* feat: remove `run-test` and `test-args` action inputs * docs: remove description for supporting testing
This commit is contained in:
13
README.md
13
README.md
@@ -1,12 +1,11 @@
|
||||
# CMake Action
|
||||
|
||||
Configure, build, and test your [CMake](https://cmake.org/) project using [GitHub Actions](https://github.com/features/actions). This action simplifies the workflow for configuring the build environment of a CMake project. It can also be optionally specified to build a CMake project using the `cmake --build` command and test it using the `ctest` command.
|
||||
Configure and build your [CMake](https://cmake.org/) project using [GitHub Actions](https://github.com/features/actions). This action simplifies the workflow for configuring the build environment of a CMake project. It can also be optionally specified to build a CMake project using the `cmake --build` command.
|
||||
|
||||
## Features
|
||||
|
||||
- Configures a CMake project using the [`cmake`](https://cmake.org/cmake/help/latest/manual/cmake.1.html) command.
|
||||
- Optionally builds a CMake project using the `cmake --build` command.
|
||||
- Optionally tests a CMake project using the [`ctest`](https://cmake.org/cmake/help/latest/manual/ctest.1.html) command.
|
||||
- Auto-detects and installs required dependencies.
|
||||
- Supports specifying multiple CMake options directly from the action inputs.
|
||||
|
||||
@@ -29,8 +28,6 @@ For more information, refer to [action.yml](./action.yml) and the [GitHub Action
|
||||
| `args` | Multiple strings | Additional arguments to pass during the CMake configuration. |
|
||||
| `run-build` | `true` or `false` | If enabled, it builds the project using CMake. It defaults to `false`. |
|
||||
| `build-args` | Multiple strings | Additional arguments to pass during the CMake build. |
|
||||
| `run-test` | `true` or `false` | If enabled, it runs testing using [CTest](https://cmake.org/cmake/help/latest/manual/ctest.1.html). It defaults to `false`. |
|
||||
| `test-args` | Multiple strings | Additional arguments to pass during the CTest run. |
|
||||
|
||||
> **Note**: Multiple strings mean that the input can be specified with more than one value. Separate each value with a space or a new line.
|
||||
|
||||
@@ -61,21 +58,17 @@ jobs:
|
||||
|
||||
- name: Build Project
|
||||
runs: cmake --build build
|
||||
|
||||
- name: Test Project
|
||||
runs: ctest --test-dir build
|
||||
```
|
||||
|
||||
> **Note**: You can replace [`v1.3.0`](https://github.com/threeal/cmake-action/releases/tag/v1.3.0) with any version you prefer. See [this](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsuses).
|
||||
|
||||
#### Configure, Build, and Test in the Same Step
|
||||
#### Configure and Build in the Same Step
|
||||
|
||||
```yaml
|
||||
- name: Configure, Build, and Test Project
|
||||
- name: Configure and Build Project
|
||||
uses: threeal/cmake-action@v1.3.0
|
||||
with:
|
||||
run-build: true
|
||||
run-test: true
|
||||
```
|
||||
|
||||
#### Specify the Source and Build Directories
|
||||
|
||||
Reference in New Issue
Block a user