Skip to content

Latest commit

 

History

History
72 lines (47 loc) · 1.86 KB

File metadata and controls

72 lines (47 loc) · 1.86 KB

Contributing to flowfilter

Thanks for your interest in contributing. Here's how to get going.

Building from source

You need Rust 1.70+ (stable). Then:

git clone https://github.com/dragonGR/flowfilter.git
cd flowfilter
cargo build

The binary ends up at target/debug/flowfilter. For an optimized build, use cargo build --release.

Running tests

cargo test

That runs unit tests and integration tests. If you want to run benchmarks too:

cargo bench

Code style

We use rustfmt and clippy. Please run both before submitting:

cargo fmt
cargo clippy -- -D warnings

CI will reject PRs that fail either check. The formatting config lives in rustfmt.toml at the repo root.

Making changes

  1. Fork the repo and create a branch off main.
  2. Make your changes. Add tests for new functionality.
  3. Run cargo fmt, cargo clippy -- -D warnings, and cargo test.
  4. Open a pull request against main.

Keep PRs focused -- one feature or fix per PR is easier to review than a grab bag. If your change is large, consider opening an issue first to discuss the approach.

Reporting issues

Open an issue on GitHub. Include:

  • What you tried to do
  • What happened instead
  • The command you ran (with input data if possible)
  • Your OS and Rust version (rustc --version)

Minimal reproducible examples make bugs much easier to track down.

Adding a new format adapter

If you want to add support for a new input format (e.g., TOML, YAML):

  1. Add a new module under src/format/.
  2. Implement the FormatReader trait for your format.
  3. Wire it into src/detect.rs for auto-detection and src/main.rs for the CLI flag.
  4. Add sample data in examples/sample_data/ and an example script in examples/.
  5. Write tests.

License

By contributing, you agree that your contributions will be licensed under the MIT License.