From 0aff454084776d1fc77cd82da9ed1427b8ce2c16 Mon Sep 17 00:00:00 2001 From: Vivek W Date: Fri, 13 Dec 2024 22:18:41 +0530 Subject: [PATCH 1/4] Updated installation script and documentation --- .DS_Store | Bin 0 -> 10244 bytes 1click.install.sh | 23 ++++++------ APT/.DS_Store | Bin 0 -> 6148 bytes Bootstrap/.DS_Store | Bin 0 -> 6148 bytes Fedora/.DS_Store | Bin 0 -> 6148 bytes Installer/.DS_Store | Bin 0 -> 8196 bytes LinuxDroid/.DS_Store | Bin 0 -> 6148 bytes Uninstall/.DS_Store | Bin 0 -> 8196 bytes WM/.DS_Store | Bin 0 -> 6148 bytes XBPS/.DS_Store | Bin 0 -> 6148 bytes new_readme.md | 82 +++++++++++++++++++++++++++++++++++++++++++ structure.md | 63 +++++++++++++++++++++++++++++++++ 12 files changed, 158 insertions(+), 10 deletions(-) create mode 100644 .DS_Store create mode 100644 APT/.DS_Store create mode 100644 Bootstrap/.DS_Store create mode 100644 Fedora/.DS_Store create mode 100644 Installer/.DS_Store create mode 100644 LinuxDroid/.DS_Store create mode 100644 Uninstall/.DS_Store create mode 100644 WM/.DS_Store create mode 100644 XBPS/.DS_Store create mode 100644 new_readme.md create mode 100644 structure.md diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..b9029fbd2dc107c4f279403b389921be6d3e7cc6 GIT binary patch literal 10244 zcmeHM&ubGw6n>keZPHrJp?E8!AWVZbopGa%Ln8@G@tC2LZ;O9wJ{3ji5Iv77Lm6c3QLk|`x?QbL1d$*PdD zs-?CVmaL9)TiK5UmJLA)pCDi)zK&o!ru}tl0);9gPfy0R+%{}Qx(5*RKg|89hBK9&C>$( z6`dLC&-WazH6GW~^Xpz*hrl=Q1Y8_ViyD9Z4Z&ZM(%`3zs|a4IV6#jGaOu!ASSnGG z_hh7)D(t5Y=fd88=W(&8FCOth>hZWD#V;bR1mbdVExO}i0Wns1Bt)kZ;Z_{`#;FYt zdq{g6ZD&i4Pri1kn=XU#0uTb5j%?sLkZF33>Ec-*QIUj(=wDyT|FieRHP&roJAxdz6`=s~G9Q8iCQT^+MO@w}>#ripNr4@%tjwGU$=c zmKwhJ6dY48jk!IuM9Y-H7;*5cz!7%ce*dYR9mlxy^_$0cXq%kdy=*zouE~bL*^Sjc zhc#8KzGaRN--*Lbe;CR~Ea2)umlsK-d`94Ec4M%-T%=B(zdX6Kxy5;fH zWE1pWI~xthGxsaCSG{41nB8K0-4Sb$hG)Wh2t1*79M|&h4-Z!x+W_BQwi?cfhTyA* zvca3MiLuBlyVZhY+uZayYifu0UVAGIPqYDNm}wK>OM7o?tkH|#;Z_{i{lvD%Sx9>v zTW3oRpY>AUi_%@-%WIehmp=p=j^pE#pB@fXkNa-bYW@c6!e4}L(lyOndib1I&V8+) z@nd%Da8J!T%}?6(6Qf&rQ;t(s^F@8D@a5~czoEze`pxvgSPau^erXC#n`9U;3>XFs z14qn&*xw`B;{5+o`~Ux4Ba;~h3o{Y* <| |_| | | | (_) | | (_| |#"; -echo "# |_____|_|_| |_|\__,_/_/\_\____/|_| \___/|_|\__,_|#"; -echo "# One-Click Installer #"; -echo "# by Vivek W #"; -echo "# Github.com/AryanVBW #"; -echo "#####################################################"; +echo "#####################################################" +echo "# _ _ ____ _ _ #" +echo "# | | (_)_ __ _ ___ _| _ \ _ __ ___ (_) __| |#" +echo "# | | | | '_ \| | | \ \/ / | | | '__/ _ \| |/ _` |#" +echo "# | |___| | | | | |_| |> <| |_| | | | (_) | | (_| |#" +echo "# |_____|_|_| |_|\__,_/_/\_\____/|_| \___/|_|\__,_|#" +echo "# One-Click Installer #" +echo "# by Vivek W #" +echo "# Github.com/AryanVBW #" +echo "#####################################################" + echo "Updating and upgrading packages..." pkg update -y && pkg upgrade -y @@ -33,3 +34,5 @@ echo "Downloading and running LinuxDroid script..." curl -O https://github.com/AryanVBW/LinuxDroid/releases/download/scripts/LinuxDroid.sh chmod +x LinuxDroid.sh bash LinuxDroid.sh + +echo "Installation completed! Run ./LinuxDroidmenu.sh to start." diff --git a/APT/.DS_Store b/APT/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..6d80880472fe279c475c2bcf9d1cc4307cc56ecb GIT binary patch literal 6148 zcmeHKu}T9$5S@)D2DJz%Xd~Pw81Mrw@nRJrk`$IljA)T?Y3#2OtSu}=Z2Sg6u=bzq ze6u@Vb}yG!RAylJ-Oby%$GmX2St2ssn@O9fMMO;u#%L2$O)$@6DH@X51sZcDSvfZyE)^{79+Y7Z;#ug%Z$G#yX#G1fH?iucR@?MLUkW|mJ@a`S8d zd57G0M14A^lzJ7dC!h26p6^P%vewtE<3rtSp?gN7itcBr3(nWg?kl>MU-VkX*Xo{9 zhep+Yw;!yoaK7%_qo-T)3*9u~vmj`6D=g&ps`hODnWcqz5Ldf)B(6`_8{ z`Wk=30qofv%`JyIs{`tQI#4>m--j53F%c{r+D`{2djtSRNZY_QpCz~^7EA;ShhPxK zl>%L;V9hiMlr$=k5aq1e0vX_JX(KeGD7mV!i+-f`vn5 Q5c)^J+Mts<@S_fV0Uz*;!2kdN literal 0 HcmV?d00001 diff --git a/Bootstrap/.DS_Store b/Bootstrap/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..3fc4742acb78830c98087af4e92eb7aebe17e2f5 GIT binary patch literal 6148 zcmeHKy-ve05I#ews)A5PMsLi0gHVMD2BeCG3Hl?b)HD@pMx;z#coi02f{BOXyR(%# zO(Hgg;I6X2PQX&9imG zTNTQHGVt3N;BU7_Da~m@3u=77(c8W~%hPnS%qP(I&j+9L>+Q!y(`WXr&-y9cC%6oX z=n54qX;I%pj_yKRnE&;p%3sB1`7U>xy(MptZjkpGznnIExwrCcfj!Lsep={$Nsa)(2x<{rOD_jnRsa)^r9)^S#)Sf1sPRV(vjNAkV3 w@o?O0Eyg_t3;UH0B?Oai$8y1~_zXh?Hp>^l#AE3Y8i@W85E^t+27Z)*FUTB$T>t<8 literal 0 HcmV?d00001 diff --git a/Fedora/.DS_Store b/Fedora/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..cad46729eaa0ac08de8143fb02e441d530fd34a2 GIT binary patch literal 6148 zcmeHKy-EW?5T1<}h}Z;d6a*K1f`C|G;>9W!k`yT=Mzlz{H1^l%8~7}~ft63;BUoGb z&CYPyO-@S@nSt4FZ+`A$zdLSkiO3Be<~^b=5q02QOp+Q46)AR;oI%#>9wEc=Rf9G_wl=tqg8pY zXp-_~?{O~XeLmXYMenj)^ETyEUN5|t)Thbjdb7{KtGSr><2d52^K0Iwd;@PADqqk! z4e2ypaeE)kQ8wm2JE^&oiZy$4MFT&t-OLm)1xx`}0DCrDXHU>ZQ@|831!@KO`{3b> zxnd<4J{=gs5dfGW91L^*rQ{y3m@8I-$iSSm0;SdI5yMG4;$G`=#Y#}x$pvQIN12_T zP+VX~+=p^;)t-C7*)wH|&A pXXCm`ux`O5Y{jVMt@r>Q3~|pBV6IpRA_B7?fgpnorogW%@CEQ;bI||* literal 0 HcmV?d00001 diff --git a/Installer/.DS_Store b/Installer/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..94381d5dcd0d44e162259569a54e2ce4377baea9 GIT binary patch literal 8196 zcmeHMO=}ZT6uqwvF`x^P6P*n1HpmdKyV;9a26cEo~=itV&Avf zFb4;M1OKH1`u-5%&@px~v(el-Fqswrv4+!T;4}IFQxmxuyO`N%O0lNx9+WFpuEkKc z9QjDY5n~rK8*Mo$TTaR`E7zeY!;ZShz)8h6hB-J894I=Vd-pnZXhJg@7yI|kZ;Sb9 znk2nR+Qa$A<;}0d2d}?$ikQJl%DdSKIUZ+G(0| zm*oYo$~14C5*ktu*MCUIlDm6#G0*wcJ_7nhkyIkD5=NzUZ)+S1X}1+ zs%dn&j4wmOSy3d&ofys4LVWf@> zG2Mb-DY=K7P?-8VEhKcL928%Cjf#2!GV9*0aZ(OlP&0Xy>;PAbgv!ZIKZKY z#$`5|5=^EYM>Op?qW^~>K1YD+n%Kq6Mx4R;>n{TEOrxJA_1)Kk_p;{Q--~1hD`B literal 0 HcmV?d00001 diff --git a/LinuxDroid/.DS_Store b/LinuxDroid/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..18252089f8024f5f70aec52e4aee910de0e5e8b9 GIT binary patch literal 6148 zcmeHKy-EW?5T1>v#2-RR3yW<9n^dWUOE?R`F1_RzEpoXK5ZkLPf)C--r1Bv|(9&n{ zo88HIn;-0g$jq_(EweK_bKe~|H$-IG55opgortO!jFm%78-(|HtVu;QCqU!QcpTp~ zI)f~ouGy;MZ!*BoZl78-!r(-$yr3i`J^e@E42eed!Hp zcHvG3)TSOyaE)jdyg~EZz19744quCpWe&j^Y4(%FHk%-iXUlm+bWH=WFbQ&~U0jy; z%JE-bKbP?f-*W6t`$62=8^={q29yD1VAl+wX0ud}J?g9sC&(f-9(7g*l!1@|?yVqouK!ot`+sMolQN(T{7(i*tq66#T0PoqlbzAQHHXHlsKy=_r zI-tKFQXV>HE*3VLuMT!*3&5Cg*fhT8KETXLUCdl8Y&283rrkX#H&wYUhO*O{Pqmye zbFr||PKUD7pyr#2zSDGqU5dxr3b>-(In|MH`+FY;yWP(Dz%gCQmu z@%{?hSXis@q#P*5BYr%4460ZdzB^Xr{2!5h*bW(91{(QC`DuJ?V;;1j&o~S&wIF7@f_pnqAJ&|JaPP8 z1^C_dX+l>tTRnvD?|8R~lvPp8SJfPz^zGp5{^I3z5=NIlMAwhutfwdgUqP329`g;a zn@Gs_aTxH~y0U8c+R+Za9qjIo7F42tidm1|!5YOw?$1%py^+(bU|UYdIug2}9BY}z zYZ%V3hB_AVo0FP9h&S9_@eW>0FD43z0-`{q0M2Z-bl;)$qJStM3e*bl_d%mEW*&`0 z`{_VuuK>UVZfh9xFD2J#kC{i~5D}Pir9fAz{1rpFa`?5+%RCx~uAG#=d??SX{0&7} zcFeDBI;qT|^rC<$5G&Akj{`pc&$i$H<05$y1w?^=rGQF`X^~?~{%mb+j?Y?+c8kWw ndB$N~f`L7Xk;_N%2+bP&ng_tlqj3liOnwBc4AO}LzpB7D2~Ktc literal 0 HcmV?d00001 diff --git a/XBPS/.DS_Store b/XBPS/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..287aa480c079bbad34d77c038abaf52f0223a5dc GIT binary patch literal 6148 zcmeHKy-ve05I(m-3WA{{qhFyC4`7PJ)CHA+5tUXjv`QC7Bu@-5@d7*!;$e6O#CJX` zjY-M~2;E8cm)uXj_)CgMCar#&I4U8zj#m(C{@@H{;oLz20;( z)$vyq;AdCRlrG6rl|R4XeLJ?Uy`Qh@Ieevmd|yr0&1@ zVr|}!r!TxQzUA$U_wepvwP$on6&>fy#S8AL6>W3BJvZE0#+JQ5BjwwXH`HIPz4$V`1@cn7+u037(X4D;uZi{z#R?8@!t+;*#UG3gCIOGBc(to zHED}sq#S;m@?63oDCJ}#Gp>`EP1>QD$PT}a>13Rs&Z>YakSj2h(-HUoYWMy>FVZtr zKo$5`3Yfyr`~*u%y|uGA?zI-<3WJUFf?!jEgV>6Z%dPkbBO3gc4}dOV5QGP&KLSw( Kom7DzRp1kL`(79T literal 0 HcmV?d00001 diff --git a/new_readme.md b/new_readme.md new file mode 100644 index 0000000..88f5a26 --- /dev/null +++ b/new_readme.md @@ -0,0 +1,82 @@ +# LinuxDroid - Linux CLI + GUI for Android + +

+ +LinuxDroid

+ +## Overview + +LinuxDroid brings the power of Linux to your Android device, offering both Command Line Interface (CLI) and Graphical User Interface (GUI) experiences. Run your favorite Linux distributions directly on your Android device with ease and flexibility. + +

+ +LinuxDroid

+ +## Quick Installation + +### One-Click Installation +Copy and paste this command in Termux: +```bash +curl -sSL https://raw.githubusercontent.com/AryanVBW/LinuxDroid/refs/heads/main/1click.install.sh | bash +``` + +## Supported Operating Systems + +LinuxDroid supports a wide range of Linux distributions: + +- 🦜 Parrot OS +- Kali Linux +- Ubuntu +- Arch Linux +- Debian +- Manjaro +- Void Linux +- Alpine +- Fedora +- NethunterRootLess (Specialized for Security Testing) + +## Features + +- Easy one-click installation process +- Support for both CLI and GUI interfaces +- Wide range of Linux distributions +- Customized bash environment +- Regular updates and maintenance +- Active community support + +## Requirements + +- Android device (ARM64) +- Termux app installed +- Internet connection +- Minimum 4GB storage space +- 2GB RAM recommended + +## Usage + +1. Install Termux from F-Droid or Google Play Store +2. Run the one-click installation command +3. Choose your preferred Linux distribution +4. Start using Linux on your Android device! + +## Project Structure + +For detailed information about the project structure and organization, please refer to [structure.md](structure.md). + +## Contributing + +Contributions are welcome! Please feel free to submit pull requests. + +## Support + +If you encounter any issues or need help, please: +1. Check the [Issues](https://github.com/AryanVBW/LinuxDroid/issues) section +2. Create a new issue if your problem isn't already listed +3. Join our community discussions + +## License + +This project is open source and available under the MIT License. + +

Made with ❤️ By Vivek W

+

v1.1.3

diff --git a/structure.md b/structure.md new file mode 100644 index 0000000..1a906a8 --- /dev/null +++ b/structure.md @@ -0,0 +1,63 @@ +# LinuxDroid Project Structure + +## Overview +LinuxDroid is organized into several key components that work together to provide a seamless Linux experience on Android devices. + +## Directory Structure + +``` +LinuxDroid/ +├── LinuxDroid/ # Core assets directory +│ ├── Banner/ # Project banners and images +│ └── Icon/ # OS and application icons +│ +├── scripts/ # Installation and utility scripts +│ ├── LinuxDroidmenu.sh # Main menu interface +│ └── OS-specific/ # OS-specific installation scripts +│ +├── 1click.install.sh # One-click installation script +├── default.bashrc # Default bash configuration +├── README.md # Project documentation +└── structure.md # This file - project structure documentation +``` + +## Component Description + +### 1. Core Scripts +- `1click.install.sh`: Primary installation script that sets up the basic environment +- `LinuxDroidmenu.sh`: Interactive menu for OS selection and management +- `default.bashrc`: Customized bash configuration for optimal terminal experience + +### 2. Supported Operating Systems +LinuxDroid supports multiple Linux distributions: +- Parrot OS +- Kali Linux +- Ubuntu +- Arch Linux +- Debian +- Manjaro +- Void Linux +- Alpine +- Fedora +- NethunterRootLess + +### 3. Asset Management +- **Banner Directory**: Contains project branding and promotional images +- **Icon Directory**: Houses distribution-specific icons and logos + +### 4. Documentation +- `README.md`: Primary project documentation and setup instructions +- `structure.md`: Detailed project structure and organization + +## Installation Flow +1. User executes `1click.install.sh` +2. Script sets up Termux environment +3. Downloads and configures necessary components +4. Installs LinuxDroid menu interface +5. User can then select and install desired Linux distributions + +## Development Guidelines +- All scripts should maintain POSIX compliance +- New OS additions should follow the existing script structure +- Asset additions should maintain consistent naming conventions +- Documentation updates should be made for significant changes From 620de5c16045f2a4547c92c089ab329b437515be Mon Sep 17 00:00:00 2001 From: Vivek W <92390419+AryanVBW@users.noreply.github.com> Date: Fri, 13 Dec 2024 23:56:13 +0530 Subject: [PATCH 2/4] Create 1click.install.sh --- BETA/1click.install.sh | 288 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 288 insertions(+) create mode 100644 BETA/1click.install.sh diff --git a/BETA/1click.install.sh b/BETA/1click.install.sh new file mode 100644 index 0000000..f391364 --- /dev/null +++ b/BETA/1click.install.sh @@ -0,0 +1,288 @@ +#!/bin/bash + +# Function to detect Android version +detect_android_version() { + local api_level=$(getprop ro.build.version.sdk) + local version_code=$(getprop ro.build.version.release) + echo "Android API Level: $api_level" + echo "Android Version Code: $version_code" +} + +# Function to detect device architecture +detect_device_architecture() { + local arch=$(getprop ro.product.cpu.abi) + echo "Device Architecture: $arch" +} + +# Function to display LinuxDroid logo +display_logo() { + echo -e "\033[96m+===================================================+\033[0m" + echo -e "\033[96m| _ _ ____ _ _ |\033[0m" + echo -e "\033[96m| | | (_)_ __ _ ___ _| _ \ _ __ ___ (_) __| ||\033[0m" + echo -e "\033[96m| | | | | _ \| | | \ \/ / | | | __/ _ \| |/ _ ||\033[0m" + echo -e "\033[96m| | |___| | | | | |_| |> <| |_| | | | (_) | | (_| ||\033[0m" + echo -e "\033[96m| |_____|_|_| |_|\__,_/_/\_\____/|_| \___/|_|\__,_||\033[0m" + echo -e "\033[96m| By Vivek W |\033[0m" + echo -e "\033[96m| |\033[0m" + echo -e "\033[96m| 🔥GitHub:- Github.com/AryanVBW |\033[0m" + echo -e "\033[96m| 🌐Site:- AryanVBW.github.io |\033[0m" + echo -e "\033[96m| 💖Instagram:- Aryan_Technolog1es |\033[0m" + echo -e "\033[96m+===================================================+\033[0m" +} + +# Function to display colored text +color_text() { + local text="$1" + local color="$2" + echo -e "\e[${color}m$text\e[0m" +} + +# Function to install GUI version based on OS choice and Android version +install_gui_version() { + local os_choice="$1" + local cmd="" + + # Construct the appropriate command based on OS choice and Android version + case $os_choice in + 1) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install kali-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Kali/kali-xfce.sh -O kali-xfce.sh && chmod +x kali-xfce.sh && bash kali-xfce.sh" + fi + ;; + 2) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install ubuntu22-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Ubuntu22/ubuntu22-xfce.sh -O ubuntu22-xfce.sh && chmod +x ubuntu22-xfce.sh && bash ubuntu22-xfce.sh" + fi + ;; + 3) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install arch-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Arch/armhf/arch-xfce.sh -O arch-xfce.sh && chmod +x arch-xfce.sh && bash arch-xfce.sh" + fi + ;; + 4) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install debian-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Debian/debian-xfce.sh -O debian-xfce.sh && chmod +x debian-xfce.sh && bash debian-xfce.sh" + fi + ;; + 5) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install manjaro-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Manjaro/manjaro-xfce.sh -O manjaro-xfce.sh && chmod +x manjaro-xfce.sh && bash manjaro-xfce.sh" + fi + ;; + 6) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install void-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Void/void-xfce.sh -O void-xfce.sh && chmod +x void-xfce.sh && bash void-xfce.sh" + fi + ;; + 7) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install alpine-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Alpine/alpine-xfce.sh -O alpine-xfce.sh && chmod +x alpine-xfce.sh && bash alpine-xfce.sh" + fi + ;; + 8) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install fedora-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Fedora/fedora-xfce.sh -O fedora-xfce.sh && chmod +x fedora-xfce.sh && bash fedora-xfce.sh" + fi + ;; + 9) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install nethunter-rootless" + else + cmd="termux-setup-storage && pkg install wget && wget -O install-nethunter-termux https://offs.ec/2MceZWr && chmod +x install-nethunter-termux && ./install-nethunter-termux" + fi + ;; + 10) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install parrot-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AryanVBW/LinuxDroid/main/Scripts/InstallScript/Cli/parrot.sh -O parrot.sh && chmod +x parrot.sh && bash parrot.sh -y" + fi + ;; + esac + + # Execute the constructed command + eval "$cmd" +} + +# Function to install CLI version based on OS choice and Android version +install_cli_version() { + local os_choice="$1" + local cmd="" + + # Construct the appropriate command based on OS choice and Android version + case $os_choice in + 1) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install kali" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Kali/kali.sh -O kali.sh && chmod +x kali.sh && bash kali.sh" + fi + ;; + 2) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install ubuntu22" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Ubuntu22/ubuntu22.sh -O ubuntu22.sh && chmod +x ubuntu22.sh && bash ubuntu22.sh" + fi + ;; + 3) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install arch" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Arch/armhf/arch.sh -O arch.sh && chmod +x arch.sh && bash arch.sh" + fi + ;; + 4) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install debian" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Debian/debian.sh -O debian.sh && chmod +x debian.sh && bash debian.sh" + fi + ;; + 5) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install manjaro" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Manjaro/manjaro.sh -O manjaro.sh && chmod +x manjaro.sh && bash manjaro.sh" + fi + ;; + 6) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install void" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Void/void.sh -O void.sh && chmod +x void.sh && bash void.sh" + fi + ;; + 7) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install alpine" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Alpine/alpine.sh -O alpine.sh && chmod +x alpine.sh && bash alpine.sh" + fi + ;; + 8) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install fedora" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Fedora/fedora.sh -O fedora.sh && chmod +x fedora.sh && bash fedora.sh" + fi + ;; + 9) + color_text "Nethunter CLI is not available." "31" + exit 1 + ;; + 10) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install parrot" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AryanVBW/LinuxDroid/main/Scripts/InstallScript/Cli/parrot.sh -O parrot.sh && chmod +x parrot.sh && bash parrot.sh -y" + fi + ;; + esac + + # Execute the constructed command + eval "$cmd" +} + +# --- Main script --- + +# Display Android version and architecture +detect_android_version +detect_device_architecture + +# Display logo +display_logo + +# Update and upgrade packages +color_text "Updating and upgrading packages..." "32" +pkg update -y && pkg upgrade -y + +# Set up storage permissions +color_text "Setting up storage permissions..." "32" +termux-setup-storage + +# Download and install necessary packages based on Android version +if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + color_text "Installing proot-distro..." "32" + pkg install proot-distro -y +else + color_text "Installing proot..." "32" + pkg install proot -y +fi + +# Install wget and figlet +color_text "Installing wget and figlet..." "32" +pkg install wget -y && pkg install figlet -y + +# Download default bashrc +color_text "Downloading default bashrc..." "32" +curl -O https://github.com/AryanVBW/LinuxDroid/releases/download/A1/default.bashrc +chmod +x default.bashrc + +# Replace current .bashrc with default bashrc +color_text "Replacing current .bashrc with default bashrc..." "32" +rm -rf .bashrc && cp default.bashrc .bashrc + +# Display welcome message +color_text "Welcome to LinuxDroid!" "32" + +# Define array of supported operating systems +declare -a os_list=( + "Kali" + "Ubuntu 22" + "Arch" + "Debian" + "Manjaro" + "Void" + "Alpine" + "Fedora" + "Nethunter" + "Parrot" +) + +# Display OS options +for ((i=0; i<${#os_list[@]}; i++)); do + echo "$((i+1)). ${os_list[i]}" +done + +# Prompt user for the number of the OS they want to install +read -p "Enter the number of the OS you want to install: " os_number + +# Validate user input +if [[ "$os_number" -ge 1 && "$os_number" -le "${#os_list[@]}" ]]; then + selected_os="${os_list[$((os_number-1))]}" + + # Display the selected number and OS name + echo "You selected OS number $os_number: $selected_os" + + # Prompt user for GUI or CLI version + read -p "Do you want to install the GUI version? (y/n): " gui_choice + + # Install the selected OS version + if [[ "$gui_choice" == "y" ]]; then + install_gui_version "$os_number" + else + install_cli_version "$os_number" + fi +else + color_text "Invalid input. Please enter a valid number." "31" +fi + +# Display completion message +color_text "Installation completed successfully!" "32" From 9da32035b56e955d94f2feebe5af76d6b0609b24 Mon Sep 17 00:00:00 2001 From: Vivek W <92390419+AryanVBW@users.noreply.github.com> Date: Sat, 14 Dec 2024 00:00:12 +0530 Subject: [PATCH 3/4] Create LinuxDroidmenu.sh --- BETA/LinuxDroidmenu.sh | 86 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 BETA/LinuxDroidmenu.sh diff --git a/BETA/LinuxDroidmenu.sh b/BETA/LinuxDroidmenu.sh new file mode 100644 index 0000000..a5e8188 --- /dev/null +++ b/BETA/LinuxDroidmenu.sh @@ -0,0 +1,86 @@ +#!/bin/bash + +# Function to detect Android version +detect_android_version() { + local api_level=$(getprop ro.build.version.sdk) + local version_code=$(getprop ro.build.version.release) + echo "Android API Level: $api_level" + echo "Android Version Code: $version_code" +} + +# Function to detect device architecture +detect_device_architecture() { + local arch=$(getprop ro.product.cpu.abi) + echo "Device Architecture: $arch" +} + +# Function to display LinuxDroid logo +display_logo() { + echo -e "\033[96m+===================================================+\033[0m" + echo -e "\033[96m| _ _ ____ _ _ |\033[0m" + echo -e "\033[96m| | | (_)_ __ _ ___ _| _ \ _ __ ___ (_) __| ||\033[0m" + echo -e "\033[96m| | | | | _ \| | | \ \/ / | | | __/ _ \| |/ _ ||\033[0m" + echo -e "\033[96m| | |___| | | | | |_| |> <| |_| | | | (_) | | (_| ||\033[0m" + echo -e "\033[96m| |_____|_|_| |_|\__,_/_/\_\____/|_| \___/|_|\__,_||\033[0m" + echo -e "\033[96m| By Vivek W |\033[0m" + echo -e "\033[96m| |\033[0m" + echo -e "\033[96m| 🔥GitHub:- Github.com/AryanVBW |\033[0m" + echo -e "\033[96m| 🌐Site:- AryanVBW.github.io |\033[0m" + echo -e "\033[96m| 💖Instagram:- Aryan_Technolog1es |\033[0m" + echo -e "\033[96m+===================================================+\033[0m" +} + +# --- Main script --- + +# Display Android version and architecture +detect_android_version +detect_device_architecture + +display_logo + +echo -e "\e[1m\e[32mWelcome to the LinuxDroid!\e[0m" +declare -a os_list=() + +# Find and extract OS names +for file in start-*.sh; do + os_name=$(echo "$file" | sed 's/start-\(.*\)\.sh/\1/') + os_list+=("$os_name") +done + +# Add "Termux" option +os_list+=("Termux") + +# Display OS options +for ((i=0; i<${#os_list[@]}; i++)); do + echo "$((i+1)). ${os_list[i]}" +done + +# Prompt user for the number of the OS they want to run +read -p "Enter the number of the OS you want to run: " os_number + +# Validate user input +if [[ "$os_number" -ge 1 && "$os_number" -le "${#os_list[@]}" ]]; then + selected_os="${os_list[$((os_number-1))]}" + + # Display the selected number and OS name + echo "You selected OS number $os_number: $selected_os" + + # Execute the corresponding script or exit for Termux + case $selected_os in + "Termux") + echo "Exiting Termux." + exit + ;; + *) + script_name="start-$selected_os.sh" + if [[ -f "$script_name" ]]; then + echo "Executing ./$script_name" + ./"$script_name" + else + echo "Script $script_name not found." + fi + ;; + esac +else + echo "Invalid input. Please enter a valid number." +fi From 31aaf45ae60d3146019bae61234c4a19e9c68c1a Mon Sep 17 00:00:00 2001 From: Vivek W <92390419+AryanVBW@users.noreply.github.com> Date: Sat, 14 Dec 2024 00:00:45 +0530 Subject: [PATCH 4/4] Create linuxdroid.sh --- BETA/linuxdroid.sh | 154 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 154 insertions(+) create mode 100644 BETA/linuxdroid.sh diff --git a/BETA/linuxdroid.sh b/BETA/linuxdroid.sh new file mode 100644 index 0000000..3df2683 --- /dev/null +++ b/BETA/linuxdroid.sh @@ -0,0 +1,154 @@ +#!/bin/bash + +# Function to display LinuxDroid logo +display_logo() { + echo -e "\033[96m+===================================================+\033[0m" + echo -e "\033[96m| _ _ ____ _ _ |\033[0m" + echo -e "\033[96m| | | (_)_ __ _ ___ _| _ \ _ __ ___ (_) __| ||\033[0m" + echo -e "\033[96m| | | | | _ \| | | \ \/ / | | | __/ _ \| |/ _ ||\033[0m" + echo -e "\033[96m| | |___| | | | | |_| |> <| |_| | | | (_) | | (_| ||\033[0m" + echo -e "\033[96m| |_____|_|_| |_|\__,_/_/\_\____/|_| \___/|_|\__,_||\033[0m" + echo -e "\033[96m| By Vivek W |\033[0m" + echo -e "\033[96m| |\033[0m" + echo -e "\033[96m| 🔥GitHub:- Github.com/AryanVBW |\033[0m" + echo -e "\033[96m| 🌐Site:- AryanVBW.github.io |\033[0m" + echo -e "\033[96m| 💖Instagram:- Aryan_Technolog1es |\033[0m" + echo -e "\033[96m+===================================================+\033[0m" +} + +# Function to display colored text +color_text() { + local text="$1" + local color="2" +echo \-e "\\e\[{color}m$text\e[0m" +} + +# Function to install GUI version based on OS choice and Android version +install_gui_version() { + local os_choice="$1" + local cmd="" + + # Construct the appropriate command based on OS choice and Android version + case $os_choice in + 1) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install kali-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Kali/kali-xfce.sh -O kali-xfce.sh && chmod +x kali-xfce.sh && bash kali-xfce.sh" + fi + ;; + 2) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install ubuntu22-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Ubuntu22/ubuntu22-xfce.sh -O ubuntu22-xfce.sh && chmod +x ubuntu22-xfce.sh && bash ubuntu22-xfce.sh" + fi + ;; + 3) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install arch-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Arch/armhf/arch-xfce.sh -O arch-xfce.sh && chmod +x arch-xfce.sh && bash arch-xfce.sh" + fi + ;; + 4) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install debian-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Debian/debian-xfce.sh -O debian-xfce.sh && chmod +x debian-xfce.sh && bash debian-xfce.sh" + fi + ;; + 5) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install manjaro-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Manjaro/manjaro-xfce.sh -O manjaro-xfce.sh && chmod +x manjaro-xfce.sh && bash manjaro-xfce.sh" + fi + ;; + 6) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install void-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Void/void-xfce.sh -O void-xfce.sh && chmod +x void-xfce.sh && bash void-xfce.sh" + fi + ;; + 7) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install alpine-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Alpine/alpine-xfce.sh -O alpine-xfce.sh && chmod +x alpine-xfce.sh && bash alpine-xfce.sh" + fi + ;; + 8) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install fedora-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Fedora/fedora-xfce.sh -O fedora-xfce.sh && chmod +x fedora-xfce.sh && bash fedora-xfce.sh" + fi + ;; + 9) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install nethunter-rootless" + else + cmd="termux-setup-storage && pkg install wget && wget -O install-nethunter-termux https://offs.ec/2MceZWr && chmod +x install-nethunter-termux && ./install-nethunter-termux" + fi + ;; + 10) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install parrot-xfce" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AryanVBW/LinuxDroid/main/Scripts/InstallScript/Cli/parrot.sh -O parrot.sh && chmod +x parrot.sh && bash parrot.sh -y" + fi + ;; + esac + + # Execute the constructed command + eval "$cmd" +} + +# Function to install CLI version based on OS choice and Android version +install_cli_version() { + local os_choice="$1" + local cmd="" + + # Construct the appropriate command based on OS choice and Android version + case $os_choice in + 1) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install kali" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Kali/kali.sh -O kali.sh && chmod +x kali.sh && bash kali.sh" + fi + ;; + 2) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install ubuntu22" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Ubuntu22/ubuntu22.sh -O ubuntu22.sh && chmod +x ubuntu22.sh && bash ubuntu22.sh" + fi + ;; + 3) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install arch" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Arch/armhf/arch.sh -O arch.sh && chmod +x arch.sh && bash arch.sh" + fi + ;; + 4) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install debian" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Debian/debian.sh -O debian.sh && chmod +x debian.sh && bash debian.sh" + fi + ;; + 5) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install manjaro" + else + cmd="pkg update -y && pkg install wget curl proot tar -y && wget https://raw.githubusercontent.com/AndronixApp/AndronixOrigin/master/Installer/Manjaro/manjaro.sh -O manjaro.sh && chmod +x manjaro.sh && bash manjaro.sh" + fi + ;; + 6) + if [[ $(getprop ro.build.version.sdk) -ge 30 ]]; then + cmd="proot-distro install void" + else