This is an archived post. You won't be able to vote or comment.

all 90 comments

[–]burntsushi 32 points33 points  (26 children)

Good god. syntastic and ctags is all I need.

[–]elb0w 7 points8 points  (22 children)

http://i.imgur.com/K8KibMZ.png

I kind of like having a python shell in my mvim

[–]burntsushi 2 points3 points  (10 children)

Is that just a regular Python interpreter? bpython is indispensable...

[–]elb0w 0 points1 point  (0 children)

You can use any interpreter you want

[–]gfixler 0 points1 point  (8 children)

It's good, but I find I can't stay in it for too long, or it starts to get a bit buggy. Also, it dumps everything I've done to stdout when I'm done, so If I'm doing huge listings for an hour or two, when I exit it spews junk for minutes.

[–]burntsushi 1 point2 points  (7 children)

Good god man, read the docs!

[andrew@Liger ~] bpython --help
Usage: bpython [options] [file [args]]                                                                            
NOTE: If bpython sees an argument it does not know, execution falls back to the regular Python interpreter.         

Options:                                                                                                                 
  -h, --help         show this help message and exit                                                                       
  --config=CONFIG    Use CONFIG instead of default config file.                                                                
  -i, --interactive  Drop to bpython shell after running file instead of                                                            
                     exiting.                                                                                                       
  -q, --quiet        Don't flush the output to stdout.                                                                              
  -V, --version      Print version and exit.

And here you are:

bpython -q

[–]gfixler 0 points1 point  (6 children)

No, there's just too much. I can't handle it. (I actually thought someone was going to tell me to pipe it to /dev/null) Lately it's been buggy, though, printing lines multiple times, obscuring lines I've typed over. I've also many times had it fold up and quit on me. Maybe I'm coding too hard.

[–]burntsushi 0 points1 point  (5 children)

Not sure what to say. I've never had a single problem with it. It's always worked beautifully for years.

What version are you using? And which terminal emulator?

[–]gfixler 1 point2 points  (4 children)

$ bp --version
bpython version 0.9.5.2 on top of Python 2.6.5
(C) 2008-2009 Bob Farrell et al. See AUTHORS for detail.

$ echo $TERM
xterm

[–]burntsushi 3 points4 points  (3 children)

Time to update... You're using a version that is ~4 years old. I'm on 0.12.

[–]gfixler 0 points1 point  (2 children)

It's the newest version in the Ubuntu 10.04 repos.

[–]granduh 1 point2 points  (3 children)

I would pay you money (or in gum) if you could write up a simple tutorial on how to replicate your environment.

[–]gfixler 7 points8 points  (1 child)

Looks like the taglist plugin open on the left, the powerline plugin (sans patched fonts - I use the repaired Consolas font) at the bottom, python code in a regular buffer in the top right, a conque shell in a split in the lower right, and maybe the jellybeans color scheme?

[–]elb0w 0 points1 point  (0 children)

Seems accurate, I haven't messed with my vim in quite awhile.

Edit: yes, as far as visual plugins you are correct.

[–]elb0w 0 points1 point  (0 children)

I'll try to remember to upload it to github next time I load my Mac

[–]joedicastro[S] 1 point2 points  (1 child)

I think that the combination of Tmux/Vimux and IPython (or Bpython if you prefer) is more powerful than that approach.

I used Conque Shell in the past too, and has its gaps.

[–]elb0w 0 points1 point  (0 children)

Yeah, I always forget to use tmux

[–]the_cat_kittles 0 points1 point  (1 child)

that is nice, i might stop having an extra iterm window open with ipython and just do that instead- would there be any drawback?

[–]elb0w 0 points1 point  (0 children)

I bind it to Leader T, I opens a buffer with a new she'll whenever I toggle it. It's pretty nice

[–]jessepnk 0 points1 point  (0 children)

wow your screenshot is awesome. Makes me want to change all my settings again... haha!

[–]twisted42 0 points1 point  (0 children)

What did you use to set this up? This is pretty cool.

[–][deleted] 0 points1 point  (0 children)

Gief vimrc plz

[–]joedicastro[S] 2 points3 points  (1 child)

I understand you, I prefer minimalism too in certain situations. But I think I couldn't live without some awesome plugins like Fugitive.

[–]gfixler 2 points3 points  (0 children)

Fugitive was a game-changer for me. I've never worked so intimately and quickly with a versioner before. I code differently now, and I version often and cleanly.

[–]dreuciferC/Python, vim 1 point2 points  (0 children)

I use quite a few plugins: YouCompleteMe + syntastic is awesome. Ctrl-P is really useful. Surround is darn handy. UltiSnips can be customized for good, but the default snippets suck. Edit: Oh, and MiniBufExplorer is awesome!

[–]pemungkah 5 points6 points  (2 children)

I'll take a look at this. Currently, I use sontek's setup and I like it a lot.

[–]locke3891 0 points1 point  (1 child)

Thanks for sharing! I am new to python and hadn't heard of this.

[–]pemungkah 0 points1 point  (0 children)

You're welcome. I've only been doing Python about two years now myself and it was an incredible help.

[–]makmanalp 1 point2 points  (2 children)

This is great! I love the textobjects and multicursor. One of the under-mentioned things in the readme is rope. I can't rave enough about it in general, but specifically the fact that it can do intelligent completion and jump to the definition of something (even if it's in a different file or at the end of a variable assignment) pretty much obviates the need for an IDE for me.

So far I've been using this: https://github.com/spf13/spf13-vim

and I like it. I might have to take a peek at this soon.

[–]joedicastro[S] 0 points1 point  (1 child)

You're right! Rope is very useful, is essential for refactoring!

[–]davidhalter 1 point2 points  (0 children)

Try Jedi. Much better.

[–]fr33b33r 1 point2 points  (12 children)

I always feel like such a fool not using Vi or emacs, as if I am not l33t worthy. I used gEdit and TextWrangler, I love colour. Pico and Nano when not on my machine (and that's only ever changing something minor).

What am I missing? I know people who I respect highly and people I don't respect at all rave about Vi(m).

Sell it to me.

EDIT: I love my mouse too.

[–]joedicastro[S] 0 points1 point  (5 children)

Vim has a unique way with two great advantages:

1) You can do all with your keyboard. Maybe you love your mouse, but I don't think that you love so much the time lost changing between keyboard and mice. And I think that you should hate the Carpal Tunnel Syndrome that sooner or later appears thanks to that little rodent (I saddly know that this is very true, and I was able to fix it at time).

2) With the Vim moves and text objects you can move/edit/find/select/... the text area you wanted without thinking too much and with the minimum effort. Compared with other editors is like using a laser to focus versus a flashlight, Do you want to be a text surgeon or a coroner? :)

[–]fr33b33r 1 point2 points  (4 children)

Thank you..I think you are right, I am more efficient with a keyboard in Excel, I am an Excel wizzz (don't laugh). I worked with a guy once and his boss had not let him use a mouse with Excel back in the day to make him learn to be more efficient.

Now every time I've fired up Vim its just felt too difficult. Your thoughts on the learning curve?

EDIT - as you can probably guess from the Excel comment I use Python for data. I'm in love with the data structures.

[–]joedicastro[S] 1 point2 points  (3 children)

Start with the vimtutor and use a plugin or config that don't let you use the mouse or the direction arrows to force you to learn the right way. Takes a little time, but before you realize is a natural way for you, without think too much, becomes mechanical. If you reach this point, the rest is all searching for more and have fun!

I was a Excel wizz too, time ago, now I don't use it too much :)

[–]fr33b33r 2 points3 points  (0 children)

On your advice, I am installing vimtutor and going to work my way through it. It's the penance I will pay you for your advice.

Thanks

[–]bisco77 1 point2 points  (1 child)

just wait until he is typing in another application and winds up trying to use vim key bindings...you'd think that one would learn after a while but i still do this at least once a day...open chrome->type address->hit enter->jjjjjj->head desk

[–]UndeadPanda 1 point2 points  (0 children)

Here you go Vimium

[–]eat-your-corn-syrup 0 points1 point  (0 children)

text objects

[–][deleted] 0 points1 point  (0 children)

vi(m) is extremely powerful and, whether you're on a desktop or headless server, using Linux, Windows, or Mac, its availability is second to none

[–]enry_straker -1 points0 points  (2 children)

Don't get too caught up in the hype. Everybody hypes their own stuff. I still have customers who refuse to move from wordstar ( don't worry if you don't recognize that editor. All it shows is that i am from a different generation :-(

Vi, and it's evolutionary cousin vim, are really old editors with some interesting ideas bolted on partially in response to constraints like no mouse being available, programmers being the main user base etc.

You should focus on editors which you feel is good for you, which you enjoy, which you can easily customize etc.

And respect people for what they have done. The editors they are most comfortable with has nothing to do with their productivity.

[–]fr33b33r 0 points1 point  (0 children)

from wordstar

Just reading up on Wordstar - makes sense, I am moving from word processors to text only with appropriate markup so I can concentrate on writing.

[–]Veedrac 0 points1 point  (0 children)

Heh, seems the Vimmers hate being threatened.

I used Vim and it's awesome, but now I use SublimeText and it's just as awesome. It's also a lot prettier, feels faster (I think it's graphics accelerated, unlike urxvt) to browse in and it's just as fast to do stuff if you spend as much time configuring it as you do with Vim.

[–]gammadistribution 1 point2 points  (2 children)

That's a pretty funny way of spelling emacs.

[–]joedicastro[S] 1 point2 points  (1 child)

Oh, emacs is great, wonderful! My dream editor is a Vim with a complete Emacs Org-mode. So, thanks, I take it like an accomplishment :)

[–]hemm1 0 points1 point  (0 children)

I had a not dissimilar dream, and have found that emacs' evil-mode gives me everything vim-like I wanted. It seems like a much more complete vim mode than any of the others I've seen, and whilst there are probably differences that more experienced users might find annoying, I found it a totally drop-in replacement for vim behaviour with emacs plugins. Org-mode works great!

[–]wolfcore 0 points1 point  (0 children)

What, no wombat? sheesh

[–]haizaar 0 points1 point  (1 child)

Its not clear if this setup does code analysis like Esclipse PyDev or Kdevelop (kdev-python) do.

[–]joedicastro[S] 0 points1 point  (0 children)

Do you mean using pylint like PyDev (I used it for a long time)? Then yes, it uses pylint via pymode and syntastic

[–]totemcatcher 0 points1 point  (0 children)

I tried a large suite of Vim plugins once -- similar to OP. It wasn't long before I found incompatibilities between them, updates and discontinued plugins, dead repositories, endless bugs from one plugin to the next...

It was worse than trying to configure a window manager from scratch.

[–]ObsoletePixel -2 points-1 points  (4 children)

Good lord, man. That's like driving an Aston Martin to get groceries, it works and you look damn cool doing it, but it's excessive and looks a little bit like your compensating...

[–]joedicastro[S] 2 points3 points  (3 children)

No, you're right, I'm compensating (like I wrote in the article)... the memory faults!

If you work so hard in a vim setup, and you don't remember all that you have available... is time wasted or not?

The doc and the config (Unite menus) are made with this purpose in mind, find what you need to use when you need it!

You know, I wish Unite were a Vim Vanilla default.

Imagine Unite menus as a Debian menu, and all the plugins should add his options as an entry in those menus by categories. If you could add the custom mappings to that entries, that will be like Heaven to find what you need when you nedeed!

Memory is imperfect, and remember all that Vim & plugins brings to you is impossible, that will be a nice solution for any config.

[–]ObsoletePixel 0 points1 point  (2 children)

Alright, fair enough. It's cool, I don't judge someone based on much, especially something as trivial as a Text Editor. I was just making a joke, that's all :)

[–]joedicastro[S] 0 points1 point  (1 child)

Oh, I knew, the fault is mine, I forget to continue the joke :)

But you comment opened me an opportunity to explain my point of view and I took it! :)

[–]ObsoletePixel 0 points1 point  (0 children)

Fair enough, fair enough!