netscape_bookmark_parser
netscape_bookmark_parser
Introduction
netscape_bookmark_parser is a Rust crate designed to parse HTML bookmark files (commonly exported from web browsers) and convert them into a structured JSON format. This crate provides functionality to read, parse, and transform bookmark data, making it easier to work with bookmarks programmatically.
Features
- HTML Bookmark Parsing: The crate can parse HTML files that contain browser bookmarks, extracting folder structures and individual bookmarks.
- Timestamp Conversion: It handles the conversion of Unix timestamps to Windows NT timestamps, ensuring accurate date representation.
- JSON Output: The parsed data is converted into a JSON structure, which can be easily integrated into other applications or stored for further processing.
- Error Handling: Robust error handling ensures that issues with file paths or malformed HTML are gracefully managed.
Usage
To use netscape_bookmark_parser, you can add it as a dependency in your Cargo.toml file:
Then, you can call the run function to process an HTML bookmarks file and output the result as a JSON file:
use netscape_bookmark_parser;
install as CLI
# example