Friday 8 November 2013

How Can I Use an iPad for Web Development and Programming?




Bug alert! But you're on the road. All you have is your iPad, and maybe a Bluetooth keyboard. What to do? The Apple devs at Stack Exchange offer up some wisdom on developing on the road.P
The iPad is my preferred computing device when I'm on the go. Sometimes I've got a Bluetooth keyboard with me, and sometimes I don't. This may be crazy, but I would like to use my iPad for full-fledged web development and programming, and want I to know what my options are. Cloud9 seems to be nearly perfect for this in concept except for a fatal flaw: the web interface does not fully work with iPad browsers Safari or Chrome. You cannot, for example, double click to open files. What other options do I have? Ideally I would like to have command line access to my editor of choice (Vim), and be able to use web debugging tools like the developer tools in Chrome.P
See the original question.P
A Couple Quick Reccomendations (Answered by slothdog)P

If you're just looking for a straight text editor, Textastic has a lot of nice features. For full-fledged web development, check out Diet Coda. It has built-in SSH terminal, SFTP, a great text editor, etc.P
iOs Vim + Firebug Lite (Answered by Aaron Miller)P

I was all ready to call you mad, but this is looking considerably more workable than I'd have thought. There is an iOS port of Vim, and if that doesn't work well then you can always use one of many terminal emulators to shell into a remote host and run Vim there. I might recommend the latter ahead of the former, actually; it's not clear how you're expected to get files onto the device for editing and then put them back into their testing environment, whereas running Vim directly on the testing host obviates the concern entirely. Multitasking is a concern here, in that if the emulator doesn't get any CPU time then your connection will time out, but judicious use of GNU Screen, and perhaps an emulator such as Prompt which can maintain connections for a while even when backgrounded, should relieve that problem pretty handily.P
As for debugging tools, the ones built into Safari only work when your device is tethered to a computer running the desktop version, but Firebug Lite is said to work in iOS Safari and presumably would work just as well in iOS Chrome, and its bookmarklet can be added to the browser's bookmarks bar for easy access. (It doesn't seem to be working right now in any of the three browsers in which I've tried it, including Safari on my iPhone, but I suspect that's a transient issue related to the apparently quite recent release of a new version with major changes.) Being similarly equipped with an iPad and Bluetooth keyboard, I'd considered trying the same thing you're looking to do, but wrote it off as unworkable. Thanks for giving me the impetus to investigate further and discover that it can very likely be done pretty well after all.P
Read Mark O'Connor (Answered by Dan J)P

Mark O'Connor has written a compelling series of articles (starting with this one about doing web development using an iPad as a thin client to a Linux remote server). You basically just need an SSH client app for the iPad (there are several: Mark mentions iSSH), and you have access to VIM or whatever other tools you can run on the server.P
Debugging & Editing Options: A Little More in Depth (Answered by robmathers)P

Doing development on an iPad is definitely possible, but how well it works for you will depend a lot on your workflow. In particular, you may run into trouble when it comes to debugging, especially if you need a good JavaScript debugger. I recently tried some editing of a (mostly JavaScript) webapp I've been working on using my iPad. The editing went relatively smoothly (I used Textastic, but debugging the JavaScript was a pain.P
As far as I'm aware, the only thing that comes close to a proper debugging tool on iOS isFirebug Lite, which has some substantial limitations. Because it's not integrated into the browser, it can't catch a lot of problems. No syntax error catching (you're left hunting for that missing bracket on your own), and no reporting of HTTP issues if an external script isn't loading properly. The interface is also pretty rough to use on a touch device—small tap targets, and it resizes strangely if you try to zoom. As someone who relies a fair bit on Safari and Chrome's developer tools when doing JavaScript development, I found it fairly frustrating when I ran into any sort of bug. That said, if your development is more server-side, or you otherwise don't depend on those sorts of debugging tools, the iPad could very well make a good development environment for you.P
If you just want to use Vim, then an SSH client like Prompt or iSSH would work well, combined with a remote server somewhere (which you'll need anywhere for viewing files). If you want an option that doesn't require network access, there is an iOS port of Vim, but it's worth noting that the files are only accessible through iTunes (i.e. you can't upload them to an SFTP server or view them locally with Safari). If you want a more native experience, Diet Coda is worth a look, as it integrates a lot of useful tools—SFTP, a full SSH client, code editor, and browser. It's definitely on the pricier side of iOS apps, but I've read good things about it.P
Textastic is another good editor, with some nice extensions to the software keyboard (useful for making changes in a pinch if you don't have a Bluetooth one with you). I'm not a big fan of its file access model however. There's not much concept of syncing—rather you download files from a source (SFTP, Dropbox or WebDAV), edit them locally, then re-upload. An option to edit directly into Dropbox or SFTP would be nice, but that's a bit of a personal preference.

For our Services and to Contact us visit http://www.arinesolutions.com

No comments:

Post a Comment