Nickel configuration file parser with multi-language FFI bindings
[](https://example.com/rsr) [](https://example.com/tpcf) [](./LICENSE) [](https://github.com/hyperpolymath/bunsenite/actions)
Bunsenite is a Nickel configuration file parser with a Rust core library and multi-language FFI bindings. It provides a stable C ABI layer (via Zig) that enables bindings for Deno (JavaScript/TypeScript), Rescript, and WebAssembly for browser and universal use.
-
✅ Type Safety: Compile-time guarantees via Rust’s type system
-
✅ Memory Safety: Rust ownership model, zero
unsafeblocks -
✅ Offline-First: Works completely air-gapped, no network dependencies
-
✅ Multi-Language: FFI bindings for Deno, Rescript, and WASM
-
✅ Standards Compliant: RSR Bronze tier, TPCF Perimeter 3
-
✅ Well-Documented: Comprehensive API docs, examples, and guides
-
✅ Production-Ready: 100% test pass rate, CI/CD, semantic versioning
= From crates.io
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo install bunsenite
= From source
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
git clone https://github.com/hyperpolymath/bunsenite.git
cd bunsenite
cargo install --path .use bunsenite::NickelLoader;
fn main() {
let config = r#"
{
name = "my-app",
version = "1.0.0",
port = 8080,
}
"#;
let loader = NickelLoader::new();
let result = loader.parse_string(config, "config.ncl").unwrap();
println!("Config: {}", result);
}= Parse and evaluate a config file
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
bunsenite parse config.ncl
= Pretty-print output
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
bunsenite parse config.ncl --pretty
= Validate without evaluating
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
bunsenite validate config.ncl
= Show version and compliance info
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
bunsenite infoimport init, { parse_nickel } from './bunsenite.js';
async function main() {
await init();
const config = `{ name = "example", version = "1.0.0" }`;
const result = parse_nickel(config, "config.ncl");
console.log(JSON.parse(result));
}┌─────────────────────────────────────────────────┐
│ Consumers │
├───────────────┬───────────────┬─────────────────┤
│ Deno │ Rescript │ Browser │
│ (TypeScript) │ (ReScript) │ (WASM) │
└───────┬───────┴───────┬───────┴────────┬────────┘
│ │ │
▼ ▼ ▼
┌──────────┐ ┌──────────┐ ┌──────────────┐
│ Zig FFI │ │ Zig FFI │ │ wasm-bindgen │
│ (C ABI) │ │ (C ABI) │ │ │
└─────┬────┘ └─────┬────┘ └──────┬───────┘
│ │ │
└──────────────┴─────────────────┘
│
▼
┌─────────────────┐
│ Rust Core │
│ (lib.rs) │
│ │
│ nickel-lang-core│
│ 0.9.1 │
└─────────────────┘Zig FFI Layer: Provides stable C ABI, isolating consumers from Rust ABI changes. This allows language bindings to remain stable across Rust compiler versions.
WASM Support: Enables browser deployment and universal compatibility at ~95% native speed.
Deno .ts Files: Required syntax for Deno runtime FFI (NOT plain TypeScript). Uses Deno.dlopen for native FFI calls to Zig layer.
-
[CLAUDE.md](./CLAUDE.md): Comprehensive guide for AI assistants and developers
-
[SECURITY.md](./SECURITY.md): Security policies and vulnerability reporting
-
[CONTRIBUTING.md](./CONTRIBUTING.md): Contribution guidelines
-
[CHANGELOG.md](./CHANGELOG.md): Version history and release notes
-
[API Docs](https://docs.rs/bunsenite): Full Rust API documentation
Bunsenite meets all Rhodium Standard Repository (RSR) Bronze tier requirements:
-
✅ Type safety (Rust compile-time guarantees)
-
✅ Memory safety (ownership model,
#![deny(unsafe_code)]) -
✅ Offline-first (no network dependencies)
-
✅ Complete documentation (README, LICENSE, SECURITY, CONTRIBUTING, CODE_OF_CONDUCT, MAINTAINERS)
-
✅
.well-known/directory (security.txt, ai.txt, humans.txt) -
✅ Build system (Justfile, Nix flake)
-
✅ CI/CD pipeline (GitLab CI)
-
✅ 100% test pass rate
This project uses the Tri-Perimeter Contribution Framework (TPCF):
-
Perimeter 1: Core maintainers only (restricted)
-
Perimeter 2: Trusted contributors (by invitation)
-
Perimeter 3: Community Sandbox - Open to all contributors
All contributions are welcome! See [CONTRIBUTING.md](./CONTRIBUTING.md) for details.
-
Rust 1.70+ (
rustup install stable) -
justcommand runner (cargo install just) -
Optional: Zig compiler (for FFI layer)
-
Optional:
wasm-pack(for WASM builds:cargo install wasm-pack) -
Optional: Deno runtime (for Deno bindings)
= Build all targets
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
just all
= Build Rust library and CLI
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo build --release
= Build WebAssembly
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
just wasm
= Run tests
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo test
= Run linter
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo clippy
= Format code
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo fmt
= Check RSR compliance
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
just rsr-checkSee Justfile for all available commands.
= Run all tests
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo test
= Run tests with output
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo test -- --nocapture
= Run specific test
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo test test_name
= Run with coverage (requires tarpaulin)
image:https://img.shields.io/badge/license-AGPL--3.0-blue.svg[AGPL-3.0,link="https://www.gnu.org/licenses/agpl-3.0"] image:https://img.shields.io/badge/philosophy-Palimpsest-purple.svg[Palimpsest,link="https://github.com/hyperpolymath/palimpsest-licence"]
cargo tarpaulin --out HtmlCurrent status: 100% test pass rate (30+ tests covering core functionality, error handling, and edge cases)
-
Native Rust: Baseline performance
-
WebAssembly: ~95% native speed
-
FFI (Deno/Rescript): ~90% native speed (C ABI overhead minimal)
We take security seriously. See [SECURITY.md](./SECURITY.md) for:
-
Supported versions
-
Vulnerability reporting process
-
Security best practices
-
Responsible disclosure policy
Security contact: See .well-known/security.txt or [SECURITY.md](./SECURITY.md)
Dual licensed under your choice of:
-
MIT License ([LICENSE-MIT](./LICENSE) or http://opensource.org/licenses/MIT)
-
Palimpsest License v0.8 ([LICENSE-PALIMPSEST](./LICENSE) or https://palingenesis.org/palimpsest-license)
This allows maximum flexibility for use while preserving reversibility and emotional safety principles.
Contributions are welcome! This is a TPCF Perimeter 3 (Community Sandbox) project.
See [CONTRIBUTING.md](./CONTRIBUTING.md) for:
-
Code of Conduct
-
Development workflow
-
Testing requirements
-
Commit message conventions
-
Pull request process
-
Issues: [GitHub Issues](https://github.com/hyperpolymath/bunsenite/issues)
-
Discussions: [GitHub Discussions](https://github.com/hyperpolymath/bunsenite/discussions)
-
Security: See [SECURITY.md](./SECURITY.md)
-
[Nickel Language Team](https://github.com/tweag/nickel) for the excellent configuration language
-
RSR Framework contributors
-
TPCF community
-
All contributors to this project
See [NEXT_STEPS.md](./NEXT_STEPS.md) for planned features and enhancements:
-
❏ Additional language bindings (Python, Ruby, Node.js)
-
❏ Performance benchmarking suite
-
❏ REPL/interactive mode
-
❏ Schema validation
-
❏ Watch mode for auto-reload
-
❏ Plugin system