Coding on an iPad Pro

So, I have an iPad Pro. And I want to use it for coding.

I use it mostly to do artwork (I also have an art blog) and quite recently I picked up a keyboard so I can do some writing. Mostly working on comic scripts, because I like to think I’m man of many talents, but mostly to silence the voices in my head.

It got me to thinking, if I have an iPad Pro, and I have a keyboard. Why can’t I use this combination to write code?

(If you want step by step instructions, read my actual instructions for Setting up an iPad Pro with Coda and Amazon Lightsail for Coding)

Some time ago, I had dabbled in some coding on my iPhone (and Android before I switched over to iOS because of reasons) and remembered a few apps that were essentially interactive shells, but nothing useful for writing “production” code. This was some time ago, so I had hoped there’d be some new development (pun not intended?) in using tablets and mobile devices for coding.

Not an Ad. I’m just linking to things that I’ve used to support the developers.

Sad to say, there wasn’t much on the iOS side that was useful. There were a few apps, like VIM for iOS and JSAnywhere that were kinda nifty, but again, still siloed and not really useful. Overall, the biggest players, in my opinion, were CodeAnywhere and Coda. I’m sure I could write some serious articles about both of them, and I probably will in the near future, but ultimately I found Coda to be the most useful for my purposes.

Coda VS Code Anywhere

Long story short, a lot coding that I do outside of my “day job” ranges from basic webmaster stuff like “My WordPress Site” or “custom HTML thingie my nephew wrote” doesn’t work to prototype a React/Redux thingie for fun. CodeAnywhere and Coda worked great for the former, not as great for the latter, at least not immediately out of the box.

I had been using CodeAnywhere for some time for one specific client, as she required simple html changes from time to time. CodeAnywhere let me set up a simple ftp connection to her site and I could jump in from anywhere to make changes. In one case, over my iPhone, while I was commuting into my day job.

The specifics are beyond this article, but simply put, if I had my physical keyboard connected, the software keyboard for CodeAnywhere would push the code up and off-screen, where I couldn’t see what I was coding. No bueno CodeAnywhere.

So where am I going with this?

I started digging around (links at the end) for other people’s experiences with trying to set up an iPad Pro for coding, and came to the conclusion that an I’d be better off treating the iPad Pro as s thin client rather than a dev machine. This approach would actually be ideal, because I wouldn’t have to worry about code syncing or machine performance, since everything would work through SSH. The downside would be that I’d be required to have an internet connection.

Sticking with CodeAnywhere, I realized that their service was kind of doing the same thing, and maybe I could try using ssh to connect to my CodeAnywhere remote box. This worked, but the trouble was that I was using the “Free” version and the machine would go offline. While that doesn’t sound like a deal breaker, I found that I had to log into CodeAnywhere via a desktop browser to wake up the virtual machine. Kind of annoying and counter productive if I was traveling with only my iPad Pro.

By this point, I had the same revelation that you might have had: Why not Amazon?

Amazon

Seriously. This is not an ad.

While I was reading up about EC2 and other Amazon Services, I had also started reading more about Coda for iOS. I had considered using Coda as a desktop IDE for OSX back years ago, but I ended up going down the TextMate route instead. That’s a story for another day, but I always kind of kept my eye on Coda over the years and was intrigued at how it progressed on iOS.

Screenshot stolen from Panic, Coda’s manufacturer.

I decided to bite the bullet and pick up a copy of it, and try to set up EC2. For me, the difficulty wasn’t setting up Coda, but ultimately EC2 itself. There was just too many options and it was kind of overwhelming. However, all my furious googling for EC2 instructions lead me towards Lightsail, a new product (as of this writing) from Amazon.

Light at the end of the tunnel

If I had to describe Lightsail, I’d say it’s EC2 for newbs. I had a simple node server set up in under a half hour, that I was able to ssh in from a browser in no time. Setting it up via iTerm2 was just as easy.

The hard part, was the iPad.

The biggest hurdle for me was getting my public key onto the iPad, since of course, Amazon expects you to be using a desktop computer, with a file system. A this point, I’m sure all of you Android fanboys are rolling your eyes at me, but whatever.

Getting the key set up with Coda was troublesome, but ultimately I got it working by copying the .pem file over to my iPad Pro via iTunes. I hated myself for doing it this way, but it worked, and yeah, I now have an iPad Pro that I can do actual code on.

Now, onto getting Git set up…

Step by step Instructions: Setting up an iPad Pro with Coda and Amazon Lightsail

More Reading:

Leave a Reply

Your email address will not be published. Required fields are marked *