tursodatabase / turso-cli

Command line interface to Turso.
https://turso.tech
MIT License
223 stars 37 forks source link

Add Termux install documentation #713

Open tsanyqudsi opened 1 year ago

tsanyqudsi commented 1 year ago

I know it might be insignificant, but it happened to me because I somehow forgot to bring my laptop during my business trip.

I suddenly got a crazy idea since I heard about Termux years ago but never use it before. "Use my android phone to code, and start learning neovim !!".

Alas, it didn't go as planned, Turso CLI crashed

SIGSYS: bad system call
PC=0x12f80 m=8 sigcode=1

goroutine 8 [syscall]:
syscall.Syscall6(0x4000515920?, 0x27?, 0x27?, 0x4000515950?, 0x0?, 0x4f?, 0xffffffffffffff9c?)
        syscall/syscall_linux.go:91 +0x2c fp=0x4000463460 sp=0x40004633d0 pc=0x8f3ec
syscall.faccessat2(0x4000515920?, {0x4000515920?, 0xddc67a200998?}, 0x1, 0xc0?)
        syscall/zsyscall_linux_arm64.go:33 +0x84 fp=0x40004634d0 sp=0x4000463460 pc=0x8b674
syscall.Faccessat(0x4000515920?, {0x4000515920, 0x27}, 0x1, 0x200)
        syscall/syscall_linux.go:167 +0x3c fp=0x40004635c0 sp=0x40004634d0 pc=0x88f8c
internal/syscall/unix.Eaccess(...)
        internal/syscall/unix/eaccess_linux.go:10
os/exec.findExecutable({0x4000515920, 0x27})
        os/exec/lp_unix.go:31 +0x58 fp=0x4000463610 sp=0x40004635c0 pc=0x11f0c8
os/exec.LookPath({0x199a40b, 0x3})
.....

Apparently it's a go issue and from the looks of it, There's no hope so far.

However, there's a comment here that made me wonder. As desperate as I am now, I decided to install proot and use ubuntu as my termux distro.

pkg install proot
pkg install proot-distro
proot-distro install ubuntu
proot-distro login ubuntu

After that I tried to install Turso-cli again, guess what ? It works !!

I haven't tried the rest of the distros offered by termux yet since it works with my first choice, but I think you should add this to documentation for the sake of helping people that forgot their laptops while going somewhere far.

tsanyqudsi commented 1 year ago

Screenshot_20231101_015910_Termux

haaawk commented 1 year ago

All turso cli does can be done through HTTP API so as an alternative you could just use curl :).

tsanyqudsi commented 1 year ago

I know, but turso cli is really helpful