TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

The cleanest vimrc you'll ever see

52 pointsby skwpover 13 years ago

8 comments

evmarover 13 years ago
My vimrc is cleaner:<p><pre><code> $ cat ~/.vimrc cat: /home/evanm/.vimrc: No such file or directory </code></pre> I mean, it's cool and all that you love your tools, but I suspect these sorts of blog posts are net harmful when you consider the number of people who will read it and take it as an opportunity to fiddle around with settings in a program as a way of further putting off making something meaningful.
评论 #3491714 未加载
评论 #3490761 未加载
评论 #3491318 未加载
评论 #3493035 未加载
oacgnolover 13 years ago
To me, it really doesn't matter if you maintain your plugin settings in your .vimrc or in separate files, as long as it's well annotated and organized the way you like it.<p>Plus, all I have to do is track my .vimrc in my dotfiles repo and let Vundle manage my plugins for me.
leleleover 13 years ago
I followed the modular init file approach at first, but keeping track of dependencies between different modules was a chore. Having all of my initialization code in a single file greatly simplifies maintenance: I could instantly tell what code runs before or after a certain line and I could easily navigate among sections of code and fold them based on headings.<p>Nowadays, my emacs init file is 239 kB. Is it messy? Yes, in some places, for customizations I don't care that much, it is, because each section I rely on constantly gets constantly refactored.<p>Modularization helps when you are going to share code among different projects, but your init file is a single project, what does splitting it buys you? Only increased complexity. Of course, as soon as functions get refactored and made more general and independent, they go into a module of their own.
jdludlowover 13 years ago
<i>Remap caps-lock to escape</i><p>Ugh, why? Remapping caps-lock to Ctrl makes more sense to me. The Escape key is still in the upper-left, and banging somewhere in that vicinity usually hits it. Also Ctrl-C equals Escape in vim, so you still have quick access to it from the home row if you want.
评论 #3490683 未加载
评论 #3490868 未加载
评论 #3491019 未加载
评论 #3493043 未加载
评论 #3491570 未加载
评论 #3491215 未加载
评论 #3491173 未加载
DiabloD3over 13 years ago
But not the best: <a href="https://github.com/Diablo-D3/dot_vim" rel="nofollow">https://github.com/Diablo-D3/dot_vim</a><p>Edit: Woah, that guy needs to learn how to use Vundle and not embed third party files in his git repo, and let Vundle fetch it for him (look at mine for example)
评论 #3490591 未加载
评论 #3490935 未加载
daniellockardover 13 years ago
I have my vimrc on github as well. It gets the job done for me. Keep in mind I'm far more of a sysadmin than a programmer.<p><a href="https://github.com/daniellockard/vimrc" rel="nofollow">https://github.com/daniellockard/vimrc</a>
jh3over 13 years ago
I've been meaning to clean up my vimrc. I think I may finally do it. Vundle seems like it would be nicer to use, though.
njharmanover 13 years ago
This is an example of poor refactoring. Also, "cleanest" is not better.