AWS Cloud9 now works on an iPad
I've been using Cloud9 as my main IDE for years, since before Amazon bought them. Sitting here with an anemic bottom-barrel 2015 Macbook Pro with just 8GB of RAM and 128GB of SSD doesn't leave a lot of wiggle room. It's hard to just take a new language for a spin, having to install all the dependencies and frameworks and nonsense that comes with programming. Cloud9 was a breath of fresh air when I found it. And since Amazon bought it, it's gotten even better (although slowly).
The biggest driver keeping me on Cloud9 is AWS's auto-sleep feature. If I stop using the IDE for 30 minutes, it'll shut down the EC2 instance that's running behind the scenes and stop billing me for it. That's a pretty huge deal. Right now I have 8 Cloud9 instances on my AWS account and my monthly bill is about $3. It's also free for a year if you qualify for the free tier. It's a fully-fledged IDE with full root access to a full Linux system under the hood. It's a full development/test environment, letting you run your code and see it work in a real browser. Postgres and Redis running too. I mean, it's the real deal.
But one thing that's bothered me for a while was the lack of iPad support. I mean... it's a browser based tool! Why shouldn't it work? It kind of worked in iOS12, except Safari didn't support some keyboard keys necessary to navigate the code. iPadOS 13 seemed promising, but Cloud9 needed third party cookies and Safari on iOS13 and 13.1 didn't actually support enabling third party cookies. But along comes iOS13.2 and a quick update from AWS and we're in business!
There are still some downsides of Cloud9 though. It's hard to get your running instance accessible from outside of your browser window, for example. Meaning if you want to see how your code runs on a real phone (not just Chrome's impersonation of a phone), there are a ton of poorly documented hoops to jump through. And if you have a decoupled front/back end, you'll either need to jump through these hoops or run both servers on the same Cloud9 instance. You can't test your APIs with Postman without the same headaches. There's also extremely limited and experimental plugin features. For the most part, what you see is what you get. Which is fine for me, so hooray!
But why would you want to code on an iPad?
Hipster cred, mostly. Joking aside, I read this article on coding on an iPad years ago and I've never been able to shake the feeling that this should be possible. And I shouldn't have to use Vim when Cloud9 exists in a browser.
I travel a lot for work, and I also maintain an ever-growing stable of side project that need occasional maintenance. If I'm expecting to be on-call for something on a side project, I'm not doing that work on my corporate laptop. So I end up bringing two laptops, plus an iPad to read comics/books during the flight, plus two phones. It just gets to be a lot. Even when I head down to my local co-working space, I'm often lugging two laptops, just to work in an application that's browser based but for some reason doesn't work on every browser. Until now.
But while his VPS cost him $20/mo way back then and a modern equivalent is just $5, I don't program often enough to rent a server full time. And I like the ability to spin up/down new instances whenever I want but only pay for them when I'm using them. That's a pretty awful experience on Linode or DigitalOcean etc. With an EC2 instance you can sleep, but your IP address goes away unless you pay $5/mo to keep it, which defeats the purpose. Cloud9 makes those problems go away.
I should mention the Lightning->HDMI adapter works nicely, too.
Most of the time I'm coding on my Macbook using Cloud9. Maybe that'll change now that the iPad works, but we'll see. I do all of my personal projects in Cloud9. Three Rails apps, an Elixir/Phoenix app, a Flask microservice, a Nodejs microservice, all developed 100% entirely on Cloud9. One of the Rails apps actually pre-dates the AWS acquisition, and I'm still actively maintaining it using Cloud9 with thousands of lines of code. The only things I write locally are things I don't plan on putting into production (bash and python scripts, mostly).
Besides the base model 2015 rMBP, I have a base model 2019 iPad with the official Lightning-HDMI adapter. Unfortunately the adapter only mirrors and does not do full 1920x1080 (it stays at the same aspect ratio as the iPad itself). I have a Logitech K380 keyboard that lets me quickly switch between three different devices (my personal Mac, my corporate laptop, and my iPad). On my laptop I use Chrome for the developer tools. Now that iPadOS supports mice, I also connect a Bluetooth mouse sometimes, although getting used to long-clicking rather than right-clicking is weird. Other than that, the mouse and keyboard work swimmingly.
Before Cloud9 worked on an iPad, I used to SSH into the instance with the help of Termius and mosh, but I've never been super comfortable at editing multiple files at a time in Vim.
Do I actually do this?
Mark O'Connor in that blog post got quite a bit of flak on Hacker News for wanting to code on an iPad. But I get it, Mark. It's liberating. It's not especially ergonomic unless you have an external monitor or some kind of stand for your iPad, but having basically a single-purpose machine is great. The number of times I've had to wait for a React app to recompile and in those 10 seconds I've switched to another browser window and then 15 minutes later I come back to finally try the code... I have a short attention span. The easier it is for me to multitask, the more likely I am to multitask. The iPad is awful at multitasking, so it keeps me focused. And everything is full screen by default.
If nothing else, it's a great idea. Much like coding in LISP or Haskell, you might not use it every day but the concepts you learn can be applied to your normal routine. For instance, I pretty much always keep my active window full-screened on a virtual desktop on my Macbook, and I hide the dock and top bar. Removing distractions helps keep my mind in the zone.
So we'll see, now that Cloud9 supports iPad, we'll see how much I take advantage of it. Especially, like with Mark O'Connor's blog post from so long ago, my Macbook is getting a little long in the tooth and ready to be replaced... but there's not a single laptop on the market today that I'm excited for. The iPad may become my daily driver sooner rather than later. Maybe I can talk my wife into letting me get a 12” iPad Pro...
Other iPad programming resources
Cloud9 isn't the only tool, and there's a pretty nice market for iPad apps for programmers. It's growing for sure, and with the iPad Pro and enhancements in iPadOS, I think it'll keep growing. People use 11” Macbook Airs and 12” Macbooks, so is a 10” iPad or 12” iPad Pro so strange?
Pythonista is pretty good, or so I've heard.
Panic's Code Editor is a pretty full-featured programming suite.