https://github.com/philipk/steam_shortcuts_util
Utilities for parsing & writing Steams shortcut.vdf file format
https://github.com/philipk/steam_shortcuts_util
parser steam
Last synced: 11 months ago
JSON representation
Utilities for parsing & writing Steams shortcut.vdf file format
- Host: GitHub
- URL: https://github.com/philipk/steam_shortcuts_util
- Owner: PhilipK
- Created: 2021-08-29T06:09:26.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2022-05-20T21:15:05.000Z (about 4 years ago)
- Last Synced: 2025-07-26T01:32:38.193Z (11 months ago)
- Topics: parser, steam
- Language: Rust
- Homepage: https://crates.io/crates/steam_shortcuts_util
- Size: 85 KB
- Stars: 1
- Watchers: 2
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Steam Shortcuts utility
Steam Shortcuts is a utility crate that helps you to manage your Steam shortcuts.
It is a simple Rust crate that provides a simple interface to manage your Steam shortcuts.
## Getting started
First include the crate in your project:
```toml
[dependencies]
steam_shortcuts_util = "1.1.7"
```
Then you can use it:
```rust
use steam_shortcuts_util::parse_shortcuts;
use steam_shortcuts_util::shortcuts_to_bytes;
fn example() -> Result<(), Box> {
// This path should be to your steam shortcuts file
// Usually located at $SteamDirectory/userdata/$SteamUserId/config/shortcuts.vdf
let content = std::fs::read("src/testdata/shortcuts.vdf")?;
let shortcuts = parse_shortcuts(content.as_slice())?;
assert_eq!(shortcuts[0].app_name, "Celeste");
assert_eq!(3, shortcuts[0].tags.len());
let shortcut_bytes_vec = shortcuts_to_bytes(&shortcuts);
assert_eq!(shortcut_bytes_vec, content);
Ok(())
}
```
*Be aware that if you overwrite the shortcuts.vdf file, you will have to restart Steam for the changes to take effect.*