File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,11 @@ D_SCRIPTS="${TERMUX}/usr/etc/proot-distro"
55D_INSTALLED_ROOTFS=" ${TERMUX} /usr/var/lib/proot-distro/installed-rootfs"
66D_CACHCE=" ${HOME} /.udroid-cache-root"
77
8+ _c_magneta=" \e[95m"
9+ _c_green=" \e[32m"
10+ _c_red=" \e[31m"
11+ _c_blue=" \e[34m"
12+
813die () { echo -e " ${RED} [E] ${* }${RST} " ; exit 1; : ; }
914warn () { echo -e " ${RED} [W] ${* }${RST} " ; : ; }
1015shout () { echo -e " ${DS} [-] ${* }${RST} " ; : ; }
@@ -166,7 +171,7 @@ download() {
166171 url=$1
167172 location=$2
168173 curl -L -o $location $url || {
169- die " This action requires connection to the internet ."
174+ die " Download operation failed ."
170175 }
171176}
172177
@@ -179,3 +184,8 @@ if [ $# -ge 0 ]; then
179184 * ) l_login $* ;;
180185 esac
181186fi
187+
188+ # make sure to create cache dir first
189+ if [ ! -d " $D_CACHCE " ]; then
190+ mkdir -p " $D_CACHCE "
191+ fi
You can’t perform that action at this time.
0 commit comments