this video inspired me using vim some time ago. Now that I'm more experienced with it, i have to say that I like the "f" function for folding, but you are losing the default behaviour of "f" and "F" function in normal mode, which I consider very useful for moving the cursor. To fold like you do, you can do "set foldmethod=indent" and use the default "za" for folding/unfolding blocks of code. If you want to fold it all, use "zM" and if you want to unfold it all use "zR".
@md.abdullah-al-kafi118
3 жыл бұрын
nearly 9 yrs later . some kid is inspired again
@nichohells
Ай бұрын
Bram will live forever!
@AbdelazizYakout
9 жыл бұрын
enabling the mouse is against the whole principle of vim, I guess.
@teachernr1
8 жыл бұрын
+Abdelaziz Yakout Foolish consistency is the hobgoblin of small minds
@okmanek69
8 жыл бұрын
each time you use mouse in vim, small kitten dies
@ikickss
6 жыл бұрын
Mouse is only good for noobs to pick things up quickly or something that is used rare-ishly. It's not a proper interface for any professional work. (The same goes for touch interface, BTW)
@madhurchauhan1288
5 жыл бұрын
I find it easy to change window sizes easily outside of tmux
@DanHaiduc
4 жыл бұрын
@@madhurchauhan1288 Indeed; my i3 tiling wm also allows this.
@zeocamo
5 жыл бұрын
you use Ctrl+z to save while it is not set up in vim it work as default in the terminal to move a process in the background, to get it back to the forground you type "fg" command and you are back in vim. you can do alot with this like have 4 vim's running and jump from one to a another ... but for any one who hit ctrl+z by error it is "fg" to get back :)
@limitless1692
Жыл бұрын
Hahah firt time when it happened to me, I got so paniked, I thought I lost my work... Hahah since then I remember the `fg` comand, which stands to fOREgROUND
@michaelkrailo5725
9 жыл бұрын
It was painful watching you uncomment those lines in the .vimrc file. Best thing for uncommenting blocks of code in vim is using Ctrl-v (visual block mode) and then you select all the comment characters and press x. To insert the comments again Ctrl-v and select the front part of the code block then press I then the two ## or whatever you want inserted in front of the the block of code. You have to press when finished and all the comments are back again. Love that feature in vim.
@eardi
8 жыл бұрын
There is a better way, the plugin "tComment". I press gcc in command mode or visual mode and the current (or selected lines) are beeing uncommentet or commentet. Its filetype aware and 99% of the time gets it right
@miallo
6 жыл бұрын
Or at least he could have gone to the beginning of the single line to uncomment and pressed 3x
@FranciscoTornay
5 жыл бұрын
Or use :normal I# for commenting and :normal ^x to uncomment with appropriate ranges Having said that, I can see myself getting nervous in front of a live audience and falling back on less-than-effective editing
@ThomasBaxter
11 жыл бұрын
New to VIM, only been using it as my primary editor for 2 weeks.. a total n00b. I must say i'm glad to hear him say "bah!" every once in awhile.
@ThisGuyRocksLikeCrazy
10 жыл бұрын
Also, I don't recommend overriding the existing vim keywords. He's using f to fold functions, whereas f is used to jump to the first occurrence of a specific letter in a file by default, which I find quite handy.
@emusan
11 жыл бұрын
not to mention every time he deletes more than he wanted he goes back in and inserts the text back manually, why not just u?? I think he used less than five keyboard commands through this entire presentation...
@flizbarg
10 жыл бұрын
Thanks to whoever it was running the camera - you clearly got yourself up into the Cardio Zone swinging that thing around and zooming in and out - but please, next time just point it at the screen and leave it there unless something truly *requires* that we see it. Hint: random audience members making random comments is not one of those things... (Sheesh!)
@michaelfresco2769
6 жыл бұрын
28:50 - little gem: how to use pdb like a professional
@Flackon
11 жыл бұрын
Agreed. I use vim for small quick edits because it's convenient and runs in terminal but for actually writing code I always use Sublime Text.
@scorpio4lyfe
11 жыл бұрын
Sublime text is AWESOME!!! ""Cross platform"", Feature packed and light. Best thing since multi core procs.
@wenahy
12 жыл бұрын
There is also another very popular plugin manager: vim-addon-manager. The big difference is that it also manages dependencies and that its based on pool of plugins which is also managed by the community. Thus if you're trying to install outdated plugins - VAM can warn you. I use Vim myself. Remind yourself, that Vim offers much more keys for editing and moving than hjkl. Eg removing comment like at 22:50 can be done using ctrl-v3jld - also folding is creat - but using TToc plugin is faster etc.
@limitless1692
Жыл бұрын
That was apretty cool talk. And I grabed some tasty bits of code for my .vimrc file. Thank you very much :) :)
@izepax
11 жыл бұрын
I use Sublime Text to write code but Vim to write git commit messages and for some other small tasks. This will make my vim experience better.
@YeshwanthReddy
4 жыл бұрын
Can't believe you've set f for folding 🙄 You're missing on such a basic function
@adrianopinaffo
4 жыл бұрын
Why?
@YeshwanthReddy
4 жыл бұрын
@@adrianopinaffo f for find
@VirtuellJo
4 жыл бұрын
Yeshwanth Reddy / for find
@YeshwanthReddy
4 жыл бұрын
Not search in text mate... Find a character in line and jump cursor to that character
@MurtagBY
5 жыл бұрын
I get that the guy wasn't master yoda of vim, but still wanted to share it. Useful info
@mahipalsingh9361
2 жыл бұрын
This video is old but still got a few things that I didn't know
@reveluv8851
3 жыл бұрын
The claps at the start sound like me using vim.
@Tiberius214
11 жыл бұрын
For anyone else that has the same question, I think I found the font. It's "Menlo" but to get the cool looking powerline bar at the bottom, you have to install the patched version which you can get from here gist.github.com/qrush/1595572 . After you install the font, you just have to add "let g:Powerline_symbols = 'fancy' " to your ~/.vimrc !
@mordonezme
11 жыл бұрын
Nice video, vim is a very powerfull editor (I use it), Sublime is also good but Vim is more flexible yet... multiple buffers in vim is awsome, also it let you have mulltiple buffers per tab, Sublime only let you define a layout for all...
@reveluv8851
3 жыл бұрын
gT and get can be used to move between tabs
@DanielHahler
9 жыл бұрын
Good talk, but rather old, and Martin has probably gotten used better to Vim by now.. ;) You would use jedi-vim or YouCompleteMe for completion (I prefer jedi-vim) now. I also recommend not to remap 'f' etc. The "Aww shit" moment was caused by Ctrl-Z, which put Vim in the background ('fg' would have started it again).
@DanHaiduc
4 жыл бұрын
In case your SSH drops, use Mosh
@JanUC3mQtGq3NMcyMVdhm6md
11 жыл бұрын
You can quit with ZZ and ZQ, no need for extra binding.
@MeditationProfondeS
10 жыл бұрын
just use vundle to install plugins
@josefrancis7126
5 жыл бұрын
Please see video by LucidProgramming on the subject "setting up vim for Pytlhon development"
@ahadporkar7355
4 жыл бұрын
7 years ago....oh im getting old :/
@lennyhome
11 жыл бұрын
This is a nice demonstration that graphical IDEs are actually useful.
@JimJohnson79
11 жыл бұрын
top vim tip : remap "alt gr" to "esc" you can switch modes with you right thumb then :D
@segreyfurt
2 жыл бұрын
Vimmers used social distance before it became mainstream
@python_lover_01
6 жыл бұрын
Awesome and thanks alot.. It's old but still most of it worked for me.
@louismahon792
4 жыл бұрын
I can't jump to the line specified in the quickfix window. When I hit enter I get "E21: Cannot make changes, 'modifiable' is off". I can make the quickfix window modifiable with ":set ma" and then jumping works, but I don't want to have to set this option every time. Does anyone know the problem?
@georgwrede7715
11 жыл бұрын
Ok, this has nothing to do with Python. But it may still be of use to anybody who needs to do programming on various unix machines. The presenter has only one year of Vim experinece and it shows, but on the other hand he is a smart person. Ymmv.
@james4airsoft
12 жыл бұрын
clicks on video *sees macbook* leaves video
@sivabudh
6 жыл бұрын
Yes, I get all that out of the box with Visual Studio Code. :grin:
@jl_woodworks
6 жыл бұрын
Sivabudh Umpudh Good! Use that then.
@IIvveennss
11 жыл бұрын
"Ha! I am confused" 19:00 That should become a meme hahahahahaha
@jpeg.600x2
3 жыл бұрын
lol
@leetcode_hardcore
10 жыл бұрын
Does anyone know where's the initial .vimrc from?
@leetcode_hardcore
10 жыл бұрын
OK found it: github.com/mbrochh/vim-as-a-python-ide/blob/master/.vimrc
@cwhy
10 жыл бұрын
flake8 and pep8!
@cwhy
10 жыл бұрын
Are you using python2 or 3?
@leetcode_hardcore
10 жыл бұрын
Chen Yu Python2.7, nice to see you here BTW :) Following the talk, I've created a git repo: github.com/flyfy1/dotFiles
@xjazz666
9 жыл бұрын
Thank you for this good presentation. Could you please tell us how do you run quickfix ? It seems that you had to install something before, no ? thank you for the reply
@tuerda
7 жыл бұрын
quickfix is built into vim. Just run :h quickfix to see the manual on this (there is quite a lot to say about quickfix) For the video he uses the syntastic plugin that does static code analysis. Perhaps this is what you meant?
@Tiberius214
11 жыл бұрын
Hey Martin, great video! What font are you using for your terminal?
@ThomasLeo
11 жыл бұрын
I used sublimes "vintage" mode today and for a minute forgot I was in Sublime Text. Then I hit "ctrl-q" for visual-block selection and exited sublime...
@akhmadyudha6066
5 жыл бұрын
It is good for your health (HJKL movement).
@YeshwanthReddy
4 жыл бұрын
... Goes ahead and enables mouse mode
@Jzarecta
12 жыл бұрын
I was hoping to see more python centrics configuration, like to deal with class and def for identation. Code browsing or python debugging.
@avimehenwal
10 жыл бұрын
Super nice video on how to use #vim as #python #ide I just loved it :D Have arose a interest in me to use vim instead of other visual IDE
@ThisGuyRocksLikeCrazy
10 жыл бұрын
The way he deletes " and whitespace from the beginning of each line bothers me a lot. He should just block select and delete it, instead of deleting everything one by one.
@pashikcraft
10 жыл бұрын
Actually, hjkl hurts my last finger. I would love to try it
@SWGINSPECTOR
9 жыл бұрын
Which finger is that exactly? The general idea is to have your index finger on j and your ring finger on l, then you use your index finger to press h when necessary.
@beznazwy99
11 жыл бұрын
Thanks for the video! BTW Menlo is just an apple version od vera sans font.
@ThomasLeo
11 жыл бұрын
Hahahha that drove me crazy too! That situation was made for Visual-Block selection!
@JanCRefsgaard
11 жыл бұрын
alt gr does not exist on international or english keyboards though :)
@p1r0574n
10 жыл бұрын
Just love it!!!
@SuperJer
11 жыл бұрын
Quit at 22:30. I couldn't stand to watch him delete individual characters from the .vimrc any longer. No dw? No block selection? No . repeat? Why even use Vim?
@locombian
11 жыл бұрын
If you already have nstalled python3 and vim how can you enable the python interpreter?
@josefrancis7126
5 жыл бұрын
Jose Francis 1 second ago Please see video by LucidProgramming on the subject "setting up vim for Pytlhon development"
@VioletJewel1729
7 жыл бұрын
backspace ... value effect 0 same as ":set backspace=" (Vi compatible) 1 same as ":set backspace=indent,eol" 2 same as ":set backspace=indent,eol,start" in the video, you needed to close out of vim and reopen it **or** `:set bs=` if you wanted to demonstrate how backspace would not "work".
@ytSpoiler
12 жыл бұрын
absolutely great thx
@eatbreathedatascience9593
3 жыл бұрын
Do I need admin right to install VIM ?
@chopcooey
6 жыл бұрын
can you run the python debugger from inside vim?
@MRABDAHMED1
5 жыл бұрын
hey did you find the answer?
@xFallenZ38X
11 жыл бұрын
It should work out of the box. Just open the terminal and type vim test.py
@Myrkvi_
11 жыл бұрын
Why NOT?
@sureshdharavath1191
10 жыл бұрын
Hi thanks for a great video
@allisondealmeida
8 жыл бұрын
you could provide the file configuration of the VIM?
Vim is a great editor, but as an IDE it is quite lacking. Vrapper (eclipse) och Ideavim (jetbrains(pycharm)) gives you Vim mixed with a good IDE and (IMHO) makes for a far more productive toolset.
@toooes
8 жыл бұрын
Remedying that issue is the whole point of this video :S
@Unox90
8 жыл бұрын
That it is, while it is leaps and bounds ahead of vanilla VIM or a novice VIM users config it still falls short of a proper IDE. Jetbrains Pycharm (even without ideavim) is far superior to a fully tricked out vim setup.
@tuerda
7 жыл бұрын
I have never used eclipse, so the following is partially qualified by my ignorance of the software you are comparing vim to. That said, I have yet to see a function in any IDE that vim cannot replicate. Here is a list of things that I know for a fact are possible (I use many of them myself.): 1) Snippets (including optional keybindings to jump to the next relevant insertion point in the snippet) 2) Keybinding to send visual selection to an interactive console (for python this console can be vanilla python or ipython or bpython or dreampie, you name it. This is not only for python. I also do this for R and for a few other languages as well) 3) Keybinding to compile/run your program in it's current form. This can be done in parallel so you can keep working while it is going on. 4) Color code depending on which language you are writing in. This can be just the background color, or it can be an entire colorscheme. 5) Keybinding to jump to the definition of the function, object, class or variable under the cursor. Change to a different file if necessary. 6) Efficient handling of multiple files, including things such as search and replace on multiple files at once. 7) Regex for search and replace, etc. 8) Static code analysis (for pretty much any language you could dream of. If an engine that runs the analysis for the language exists, you can plug the engine into vim). 9) Autocompletion, not only for elements of the language but also for names of files in the project, lines in the file, etc. 10) Git integration. 11) Multiple registers (for cutting and pasting, or for other purposes.) So um . . . did I miss anything? What can Eclipse do that vim cannot? Of note, most of the above do not require any kind of plugins (the only ones that require plugins are 8 and 10). I'm not sure I would even say that having all of this working means your vim setup is fully tricked out. In fact, pretty much the only one that was at all difficult to get working was 2 (It is probably easier if you embed vim in tmux, but I got it working without tmux.) Also of note, most of the vimrc in the video is giving vim functionality that it actually already has by default. Some of it also overwrites some very useful stuff that vim has built in as well. I would not call it "leaps and bounds ahead of a novice Vim config" because that would mean it is leaps and bounds ahead of itself. Lastly, I have yet to see any program with a vim wrapper than actually makes the program work like vim. Most of them simply add a few of vim's keybindings. The thing is, vim is a lot like a language. To throw in a bunch of vim keybindings is like adding in several of the words from the language, but not adding any of the grammar that allows you to string the words together and say something meaningful.
@Saturn286
9 жыл бұрын
So, it took him 20 min to setup his environment only to the point where he is able to code. Until that point, even he, who is experienced with vim, had a "what the f just happened" moments. And to install a shit ton of plugins (and compiling vim itself with different option) to enable better (from non) support for 1 language. Does all of this now called "cross platform, standard on most systems, very fast"? And imagine if work machine already has it's own customized vim (of course, you can install your own, but still). This is not IDE, it is just a text editor. And feel of self satisfaction that you are better than everyone else (for some god forsaken reason) doesn't make it any better.
@Yotanido
9 жыл бұрын
How else would you get an executable program if you don't compile it? Most(probably all) binary distributions have binaries for vim and I'm pretty sure they all come with python support, but if you don't take package managers into account, you have to compile your programs anyway. (Some people like that and use Gentoo... I don't) As for lots of configuration and plugins, he was just showing his setup and what he likes about it. I have to admit, vim without any configuration is not as great, especially the colourscheme, but a lot of tools seem to have that problem. (tmux, for example). I think the reason is that these tools assume you don't have a 256-color terminal and to keep them as lightweight as possible. I wish they'd come with nicer default-themes. The rest of the configuration is not necessary and I'd actually advise against some of it. Especially binding C-Z. It's sometimes useful to suspend vim and drop to a terminal. The guy in the video did that and had no idea what was going on, though. Which brings me to the next point. Vim is made for power users. It is not meant to be an easy to use editor, but rather an editor that is insanely powerful and efficient. It takes a while to get used to it, but once you do, you will cringe every time you have to use a lesser editor. Installing shit-tons of plugins is also not necessary. I have 12 plugins installed and I'm very happy with it. The need for plugins is obvious, since it is a text editor and is meant for editing text. It does come with syntax highlighting for just about every language, but more advanced features that are language dependent would take up way too much space. Using plugins for that is a great solution. (Most IDEs do it the same way. Eclipse for example, really has shitloads of plugins. It just comes preinstalled with a lot of them, depending on which of the countless versions you download.) SSH-ing into a machine and using vim on it is something I often do, but only for configuration files and not for code. You still have a lot of good features in an unconfigured vim (or even vi, since vim is NOT installed by default on a lot of systems. vi is) that you wouldn't have in, say, nano... Instead of installing your own configuration on a remote machine, you can just use your local vim and edit the file remotely. Vim does have support for that. And finally, yes, you are right. Vim is a text editor and not an IDE. It's not trying to be integrated, but you can make it that way, which is what he was describing in the video. Source code is, in essence, text and a text editor is suitable for editing it. Want to get errors and warnings underlines? Easy, install the appropriate plugin. Want to compile your stuff by pressing a button? Already there... There is not much that separates a nicely configured vim from an IDE, except for the fact that vim does a better job at efficient editing.
@mass13982
9 жыл бұрын
***** Maybe its not for you, but if you master vim then there are things that no editor/ide can ever do for you. Think of it like the Batmobile. Customized only for one and only bat.
@Saturn286
9 жыл бұрын
Mohammad Abdullah well.. i never liked batman anyway :P
@desprit
9 жыл бұрын
***** It takes 2min to install Vundle (or another) plugin manager and install everything with one click. You just have to keep your .vimrc file somewhere in clouds.
@Benrob0329
7 жыл бұрын
You can actually go a long ways with just Vim, and a little configuration.
@info305
10 жыл бұрын
Why not add vi plugins to your modern ide?
@slavewholave
11 жыл бұрын
thank for this interesting video
@justgivemethetruth
9 жыл бұрын
Yea! for VI ! !!!!
@Freddusya
11 жыл бұрын
dude if he does that then people will lose track of watching what he is doing.
@TehNinjaHacker
11 жыл бұрын
That's pretty chill...7fold
@nichohells
Ай бұрын
22:43 painful to watch him do it that way, one by one💀
@dengan699
5 жыл бұрын
why you need to switch the damn camera all the time?? Just stick to slides -_- People must pass a "Making video 101" before they touching it
@litchi231
11 жыл бұрын
omfg! You with the camera! STAHP
@sijojose2264
11 жыл бұрын
Can any one help me to configure VIM as a python editor in ubuntu, I didn't get it working...
@notlonelyday
4 жыл бұрын
I bet he haven't tried pycharm
@hanlinshi990
10 жыл бұрын
maybe I will switch to vim someday :) Awesome!
@OmyTrenav
11 жыл бұрын
This guy needs to go read the VIM documentation.
@VioletJewel1729
7 жыл бұрын
TL;DR ... use: augroup AutoSourceVimrc autocmd! autocmd bufwritepost .vimrc source % augroup END instead of autocmd! bufwritepost .vimrc source % --- No one else seems to have caught this in the comments but this: autocmd! bufwritepost .vimrc source % is pretty gruesomely terrible because everytime you write your vimrc now, you add *all* of those autocmds in your vimrc to the autocmd list. Unfortunately, it is the first thing you show us, as well. Instead you should use what I show above. E.g.: augroup AutoSourceVimrc autocmd! autocmd bufwritepost .vimrc source % augroup END from :h autocmd-define ... :autocmd` adds to the list of autocommands regardless of whether they are already present. When your .vimrc file is sourced twice, the autocommands will appear twice. To avoid this, define your autocommands in a group, so that you can easily clear them: augroup vimrc autocmd! " Remove all vimrc autocommands au BufNewFile,BufRead *.html so :h/html.vim augroup END
@arxytas
11 жыл бұрын
Cool stuff!!! :-)
@milandufek8224
5 жыл бұрын
Once he grew up a bit, maybe he will start using real IDE to get more effective and suitable for work on complex projects. Yeah, but is looses that geek flavor to be special using oldfashion console editor.
@DanHaiduc
3 жыл бұрын
I grew tired of big fat IDEs taking forever to load and full of glitches and updates. In Vim, I can fix the glitches faster and improve my workflow.
@ASWE323
10 жыл бұрын
can i have the .vimrc file please? i dont have power to creat my own... i just want a quick setup.
@ReynosoJD
11 жыл бұрын
how do I to the file to edit the config vim settings? I am new to ubuntu and want to learn to use vim. Please explain like to a 3rd grader with all commands and assume nothing, except that vim is properly installed and terminal is running on ubuntu 12. What next to get to vimrc and edit settings?
@josefrancis7126
5 жыл бұрын
Jose Francis 1 second ago Please see video by LucidProgramming on the subject "setting up vim for Pytlhon development"
@emshains
11 жыл бұрын
Using vim on a mac... WHY?
@michaelfresco2769
6 жыл бұрын
16:08 - thanks!!!
@neogeekclc9757
12 жыл бұрын
Im user vim IDE for programation
@jazzpi
10 жыл бұрын
Well, PEP 8 disagrees with Ken Thompson then :P
@prabhakardevineni6956
10 жыл бұрын
how can i install vim on windows7 ???? please help me
@user-qz3be2li5d
10 жыл бұрын
code.google.com/p/vim-win3264/wiki/Win64Binaries i think you can do it!
@mass13982
9 жыл бұрын
Prabhakar Devineni cygwin
@pjrt_tv
11 жыл бұрын
3x. 3x!!!!
@bike4aday
9 жыл бұрын
Love that accent
@CRadiusOfficial
11 жыл бұрын
Why did they let that noob talk about vim? He "knows" what vim is all about... but he doesn't use the power of vim o_O (N)
@__nicfit__
11 жыл бұрын
3-x
@tawheedcoopoosamy9329
9 жыл бұрын
Lol Awww shit... at 12:14
@shavebunny
3 жыл бұрын
HJKL FTW
@AlexandrBorschchev
4 жыл бұрын
i thought my stomach was growling at the first part.
@shockteam
11 жыл бұрын
user terminal tabs instead, don't bother with VIM tabs )
@SriKadimisetty
11 жыл бұрын
"Real programmers dont use tabs, they use spaces". Ken Thompson disagrees with you :)
@MaikBey
11 жыл бұрын
lol way to go. What do you expect from a Max user. haha
@josefrancis7126
5 жыл бұрын
not a GREAT VIDEO . He takes time to come to the task.
@mflayer
5 жыл бұрын
I cringed every time he was going down line by line and uncommenting code by deleting single characters. Selecting a block with Ctrl-V and pressing d would have been way more efficient.
@OverG88
12 жыл бұрын
He should watch his language. He looks very unprofessional because of that!
@veryxcit
11 жыл бұрын
I'll stick to pycharm :)
@basalduat
7 жыл бұрын
Rapid and continuous talking is not recommended. Relax. Make a point and stop for a second or two. Talk less and show more.
@HelplessProcrastinatorChannel
11 жыл бұрын
:D !!!!
@SortEnthusiast
11 жыл бұрын
This isn't compelling.
@Seawolf159
5 жыл бұрын
python-mode doesn't work for me :( I keep trying to make vim "worth it", but time and time again it proves to be a pile of dogshit.
Пікірлер: 148