usdx_parser

Crates.iousdx_parser
lib.rsusdx_parser
version0.2.2
sourcesrc
created_at2022-04-03 09:32:05.968951
updated_at2022-04-07 21:29:20.563742
descriptionParser for UltraStar Deluxe song files.
homepage
repositoryhttps://github.com/MGlolenstine/usdx_parser.git
max_upload_size
id561241
size16,671
(MGlolenstine)

documentation

README

UltraStar Deluxe parser

About

This is a rust parser for USDX song files. Files are written as a plaintext files that contain data about the song and notes/lyrics.

Usage

Direct read from a file:

let song = Song::from_file("tests/test.txt").unwrap();
dbg!(song);

Read from a &str:

let text = std::fs::read_to_string("tests/test.txt").unwrap();
let song = Song::from_str(&text).unwrap();
dbg!(song);

Parse directly from String:

let text = r#"
#ARTIST:Three Days Grace
#TITLE:I Hate Everything About You
#MP3:i_hate_everything_about_you.ogg
#LANGUAGE:English
#BPM:100
#GAP:100
"#;
let song: Song = text.to_string().into();
dbg!(song);
Commit count: 10

cargo fmt