diff options
Diffstat (limited to 'bin/shuffle')
| -rwxr-xr-x | bin/shuffle | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/bin/shuffle b/bin/shuffle index 103b95c..d676963 100755 --- a/bin/shuffle +++ b/bin/shuffle @@ -15,11 +15,10 @@ def main(): nargs='?', help= 'play files in <path>, or the current directory if <path> is not passed') - parser.add_argument('-m', - dest='mpv_opts', - default=['--no-video'], - action='append', - help='pass <opts> to mpv') + parser.add_argument('--volume', + default=100.0, + type=float, + help='volume for mpv (should be in 0-100 range)') args = parser.parse_args() # Keep track of the last few files we played and avoid playing them again @@ -37,7 +36,7 @@ def main(): del prev[:len(prev) - 2] print('Playing', file) - subprocess.run(['mpv', *args.mpv_opts, file]) + subprocess.run(['mpv', f'--volume={args.volume}', file]) if __name__ == "__main__": try: |
