mirror of https://github.com/mpv-player/mpv
osx: load the proper profiles and configs in the bundle
different shells need different args to load the expected profiles and configs, so we added a small heuristic to decide those args. also don't always load the profiles for a bash login shell and instead only use the standard shell without any args.
This commit is contained in:
parent
67506f21b8
commit
12ee13101b
|
@ -1,4 +1,13 @@
|
||||||
#!/bin/bash -l
|
#!/bin/sh
|
||||||
export MPVBUNDLE="true"
|
export MPVBUNDLE="true"
|
||||||
|
|
||||||
|
# set the right args for the user specified standard shell
|
||||||
|
# to load the expected profiles and configs
|
||||||
|
args="-c"
|
||||||
|
case "$SHELL" in
|
||||||
|
*bash) args="-l $args";;
|
||||||
|
*zsh) args="-l -i $args";;
|
||||||
|
esac
|
||||||
|
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"
|
||||||
$SHELL -c "./mpv --player-operation-mode=pseudo-gui"
|
$SHELL $args "./mpv --player-operation-mode=pseudo-gui"
|
||||||
|
|
Loading…
Reference in New Issue