-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathOpenCode.sh
More file actions
63 lines (30 loc) · 979 Bytes
/
Copy pathOpenCode.sh
File metadata and controls
63 lines (30 loc) · 979 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
pkg update && pkg upgrade -y
pkg install -y proot-distro git curl wget nano
termux-setup-storage # Storage permission
ls ~/storage/shared # Test it
# Making the Project Folder
mkdir -p ~/storage/shared/OpenCodeProjects
# Installation of Debian
proot-distro install debian
proot-distro login debian # as root user
apt update && apt upgrade -y
# Installation of Node.js
apt install -y curl git build-essential ca-certificates nodejs npm
node --version
npm --version
# Installation of OpenCode
npm install -g opencode-ai
opencode --version
# How to Start
proot-distro login debian --bind ~/storage/shared:/mnt/shared
cd /mnt/shared/OpenCodeProjects/myproject
opencode
# Make the Launcher to direct open it
nano ~/opencode.sh
#!/data/data/com.termux/files/usr/bin/bash
proot-distro login debian --bind ~/storage/shared:/mnt/shared
# Ctrl+O -> Enter -> Ctrl+X
chmod +x ~/opencode.sh
~/opencode.sh
cd /mnt/shared/OpenCodeProjects/myproject
opencode