| Crates.io | cpkg |
| lib.rs | cpkg |
| version | 0.12.1 |
| created_at | 2024-03-25 07:41:43.202733+00 |
| updated_at | 2024-09-23 00:57:00.151013+00 |
| description | A dead simple C package manager. |
| homepage | |
| repository | |
| max_upload_size | |
| id | 1185055 |
| size | 90,468 |
A dead simple, modern package manager for C.
cpkg is an all-in-one wrapper for tools like gcc, clang, doxygen and clang-format.
It automatically detects which are present on your system, allowing you to use them with one simple cli.
Inspired by the convenience of modern tools like cargo and bun.
cpkg init
cpkg run
You can create a project with new or init, and then run /src/main.c with cpkg run or cpkg build.
You can run tests located in /src/*.test.c and /tests/*.c with cpkg test.
You can add local paths with cpkg add <name> --path /path/to/dependency and git dependencies with cpkg add <name> --git https://github.com/nothings/stb/tree/master.
Project files can be generated using cpkg generate.
This creates a project file that acts as if you ran cpkg build, without cpkg.
Currently only supports basic Makefile generation
cpkg supports other functionalities:
clang-formatdoxygenYou can download the cpkg binary from the releases (or a nightly build from actions)
If you have cargo you can install from crates.io.
cargo install cpkg
Or clone the repository and install it locally.
git clone https://github.com/DvvCz/cpkg
cargo install --path cpkg
The other options are preferred, but there is an install script.
curl -fsSL https://raw.githubusercontent.com/DvvCz/cpkg/master/install.sh | bash
You can easily upgrade your cpkg binary using the cpkg upgrade command.