Skip to content

Commit 4604301

Browse files
fixing new issues
1 parent 02da417 commit 4604301

File tree

2 files changed

+31
-21
lines changed

2 files changed

+31
-21
lines changed

README.md

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,17 +39,12 @@ A note before you try
3939

4040
## Getting Sources and install scripts
4141
```bash
42-
# remove ubuntu-on-android folder if exists
43-
rm -rf ubuntu-on-android
44-
# install dependencies
45-
apt update; apt upgrade -y ; apt install git -y
46-
# clone the code
47-
git clone https://github.com/RandomCoderOrg/ubuntu-on-android
42+
# download installer
43+
curl -o install.sh https://raw.githubusercontent.com/RandomCoderOrg/ubuntu-on-android/modified/install.sh
4844
# run the installer
49-
cd ubuntu-on-android
5045
bash install.sh
51-
# start the manager for first time (if it can't find any pre-installed fs it automatiaclly starts installing it)
52-
hippo
46+
# Install ubuntu with this command
47+
hippo --install
5348
```
5449
### Basic Usage
5550
| **Command** | **Usage** |

install.sh

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,30 @@
44
# * Script V01
55
#
66

7+
# * Deafault color is Blue
8+
RST="\e[0m"
9+
RED="\e[1;31m" # *This is bold
10+
GREEN="\e[1;32m"
11+
BLUE="\e[34m"
12+
DC=${BLUE}
13+
14+
#GREEN_THIN="\e[32m"
715

816
CACHE_ROOT="${HOME}/.uoa-cache-root"
917
TPREFIX="/data/data/com.termux/files"
10-
BIN_DIR="${TPREFIX}/usr/bin"
18+
#BIN_DIR="${TPREFIX}/usr/bin"
1119
INSTALL_FOLDER="${TPREFIX}/usr/var/lib/proot-distro/installed-rootfs"
1220
HIPPO_DIR="${INSTALL_FOLDER}/hippo"
13-
SCRIPT_DIR="${TPREFIX}/usr/etc/proot-distro/"
21+
SCRIPT_DIR="${TPREFIX}/usr/etc/proot-distro"
1422
HIPPO_REPO_URL="https://github.com/RandomCoderOrg/ubuntu-on-android"
1523
FSM_URL="https://github.com/RandomCoderOrg/fs-manager-hippo"
1624

17-
die () { echo -e "\e[1;32m Error ${*}\e[0m";exit 1 ;:;}
18-
shout () { echo -e "${*}\e[0m";:; }
25+
die () { echo -e "${RED}Error ${*}${RST}";exit 1 ;:;}
26+
shout () { echo -e "${DS}////////";echo -e "${*}";echo -e "////////${RST}";:; }
1927

2028
#
2129
# * die function exits program
22-
# * shout just echo the messege out
30+
# * shout just echo the messege out (fancy one line 😁)
2331
#
2432

2533
function setup_and_clone()
@@ -46,6 +54,11 @@ function setup_and_clone()
4654
apt install pv -y
4755
fi
4856

57+
if [ -d "${CACHE_ROOT}" ]; then
58+
shout "Removing old cache......."
59+
rm -rf "${CACHE_ROOT}"
60+
fi
61+
4962
git clone ${HIPPO_REPO_URL} "${CACHE_ROOT}/ubuntu-on-android" || die "failed to clone repo"
5063
git clone ${FSM_URL} "${CACHE_ROOT}/fs-manager-hippo" || die "failed to clone repo"
5164

@@ -59,6 +72,12 @@ function install()
5972

6073
shout "setting up implant..."
6174

75+
sleep 3
76+
77+
if [ -f ${SCRIPT_DIR} ]; then
78+
mv ${SCRIPT_DIR} "${SCRIPT_DIR}1"
79+
fi
80+
6281
if [ -f "${CACHE_ROOT}"/ubuntu-on-android/hippo.sh ]; then
6382
cp "${CACHE_ROOT}"/ubuntu-on-android/hippo.sh ${SCRIPT_DIR}
6483
fi
@@ -70,15 +89,11 @@ function install()
7089
oldpwd="$(pwd)"
7190
cd "${CACHE_ROOT}"/fs-manager-hippo || die "failed to cd ..."
7291
bash install.sh || die "failed to install manager..."
73-
cd "${oldpwd}"
92+
cd "${oldpwd}" || die "error"
7493
fi
7594

76-
shout
77-
shout "setup complete..."
78-
shout "Now you can install and login with comand\e[1;32hippo"
79-
shout "for info use hippo --help"
80-
shout
81-
95+
96+
shout "setup complete...\nNow you can install and login with comand${GREEN}hippo${DC}\nfor info use hippo --help"
8297
exit 1
8398

8499
}

0 commit comments

Comments
 (0)