iSH Shell
apps.apple.com
apps.apple.com
> Unfortunately, I made the decision to write nearly all of the gadgets in assembly language. This was probably a good decision with regards to performance (though I'll never know for sure), but a horrible decision with regards to readability, maintainability, and my sanity. The amount of bullshit I've had to put up with from the compiler/assembler/linker is insane. It's like there's a demon in there that makes sure my code is sufficiently deformed, and if not, makes up stupid reasons why it shouldn't compile. In order to stay sane while writing this code, I've had to ignore best practices in code structure and naming. You'll find macros and variables with such descriptive names as ss and s and a. Assembler macros nested beyond belief. And to top it off, there are almost no comments.
> So a warning: Long-term exposure to this code may cause loss of sanity, nightmares about GAS macros and linker errors, or any number of other debilitating side effects. This code is known to the State of California to cause cancer, birth defects, and reproductive harm.
M…maybe I'll hold off on that PR.
# also hell {{{
.ifin(\op, bt)
read_bullshit \size, \op\size\()_mem
.endifin
.ifin(\op, btc,bts,btr)
write_bullshit \size, \op\size\()_mem
.endifin
# }}} cd
wget http://dl-cdn.alpinelinux.org/alpine/latest-stable/main/x86/apk-tools-static-2.10.5-r1.apk
cd /
tar xvzf ~/apk-tools-static-2.10.5-r1.apk
ln -s /sbin/apk.static /sbin/apk
cd
apk# apk add R
And I finally have R on my iPad!
iPhone:~# wget http://dl-cdn.alpinelinux.org/alpine/latest-stable/main/x86/apk-tools-static-2.10.5-r1.apk
wget: bad address 'dl-cdn.alpinelinux.org' mount -t ios . /mnt
# Pick "Downloads" from "On My iPad" in the GUI
Then you can run tar xvzf /mnt/apk-tools-static-2.10.5-r1.apk
When you cd to the root.Though, I suspect apk itself will fail if you can't resolve domain names.
Edit: As gorkish points out, make sure iSH has network permissions first and try again with the original command.
So theoretically it could be like an isolated computer game and have no access to anything from the underlying iOS environment. (Maybe it does let you access iOS's filesystem—it's not clear to me at a first glance.) I have the jaded feeling that this has to do with how it got approved.
https://github.com/ish-app/ish/wiki/Mounting-other-file-prov... says: "Additionally, if jailbroken or using the psychic paper exploit (not available through TestFlight nor will we help you do it), you can also mount using real, absolute paths. To do so run "mount -t real <src> <dst>", where <src> is the absolute path from the root of iOS and <dst> is the location in iSH to mount the file." Which suggests that you can only touch the underlying iOS if you've done an exploit.
iSH emulates 32-bit alpine x86 and can install things from apk
Pythonista is much more pleasant today for actually writing code in, though.
Nice:) got a chuckle out of me...
For example the nano text editor.
EDIT: Managed it like this:
1. Download this file and put it on iCloud Drive: http://dl-cdn.alpinelinux.org/alpine/v3.12/releases/x86/alpi...
2. Back in the app, tap the Cog icon above the keyboard > Filesystems > Import > select that file.
3. (The app crashed?) Start the app again and go back to the Cog > Filesystems > alpine-minirootfs-.... > Boot from This Filesystem
4. $ apk add nano
5. $ nano
EDIT2: And now git installs fine too. Gonna have some fun with this!
https://twitter.com/PaulGowder/status/1319409818554241025?s=...
I guess you might be able to bootstrap homebrew, nix or something like that?
Now it's time to complain: The search string "ish" (just like that) on the App Store doesn't even turn iSH up, at all. It might have been somewhere after the first ten results, I guess.
App Store search is the absolute worst, and regularly turns up garbage ripoff apps that Apple should never have allowed on the store in the first place. It's the worst part of the ecosystem, and I despair of them ever doing something about it.
You'd think a company with a few hundred billion dollars of cash just sitting around could handle something like this...
If this wasn't a case of something which routinely happens to me, I wouldn't have said anything.
I wouldn't be surprised if iSH becomes the top result for that search string. But I wouldn't be surprised if it's number 2, after some obvious ripoff, either.
So, iSH does this amazing stuff by x86 emulation. Aren't iOS devices arm based devices ? Why should they emulate x86 ? Isn't it easier to emulate arm64 linux instead ?
(I mean that arm64 binaries can run on arm64 devices. For example, consider wine which runs windows programs on linux/macos. Only x64 windows apps can run on x64 wine and only arm64 windows apps can run on arm64 devices. To run x64 windows apps on arm64 devices,you need qemu/other virtualization software)
Unless it’s JavaScript. I see a missed opportunity here: compile everything to ASM.js! :)
I’m only half-kidding.
Imagine what developers could do if Apple loosened those restrictions a bit.
EDIT: added slightly. For all the OS calls which are 100% native, it wouldn’t matter.
Here are some good use cases I've used iSH for:
- youtube-dl videos to Files app
- SSH into remote servers
- performing network pings or scans discretely
There's even a device at /dev/location which when catted can keep the app active in the background, due to background app refresh. The only real issue I've had (especially with Python programs) is that it runs orders of magnitude slower than native.
Some commands seem to hang forever, until the app is killed ‘ reset.
My experience with termux on an old nexus 7 was much better than iSH on a 2017 iPad Pro.
I also tried installing some npm packages but ran into permission issues.
Re: permission errors, might be due to the fact that you are root by default and should add a new non-root user (via useradd).
https://github.com/ish-app/ish/issues/249
> You can now keep the app running in the background with the invocation cat /dev/location > /dev/null &
On Android it's not automatic or automated and the user has to do it by hand himself (for obvious reasons); but for a few specific apps it allows them to work the way they should without needing weird permissions to emulate
> UPDATE: We record significantly increased number of app killing on Samsung's Android Pie flavor. The hints show adaptive battery being much more eager than in stock Android.
> After 3 days any unused app will not be able to start from background (e.g. alarms will not work anymore). Imagine, you won't use your alarm clock for a the weekend +1 day and bang! no alarms any more and you miss work! We strongly suggest to turn off Adaptive battery and Put apps to sleep options per instructions below.
Maybe this, or similar methods, is how Apple begins to enable development on iOS, through full app-based systems that are completely isolated from the underlying OS.
Now they just need to allow UTM in the App Store.
0: https://github.com/utmapp/UTM/blob/1feb721a9474255bd112f9e42...
This GitHub issue has more info:
Janet can be parsed using a PEG parser, so I think that causes it to lose some expressivity of Lisp.
Janet is a cool language though, I like it. I wish there was a decent tutorial instead of just language reference docs. And the Core API documentation is a bit poor in my opinion. I’m trying to submit examples to Core API documentation, I’m hopeful it will get better in time.
I mean, if it shows up in the Files app, you can mount it and run normal things against that folder.
The thing I want to see, though, is a folder for the photos app. That doesn't exist, since the Photos app doesn't expose it's data as a folder.
Because it's the iphone and periodic background tasks are always malware.
There's logic in the madness. Barely.
Simply go to the [0]download page, look for "mini root filesystem" and download x86, or simply click this [1]link
Upload this to your iPhone. Then in the iSH settings find the "filesystems" section and click "import".
[0]: https://alpinelinux.org/downloads/
[1]: http://dl-cdn.alpinelinux.org/alpine/v3.12/releases/x86/alpi...
For example: https://github.com/ish-app/ish/wiki/Running-a-Python-Web-Ser....
The bit about TestFlight is certainly interesting but the best way to communicate it is not via the title but via a comment in the thread...like you just did!
I love the idea of a shell on iOS but why does it need to know my location?
This seems like a workaround so that the app can continue running in the background.
> The iSH app ("iSH") is made available to you by the developers of the application (collectively, the "iSH developers") under the terms available at https://github.com/ish-app/ish/blob/master/LICENSE.md (the "License"). These license terms are an agreement (the "Agreement") between you and the iSH developers, not Apple, which disclaims responsibility of the licensed application and its contents thereof, and replaces the terms of the standard Licensed Application End User License Agreement available at https://www.apple.com/legal/internet-services/itunes/dev/std.... The iSH developers own the intellectual property of iSH and provide it to you under the License without warranty to the fullest extent permitted by law. Apple and Apple's subsidiaries are not legally liable for product claims, including claims for maintenance and support, but may at their discretion choose to enforce this agreement against you as third party beneficiaries of iSH. In cases where certain provisions laid out in this Agreement are in conflict with local laws and cannot go into effect, the remaining provisions will continue to apply in full force. Questions or any other requests about this Agreement may be directed at Theodore Dubois, available at tbodt@ish.app.
Ctrl-[ :q!
Knowing Ctrl-[ for escape has saved me enough times.⌃ is control
⎋ is escape
the arrow keys thing can be dragged to move the cursor around