4 releases (stable)
2.0.0-beta.0 | Dec 7, 2024 |
---|---|
1.0.2 | Dec 1, 2024 |
1.0.1 | Nov 30, 2024 |
#803 in Authentication
411 downloads per month
13KB
148 lines
vxde - VXD File Parser for Rust
vxde
is a Rust library that provides a parser for .vxd
files. These files contain key-value pairs used in games or configurations, where the values can be in plaintext or serialized. The parser handles files with flexible formatting, such as varying spaces, newlines, and semicolons as delimiters.
This crate allows you to easily parse .vxd
files into a HashMap
of variables, supporting a wide range of input formats.
Series 2025 Features
- Parse
.vxd
files into aHashMap
of key-value pairs. - Custom
vxde
serialization algorithm for encoding.vxd
files. - Custom
vxde
decoder for decoding serialized.vxd
files back to plaintext. - Handle whitespace, newlines, and semicolons as delimiters.
- Handle quoted values (e.g.,
"value"
) and non-quoted values (e.g.,value
). - Handle edge cases like empty files and invalid formats.
- Support both plaintext and serialized
.vxd
files for parsing. - Customizable serialization algorithm options.
- Support for nested key-value structures (like JSON).
- Improved error handling with detailed feedback for parsing.
- Logging and debugging tools for better traceability.
- File format versioning support for future-proofing.
- Batch processing support for handling multiple
.vxd
files. - Command-line tool for parsing, encoding, and decoding
.vxd
files. - Performance optimizations for large
.vxd
files. - Cross-platform support (Windows, macOS, Linux).
- Integration tests to ensure all features work as expected.
This version, Version 2.0.0-beta.0 Series 2025, will have:
- A rework of the internal mechanisms of the parser
- A clearer syntax for the
.vxd
file,NAME : TYPE = VALUE;
ReanoMeter Rating: C - Extensive changes
Letter | Level |
---|---|
S | 5 - Invisible Update |
A | 4 - Minor Adjustments |
B | 3 - Moderate Effort |
C | 2 - Extensive Changes |
D | 1 - Complete Overhaul |
Installation
To use vxde
in your Rust project, run the command:
cargo add vxde
or add it as a dependency in your Cargo.toml
:
[dependencies]
vxde = "2.0.0-beta.0"
Tests
vxde
includes a comprehensive test suite to ensure that the parser works correctly. These tests cover:
- Basic parsing of well-formed
.vxd
files. - Handling of extra spaces, newlines, and semicolons as delimiters.
- Parsing empty files and files with missing values.
- Handling of malformed files and invalid formats.
You can run the tests using the following command:
cargo test
Contributing
If you'd like to contribute to vxde
, feel free to open an issue or submit a pull request. Contributions are always welcome!
Steps for Contributing:
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Write tests for your changes.
- Run
cargo test
to ensure all tests pass. - Submit a pull request with a detailed explanation of your changes.
License
vxde
is licensed under the BSD 2-Clause License. See the LICENSE file for more details.
Project Structure
vxde/
├── src/
│ └── lib.rs # Main library file containing the parser
├── tests/
│ ├── test_name.rs # Tests for the VxdeParser
│ └── assets/
│ ├── test_data.vxd # assets for unit tests in the src files
│ ├── test_data2.vxd
│ └── test_name.rs/ # assets for the specific test files
│ └── func_name.vxd # assets for the specific function in named test file
├── Cargo.toml # The project's metadata and dependencies
└── README.md # This README file
Dependencies
~2.2–3MB
~55K SLoC