Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ brew tap Roshan-R/termv https://github.com/Roshan-R/homebrew-termv
brew install termv
```

### Android
For Android users with [termux](https://termux.org/) and [mpv-android](https://github.com/mpv-android/mpv-android) installed, it is possible to direct install to a folder in the path

### Installation by cloning the repository

```sh
Expand Down
6 changes: 5 additions & 1 deletion termv
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,9 @@ update_channelsfile() {
}

# check if necessary programs are installed
for prog in mpv fzf jq curl gawk; do
DEPENDENCIES="fzf jq curl gawk"
[ "$(uname -o)" != "Android" ] && DEPENDENCIES="mpv ${DEPENDENCIES}"
for prog in ${DEPENDENCIES}; do
! has "$prog" && dependencies_not_installed="${dependencies_not_installed}${prog}, "
done

Expand Down Expand Up @@ -139,6 +141,8 @@ _play() {
# shellcheck disable=SC2086
mpv "${*##* }" ${TERMV_MPV_FLAGS} --force-media-title="${*%% *}" --force-window=immediate
xdo show "$WID" && xdo activate "$WID"
elif [ "$(uname -o)" == "Android" ]; then
am start -n is.xyz.mpv/is.xyz.mpv.MPVActivity -e filepath "${*##* }"
else
# shellcheck disable=SC2086
mpv "${*##* }" ${TERMV_MPV_FLAGS} --force-media-title="${*%% *}"
Expand Down