Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- STEAMAPPS=~/.steam/steam/steamapps/
- echo '<openbox_pipe_menu>'
- for file in $(ls $STEAMAPPS/*.acf -1v); do
- ID=$(cat "$file" | grep '"appid"' | head -1 | sed -r 's/[^"]*"appid"[^"]*"([^"]*)"/\1/')
- NAME=$(cat "$file" | grep '"name"' | head -1 | sed -r 's/[^"]*"name"[^"]*"([^"]*)"/\1/')
- echo "<item label=\"$NAME\" icon=\"$HOME/.local/share/icons/hicolor/32x32/apps/steam_icon_$ID.png\"><action name=\"Execute\"><execute>steam steam://run/$ID</execute></action></item>"
- done | sort
- echo '</openbox_pipe_menu>'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement