Better Vim integration #44

wants to merge 1 commit into

5 participants


Hi Craig,

I watched your RubyConf talk yesterday and discovered Xiki.
Being a Vim user, I decided to help a bit with the integration.

What I did

  • Gathered and improved small fixes from #36 and #19
  • Nested commands (going up the tree)
  • Expand and collapse
  • Got rid of vim/line (indirection didn't seem to be justified) and replaced vim/tree
  • Provided tests for most of this
  • (NOT ANYMORE, see below) Added some more test infrastructure (minitest, guard to rerun test automatically), I think it is good to enforce good practices at the project level, but do whatever you want with these!
  • Updated vim status

What I did not do

  • Filtering on additional key strokes, not sure how to approach this in Vim (but didn't look at your emacs implementation)

I strongly believe Xiki is the right way to interact with a computer, at least from a keyboard. I have always been a huge fan of CLI interfaces and seeing projects like yours is refreshing, but...

  1. I find the shelling-out option too slow compared to the snappiness of your emacs demo.
    A TCP client/server model seems like the right thing to do, with most of the code being editor-agnostic with only thin editor-specific presentation layers.

  2. I had trouble dealing with the codebase and gave up on reusing existing data structure after 15min of browsing. That's why I added XikiVim::Tree. Get rid of the $el already :)

Is there anything planned to address these issues?

Anyway, thank you and keep up the good work! :)


Would it be possible for you to break out the Gemfile changes into a different commit so they can be either accepted or not as a separate commit please?


I agree it was bold of me to add a dependency.
I removed the changes to Gemfile and removed the Guardfile.
I'll add them back if requested.

@trogdoro care to weigh in?


Eagerly awaiting this. :-)


any news on this? really waiting for this merge :)


Thanks for the contributions!

Got rid of vim/line (indirection didn't seem to be justified) and replaced vim/tree.

I definitely intend for the line.rb class to exist, so this pull request would be awkward to merge, since I'd have to restore it back after the merge. There isn't much in line.rb now, but in the emacs version there is a lot. Will be tough to maintain in the future if the vim classes are named/structured differently than the emacs ones.


Hi Craig,

To be honest, I too think that this pull request doesn't fit in the codebase anymore.
As I said before, I tried to reuse existing classes, but $el was everywhere so it was quite hard.

For instance, if the Line class is supposed to be generic, then it should be a superclass of EmacsLine and VimLine.
I'm glad to hear that a refactoring is in progress though, because it should be easy to redo what I did (not much really) afterwards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment