Blink Shell for iOS (edited for more shell utils)
Do Blink! Blink is the first professional, desktop-grade terminal for iOS that leverages the support of Mosh and SSH. Thus, we can unequivocally guarantee stable connections, lightning-fast speeds, and full configurations. It can and should be your all-day-long tool.
We did not create another terminal to fix your website on the go. Blink was built as a professional grade product from the onset. We started by analyzing what the must-haves were and we ended up grounding Blink on these three concepts:
- Fast rendering: dmesg in your Unix server should be instantaneous. We can't wait even a second to render. We didn't need to reinvent the wheel to make this happen. We simply used Chromium's HTerm to ensure that rendering is perfect and fast, even with those special, tricky encodings.
- Always on: Mosh transcends SSH's variability. Mosh overcomes the unstable and intermittent connectivity that we all associate with mobile connections. You can check your Safari without fear of having to restart the SSH connection. You can flawlessly jump from home, to the train, and then the office thanks to Mosh. Blink is rock-solid connected all the way. Mosh is readily available and can be easily installed on your server. Go to https://mosh.org.
- Fully configurable: Blink embraces Bluetooth-coupled keyboards with gusto. Some like Caps as Esc on Vim, others Caps as Ctrl on Emacs. Blink champions them all. But there's more, because we want more. You can also add your own custom themes and fonts to Blink. During your always-on sessions, you're in your zone.
But, Blink is much more. Please read on:
- You should command your terminal, not navigate it. Blink will jump you right into a friendly shell and it'll be clear to you how to roll.
- The interface is straightforward. We dumped all menus and went full screen for your terminal.
- Use swipe to move between your open connections, slide down to close them, and even pinch to zoom!
- Configure your Blink connections by adding your own Hosts and RSA Encryption keys. Everything will look familiar and you get to work, fast!
- We've incorporated SplitView, for those necessary Google searches and chats with coworkers.
For more information, please visit Blink Shell.
This fork also contains a set of shell utilities, so you can add / remove files, list them, etc.
Specifically, the commands available (as of now) are:
cd, setenv, ls, touch, cp, rm, ln, mv, mkdir, rmdir, df, du, chksum, chmod, chflags, chgrp, stat, readlink, compress, uncompress, gzip, gunzip,
pwd, env, printenv, date, uname, id, groups, whoami, uptime
cat, grep, wc
curl (includes http, https, scp, sftp...), scp, sftp
You can call commands individually, or use small scripts using python or lua. There is redirection (">", "<", "&>" ...), but no pipe.
All these commands are inside the
ios_system.framework (precompiled, for facility). If you want to edit the source (to add more commands), see: https://github.com/holzschu/ios_system .
I suggest installing iVim (https://github.com/terrychou/iVim or https://itunes.apple.com/us/app/ivim/id1266544660?mt=8 ) and use iOS 11 "edit-in-place" to edit files inside Blink sandbox.
curl opens access to file transfers to and from your iPad (ftp, http, scp, sftp...). It uses the key management of BLINKSHELL (the keys you created with "config"). You can also specify keys with a path:
curl scp://host.name.edu/filename -o filename --key $SHARED/id_rsa --pass MyPassword
You can also use the scp and sftp commands:
scp firstname.lastname@example.org:filename . sftp localFilename email@example.com:~/
scp and sftp are implemented through curl, by rewriting the arguments to follow the curl syntax. Pro: lighter implementation, smaller memory cost, less likely to have function name collisions. Con: some switches might not have exactly the same meaning.
The language packages (Python, Lua and TeX) only provide the equivalent of the binaries. It is up to you to transfer the directories with the packages (
/usr/lib/python2.7), and place them in the Library folder of the Blink application. This is where commands such as ls, rm, tar, mv... will be useful.
Note: all frameworks (except curl) are dynamic frameworks, to reduce the Application memory footprint.
In iOS, because of sandbox restrictions, you cannot write in the
~ directory, only in
~/tmp. Most Unix programs assume the configuration files are in
$HOME. So either you redefine
~/Documents/ or you set configuration variables (using
setenv) to some other place.
I do this in Blink, inside the
MCPSession.m file. The following variables are defined:
setenv PATH = $PATH:~/Library/bin:~/Documents/bin setenv PYTHONHOME = $HOME/Library/ setenv SSH_HOME = $HOME/Documents/ setenv CURL_HOME = $HOME/Documents/ setenv HGRCPATH = $HOME/Documents/.hgrc/ setenv SSL_CERT_FILE = $HOME/Documents/cacert.pem
If you want to change them permanently, it's probably best to edit
Blink is available now on the AppStore. Check it out!
If you would like to participate on its development, we would love to have you on board! There are two ways to collaborate with the project: you can download and build Blink yourself, or you can request an invitation to help us test future versions (on the raw branch). If you want to participate on the testing, follow and tweet us @BlinkShell about your usage scenarios. Invitations will be sent out in waves, please be patient if you do not receive yours immediately.
Bugs should be reported here on GitHub. Crash reports will be automatically reported back to us thanks to HockeyApp. If you have any questions or want to make sure we do not miss on an interesting feature, please send your suggestions to our Twitter account @BlinkShell. We would love to discuss them with you! Please do not use Twitter to report bugs.
We can't wait to receive your valuable feedback. Enjoy!
We made a ton easier to build and install Blink yourself on your iOS devices through XCode. We provide a precompiled package with all the libraries for the master branch. Just extract this package in your Framework folder and build Blink.
git clone --recursive https://github.com/blinksh/blink.git && \ cd blink && ./get_frameworks.sh
This will download Blink and the associated frameworks:
Although this is the quickest method to get you up and running, if you would like to compile all libraries and resources yourself, refer to BUILD. Please let us know if you find any issues. Blink is a complex project with multiple low level dependencies and we are still looking for ways to simplify and automate the full compilation process.
The precompiled version of
ios_system already containes the
lua "binaries", but not their associated modules.
If you want to use python, you will have to transfer the python modules. On your computer:
curl -OL https://www.python.org/ftp/python/2.7.13/Python-2.7.13.tgz tar -xvzf Python-2.7.13.tgz rm Python-2.7.13.tgz cd Python-2.7.13/ tar -cvzf packages.tar.gz Lib/
transfer the file
packages.tar.gz to your iOS device, using iTunes or the scp command in Blink.
On your device:
cd ~/Library/ mkdir lib/ tar -xvzf ~/packages.tar.gz mv Lib lib/python2.7 cd ~
Our UI is very straightforward and optimizes the experience on touch devices for the really important part, the terminal. You will jump right into a very simple shell, so you will know what to do. Here are a few more tricks:
- Type 'help' to find information at the shell.
- Use two fingers tap to create a new shell.
- Move between shells by swiping your finger.
- You can exit the session and get back to the shell to open a new connection.
- You can also close a session by dragging two fingers down.
- Use pinch gesture to increase or reduce size of text. You can also use Cmd+ or Cmd- if using the keyboard.
- Copy and Paste by selecting text o tapping the screen.
- Run 'config' to setup your keys. Install them to a server through ssh-copy-id.
- Ctrl and Alt modifiers at the SmartKeys bar allow for continuous presses, like in a real keyboard.
- Mosh was written by Keith Winstein, along with Anders Kaseorg, Quentin Smith, Richard Tibbetts, Keegan McAllister, and John Hood.
- This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/).
- Entypo pictograms by Bruce Daniel www.entypo.com.