Live data from Hacker News

Vim ported to iOS

applidium.com

121–130 of 133 posts

Re: Vim ported to iOS

#121
post #77

Earlier quoted context omitted.

Small tip - I use "jk" instead of "jj" for ESC. I always thought the difference was personal preference, but there is actually 1 good reason to use "jk". If you get used to pressing "jk" all the time, you'll probably end up using it in Normal mode as well as insert mode. "jj" will move up 2 rows in Normal mode, while "jk" doesn't do anything. Therefore you can use "jk" as a reflex every time you get to the keyboard,…

ctrl-c, to avoid any of that stuff. 'jk' will move you one row down, and one row up.

There's no "ctrl" key on the iOS keyboard, though.

Re: Vim ported to iOS

#122
post #116

Earlier quoted context omitted.

Apple did not take any special action to support GPL in the app store. You do not need to take any special action with any operating system to get it to support the GPL. What Apple have done is done special action (lots of EULA/contracts/etc.) that explicitly disallow the GPL. The reason ( I think ) Apple are explicitly disallowing the GPL is because it would be incompatible with the DRM type systems that Apple use.…

Yes, you do (sometimes) have to take special action to support the GPL. For example, Ruby recently changed its license to allow the bundling of readline 6 with MRI. This was a distribution problem as well. Show me the places where Apple EULA "explicitly" disallows the GPL (and not just includes things that are incompatible with the GPL). There certainly is GPLed Software in the app store, even with a notice included…

I think MS were the ones that explicitly mentioned the GPL.

Apple do not explicitly mention it, however they have chosen to add extra restrictions to their licence, which goes above and beyond a normal "Download software from this web host". Explicit clauses that make the GPL incompatible are the same as "explicitly banning GPL apps".

The GPL is a massively popular licence, I believe Apple would have considered it. They appear to have rejected it.

Re: Vim ported to iOS

#123
post #95
post #85

Earlier quoted context omitted.

Definitely. Unfortunately Git is GPL, and given the trouble we went through with VLC we decided not to work on that feature. It's definitely sad though.

Would libgit2 improve this situation for you? It comes with a linking exception which should keep you on the safe side. Sadly, most of the network stuff is not or only partially implemented yet, such as clone and push. They have an example for 'fetch', though.

Oh, I wasn't aware of this. Actually yes, it might :-) Thanks for the pointer!

Re: Vim ported to iOS

#124
post #101
post #98

Earlier quoted context omitted.

Other way around - the app store does not allow distributing the source along with the app. So, strictly speaking, publishing GPL software in the App Store is in violation of the GPL. If you - as a rights holder - are okay with having the source downloadable at another location, you can definitely publish GPL software using the App Store. Case in point: Battle for Wesnoth.

You do not have to distribute the source code of a GPL application with the binary. You merely have to make it available. For example, I have an Ubuntu Linux install CD with lots of GPL binaries and no source. It's perfectly legal for that binary-only CD to be distributed. AFAIR from the VLC case, software distributed on the AppStore has extra restrictions on the user (You can only use it for personal reasons, you ca…

You merely have to make it available.

Also, you don't have to make it available forever, I think the GPL says you only have to do it for 3 years. So you don't have to worry about someone in 50 years demanding some source code.

Re: Vim ported to iOS

#125
post #17

Earlier quoted context omitted.

That's great for browsing but I can't picture coding in an editor where I need to stop and look for common command keys. At the moment vim is efficient because [esc]10dd or something but it's just not viable without a keyboard. For reviewing code or making quick edits however this could be incredible. I wonder if it supports plugins.

nnoremap jk

Shouldn't that be inoremap?

Re: Vim ported to iOS

#126
post #77

Earlier quoted context omitted.

Small tip - I use "jk" instead of "jj" for ESC. I always thought the difference was personal preference, but there is actually 1 good reason to use "jk". If you get used to pressing "jk" all the time, you'll probably end up using it in Normal mode as well as insert mode. "jj" will move up 2 rows in Normal mode, while "jk" doesn't do anything. Therefore you can use "jk" as a reflex every time you get to the keyboard,…

ctrl-c, to avoid any of that stuff. 'jk' will move you one row down, and one row up.

Yes, except ctrl-c moves you off home row, which I wanted to avoid.

Also, technically, ctrl-c is not the same as escape - it also sends a cancel signal. I actually have no idea what the practical difference is, I just know that some commands treat it differently.

Re: Vim ported to iOS

#127
post #96
post #36

Earlier quoted context omitted.

This is a circular argument (or some sort of thing like that), but if you ever find yourself at a *nix command line prompt and need to edit a file, you can be certain that vim will be available. Basic familiarity with it can be helpful. Personally, I used to write a ton of perl inside Vim as a student, but these days I'm in VS all the time, and only use Vim like I would use Notepad - when I want to do quick edits in…

What port of Vim do you use under Windows ?

At my work we get Vim for free with your dev enlistment. It's 7.3.46, and the version that works inside cmd.exe.

Re: Vim ported to iOS

#128
post #126

Earlier quoted context omitted.

ctrl-c, to avoid any of that stuff. 'jk' will move you one row down, and one row up.

Yes, except ctrl-c moves you off home row, which I wanted to avoid. Also, technically, ctrl-c is not the same as escape - it also sends a cancel signal. I actually have no idea what the practical difference is, I just know that some commands treat it differently.

It doesn't check for abbreviations and doesn't trigger InsertLeave, which essentially means that any pending command is aborted, but you're totally right about not leaving the home row.

I just right now remapped caps-lock to control and use CTRL-[ to escape instead.

Re: Vim ported to iOS

#129

I'm confused, how does one use the esc key without a keyboard?

The correct way to do it is to attach a toolbar to the top of the keyboard that contains any special keys or commands that one needs, such as "Esc".

This would be awesome for vim. Not just for the escape key, but also for other often used keys. I love the virtual keyboard in Codea for example.

Re: Vim ported to iOS

#130
post #28
post #26

Interesting that they actually exit on ":q", which is prohibited by the iOS Human Interface Guidelines: http://developer.apple.com/library/ios/#documentation/UserEx... Also, ":Explore" and then "-", "-", "-"... works to browse the file system, or at least the parts allowed by the app sandbox

I think they're called "guidelines" for a reason, and nowhere in them is the word "prohibited" used.

Especially as the guideline is clearly there so as not to give users the misleading impression that the app's crashed. That's obviously not the case when a vim user is using the expected command to close the program.
Post reply on HN