| Crates.io | editorconfig-sys |
| lib.rs | editorconfig-sys |
| version | 0.1.3 |
| created_at | 2024-01-27 02:44:56.614358+00 |
| updated_at | 2025-02-11 21:53:40.436515+00 |
| description | Raw FFI bindings to libeditorconfig |
| homepage | https://github.com/toblux/editorconfig-sys |
| repository | https://github.com/toblux/editorconfig-sys |
| max_upload_size | |
| id | 1116448 |
| size | 35,040 |
This crate uses bindgen and pkg-config to automatically generate Rust FFI bindings to the editorconfig-core C library.
Following the *-sys package convention, editorconfig-sys is just a thin wrapper around the native libeditorconfig library.
The safe Rust bindings to libeditorconfig, built on top of this editorconfig-sys crate, can be found here.
To use this crate, pkg-config and libeditorconfig >= 0.12.5 must be installed. For example, on Debian or Ubuntu you could use apt install pkg-config libeditorconfig-dev and on macOS brew install pkg-config editorconfig to install the dependencies.
You can check if pkg-config can find the library and which version is installed with:
pkg-config --modversion editorconfig
Add this to your Cargo.toml:
[dependencies]
editorconfig-sys = "0.1.3"
Some unsafe Rust code examples can be found in the tests.