fix: script update function

This commit is contained in:
CoolnsX
2022-03-06 02:08:51 +05:30
parent 23db25ab5d
commit a1a6c4be14
2 changed files with 6 additions and 6 deletions

View File

@@ -12,7 +12,7 @@
A cli to browse and watch Korean Drama, Chinese drama. This tool scrapes the site [dramacool](https://dramacool.fo). A cli to browse and watch Korean Drama, Chinese drama. This tool scrapes the site [dramacool](https://dramacool.fo).
This tool is modified version of [ani-cli](https://github.com/pystardust/ani-cli) which is anime scraping tool. Feel free to checkout if you need to watch anime. This tool is modified version of [ani-cli](https://github.com/pystardust/ani-cli) which is anime scraping tool. Feel free to check it out if you need to watch anime.
## Table of Contents ## Table of Contents
- [Install](#Installation) - [Install](#Installation)
@@ -43,7 +43,7 @@ Install termux [(Guide)](https://termux.com/)
pkg install git termux-tools ncurses-utils openssl-tool -y pkg install git termux-tools ncurses-utils openssl-tool -y
git clone https://github.com/CoolnsX/dra-cla && cd dra-cla git clone https://github.com/CoolnsX/dra-cla && cd dra-cla
cp dra-cla $PREFIX/bin/dra-cla cp dra-cla $PREFIX/bin/dra-cla
echo 'am start --user 0 -a android.intent.action.VIEW -d "$2" -n is.xyz.mpv/.MPVActivity' > $PREFIX/bin/mpv echo 'am start -n is.xyz.mpv/.MPVActivity "$2"' > $PREFIX/bin/mpv
chmod +x $PREFIX/bin/mpv chmod +x $PREFIX/bin/mpv
``` ```
@@ -55,8 +55,8 @@ Install mpv-android [(Link)](https://play.google.com/store/apps/details?id=is.xy
## Uninstall ## Uninstall
* Other Linux: Just remove the thing from path * Linux: ```sudo rm /usr/local/bin/dra-cla```
* Android: Just remove the thing from path * Android: ```rm $PREFIX/bin/dra-cla```
## Dependencies ## Dependencies

View File

@@ -18,7 +18,7 @@
# Project repository: https://github.com/CoolnsX/dra-cla # Project repository: https://github.com/CoolnsX/dra-cla
# Version number # Version number
VERSION="1.0.0" VERSION="1.0.1"
####################### #######################
@@ -70,7 +70,7 @@ die () {
update_script () { update_script () {
# get the newest version of this script from github and replace it # get the newest version of this script from github and replace it
update="$(curl -s "https://raw.githubusercontent.com/CoolnsX/dra-cla/master/dra-cla" | diff -u "$0" -)" update="$(curl -s "https://raw.githubusercontent.com/CoolnsX/dra-cla/main/dra-cla" | diff -u "$0" -)"
if [ -z "$update" ]; then if [ -z "$update" ]; then
inf "Script is up to date :)" inf "Script is up to date :)"
else else