40 lines
625 B
Bash
Executable file
40 lines
625 B
Bash
Executable file
#!/usr/bin/env bash
|
|
#
|
|
# SCRIPT NAME:
|
|
# games
|
|
#
|
|
# AUTHOR:
|
|
# Severin Kaderli <severin@kaderli.dev>
|
|
#
|
|
# DESCRIPTION:
|
|
# Displays a game menu using rofi.
|
|
#
|
|
# USAGE:
|
|
# ./games
|
|
|
|
# The rofi prompt
|
|
PROMPT="Games"
|
|
|
|
# Actions for the menu
|
|
ACTIONS=(
|
|
"1: Steam"
|
|
"2: Guild Wars 2"
|
|
"3: Minecraft"
|
|
"4: Pegasus"
|
|
)
|
|
|
|
SELECTION=$(printf '%s\n' "${ACTIONS[@]}" | rofi -dmenu -p "${PROMPT}" | cut -d ":" -f1)
|
|
case "${SELECTION}" in
|
|
"1")
|
|
steam
|
|
;;
|
|
"2")
|
|
gw2
|
|
;;
|
|
"3")
|
|
optirun -b primus java minecraft-launcher
|
|
;;
|
|
"4")
|
|
optirun -b primus pegasus-fe
|
|
;;
|
|
esac
|