AstonJ

AstonJ

What's in your .vimrc file?

Inspired by some of the comments in our Your Vim Tips! (in particular those by Mafinar and Hallski) …what’s in your .vimrc?

*If you’re using something like Janus, you’ll probably want to look in .gvimrc.after

Most Liked

mafinar

mafinar

I haven’t touched it for like forever. Not a good example either, but it is well attuned to my muscle memory.

Hallski

Hallski

This is a plugin found after stumbling over the feature in Doom Emacs and wanted to have the same functionality in Vim.

It gives a visual feedback to what you just yanked so that you can verify that you got it correctly.

AstonJ

AstonJ

Here’s mine:

color Elixify
set guifont=Menlo:h12
set linespace=2
let g:NERDTreeWinPos = "right"
autocmd BufWinEnter * NERDTreeMirror
set guioptions-=T " Removes top toolbar
set guioptions-=r " Removes right hand scroll bar
set go-=L " Removes left hand scroll bar
autocmd User Rails let b:surround_{char2nr('-')} = "<% \r %>" " displays <% %> correctly
set cpoptions+=$ " puts a $ marker for the end of words/lines in cw/c$ commands
let mapleader="," " Change mapleader from \ to ,
"autocmd BufWritePre *.rb :%s/\s\+$//e
autocmd BufWritePre * :%s/\s\+$//e
set shortmess+=A " removes swap file warnings

"Better window navigation
nnoremap <C-j> <C-w>j
nnoremap <C-k> <C-w>k
nnoremap <C-h> <C-w>h
nnoremap <C-l> <C-w>l

set splitbelow
set splitright

inoremap jk <esc>

Where Next?

Popular General Dev topics Top

AstonJ
Thanks to @foxtrottwist’s and @Tomas’s posts in this thread: Poll: Which code editor do you use? I bought Onivim! :nerd_face: https://on...
New
First poster: bot
Batteries included with Emacs. Emacs has a reputation for being borderline unusable out of the box, of being bloated but somehow surpris...
New
New
First poster: bot
At least one Vim trick you might not know • Hillel Wayne. I’ve been using Vim for eight years and am still discovering new things. This...
New
First poster: bot
Download and play .puz crossword puzzles in Emacs. Includes a browser to view puzzles’ detailed metadata, including progress of partially...
New
CommunityNews
adobe/brackets. An open source code editor for the web, written in JavaScript, HTML and CSS. - adobe/brackets This thread was posted...
New
First poster: OvermindDL1
It’s Magit! A Git interface inside Emacs Magit is a text-based Git user interface that puts an unmatched focus on streamlining workflows....
New
CommunityNews
I was a rather puzzled the first time I spotted DWIM in an Emacs interactive command name. Don’t think I remember what the command itself...
New
DevotionGeo
I installed Github Copilot (VS Code extension) and signed up for the technical preview three days ago. Yesterday I got the invitation, an...
New
First poster: jaeyson
Nova. The beautiful, fast, flexible, native Mac code editor from Panic.
New

Other popular topics Top

malloryerik
Any thoughts on Svelte? Svelte is a radical new approach to building user interfaces. Whereas traditional frameworks like React and Vue...
New
AstonJ
You might be thinking we should just ask who’s not using VSCode :joy: however there are some new additions in the space that might give V...
New
AstonJ
There’s a whole world of custom keycaps out there that I didn’t know existed! Check out all of our Keycaps threads here: https://forum....
New
New
PragmaticBookshelf
Create efficient, elegant software tests in pytest, Python's most powerful testing framework. Brian Okken @brianokken Edited by Kat...
New
Maartz
Hi folks, I don’t know if I saw this here but, here’s a new programming language, called Roc Reminds me a bit of Elm and thus Haskell. ...
New
PragmaticBookshelf
Author Spotlight: Tammy Coron @Paradox927 Gaming, and writing games in particular, is about passion, vision, experience, and immersio...
New
PragmaticBookshelf
Author Spotlight: Peter Ullrich @PJUllrich Data is at the core of every business, but it is useless if nobody can access and analyze ...
New
New
PragmaticBookshelf
Fight complexity and reclaim the original spirit of agility by learning to simplify how you develop software. The result: a more humane a...
New