2024-09-14 23:01:46 +00:00
|
|
|
set command termux-media-player
|
|
|
|
|
|
|
|
complete -c $command -f
|
|
|
|
|
|
|
|
complete -c $command \
|
|
|
|
-s h \
|
2024-09-29 14:39:22 +00:00
|
|
|
-d 'Show help'
|
2024-09-14 23:01:46 +00:00
|
|
|
|
|
|
|
set subcommands_with_descriptions 'info\t"Show a current playback information"' \
|
|
|
|
'play\t"Resume a playback if paused | Play a specific media file"' \
|
|
|
|
'pause\t"Pause a playback"' \
|
|
|
|
'stop\t"Quit a playback"'
|
|
|
|
|
|
|
|
set subcommands (string replace --regex '\\\t.+' '' -- $subcommands_with_descriptions)
|
|
|
|
|
|
|
|
complete -c $command \
|
|
|
|
-a "$subcommands_with_descriptions" \
|
|
|
|
-n "not __fish_seen_subcommand_from $subcommands"
|
|
|
|
|
|
|
|
complete -c $command \
|
|
|
|
-n "__fish_seen_subcommand_from play" \
|
2024-09-15 11:14:22 +00:00
|
|
|
-F -r
|