think tank forum

technology » vi to emacs?

maple's avatar
14 years ago
r2, link
maple
i like large datasets
so i don't have alot of time to write this but starting today i will be trying to switch to emacs. i've never liked emacs and until the other day it was never even an option to switch to. i love vi-keybindings everywhere. my browser, my shell, vi itself, etc etc. i love modal editing.

i've even tried emacs a few times for about a total of 10 minutes. i cant ever do anything i want. i've used textmate for alot of development over the past 2 years but want something that is more portable (same environment on mac/windows/unix), plus there really isn't a need to know more editors than vi and emacs. just pic one.

i like vi for editing shit, but i cant ever get my dev environment setup the way i want with it. but i've seen some videos that i CAN do alot of it with emacs. even watched the peepcode intro to emacs to get a decent overview. i'm not possitive i'll fully switch but im gonna give it a shot. already switch my caps-lock to a ctrl key, now just gotta retrain my muscle memory and stop typing vi at the command line.

just real quick a few of the reasons im switching
better file browsing. (im in alot of files and switch between them fast and frequent)
you stay in the environment after you close the last file
snippets (they save me tons of time, vi can do this but emacs does it way better)
nice version control integration
easier plugins system
and more

also, i read tons of places that people use vi for editing files quickly but use emacs to actually develop, so im interested to see why that is. maybe im missing someting

things i dont like about it though - its GNU, i dont like GNU crap. its fairly fat. i dont want a broken pinkey finger. hjkl are way better than C-fbpn. there is `mg` that comes with openbsd but it lacks the functionality i need in a dev environment.

anyone else do this?


edits: typos
nny's avatar
14 years ago
link
nny
M̮͈̣̙̰̝̃̿̎̍ͬa͉̭̥͓ț̘ͯ̈́t̬̻͖̰̞͎ͤ̇ ̈̚J̹͎̿̾ȏ̞̫͈y̭̺ͭc̦̹̟̦̭̫͊̿ͩeͥ̌̾̓ͨ
The only thing emacs is missing is a decent editor.
bluet's avatar
14 years ago
link
bluet
The university I'm going to might force me to use Emacs.
maple's avatar
14 years ago
link
maple
i like large datasets
fuck emacs, gnu and rms.

not sure why i thought i would like something by a guy i cant stand, a philosophy i don't like and an editor that wasn't vi.

i just needed to do some searching and update my configs and plugins that i hadn't touched in years. happier than ever. all the things i was searching for have slick plugins now.

never leaving vi again.
dannyp's avatar
14 years ago
link
dannyp
dʎuuɐp
:]
asemisldkfj's avatar
14 years ago
link
asemisldkfj
the law is no protection
hahaha, I love this thread
maple's avatar
14 years ago
link
maple
i like large datasets
ok. so i've been using emacs with some effort. it's starting to grow on me.

i still have times where i think 'oh fuck this, vi is awesome' but there are some awesome things about it.


ido-mode rules
the buffers are better. leave a session open all day instead of in and out like i am in vi
version control hooks in it is nice


its true. the editor itself is pretty shit, vi owns it, but the other stuff is where it shines. gonna keep working with it for a while. trying to use it for everything right now to give it an honest run.
andre's avatar
14 years ago
link
andre
I've been thinking of trying emacs or one of its clones, mostly because vim's OCaml mode is somewhat lacking... But I'm not really sure if the effort of learning a new editor will be worth it, so I keep postponing it...
Carpetsmoker's avatar
14 years ago
link
Carpetsmoker
Martin
Infidels, how dare you question the power of the Vim!
andre's avatar
14 years ago
link
andre
Went through a small tutorial today; my left hand hurts...
maple's avatar
14 years ago
link
maple
i like large datasets
yeah on my mbp i move the ctrl key to the caps lock.

i actually like it. i use it there for everything now. much easier on my pinky
maple's avatar
14 years ago
link
maple
i like large datasets
ok, just an update.

so im past the point of no return. although there are a few things i still dislike about it, i dont think i could ever switch back to just vim (although for quick edits i still use it). here is why i cant switch back. I develop in python (django), html, css, javascript and thats about it. basically when im developing im using a bunch of terminals, an editor and the browser.

random list:
pyflakes - i can see errors on the fly in python, unused imports, indentaion errors, etc. this is awesome

buffers - the emacs buffers is the best way of handling multiple files i've ever seen. i always need alot of files open at a time and there is no faster way of handling this.

ido mode - for opening files, switching buffers this is amazing. hard to understand how useful till you use it.

magit - interface to git. best version control interface i've ever used.

whitespace mode - show all random white space around the file. "C-c n" to clean it up. love this (im ocd)

yasnippet - just like textmates. not new, but nice to have.

terminal inside the editor - this is awesome. the shell is also, just an emacs buffer so you can edit it just like a text.

nice full screen - self explanatory.

orgmode - i need to learn more, cuz what i know i love.

orgmode + gpg - use this for password storage. orgmode tables let me enter data easy, gpg automatically encrypts the file on save and asks to decrypt on open.

its always open - i opened and closed vim all through the day before. i leave emacs open for days at a time.

keybindings suck but my muscle memory is getting replaced. i can whip around in emacs without thinking about it now.

i read something the other day that made alot of sense. vi users usually started as sys administrators and emacs users are usually developers. this makes sense for me as i loved vi but was for years a unix administrator (and windows with vi) and now do alot more development. vi is easy, fast, can slice text quick like no other, always the same, etc. perfect for admins.

anyway just some notes from a 10 year vi nerd. religiously.
nny's avatar
14 years ago
link
nny
M̮͈̣̙̰̝̃̿̎̍ͬa͉̭̥͓ț̘ͯ̈́t̬̻͖̰̞͎ͤ̇ ̈̚J̹͎̿̾ȏ̞̫͈y̭̺ͭc̦̹̟̦̭̫͊̿ͩeͥ̌̾̓ͨ
python... when I really started to use it... I discovered I despised it.
maple's avatar
14 years ago
link
maple
i like large datasets
what do you like?
nny's avatar
14 years ago
link
nny
M̮͈̣̙̰̝̃̿̎̍ͬa͉̭̥͓ț̘ͯ̈́t̬̻͖̰̞͎ͤ̇ ̈̚J̹͎̿̾ȏ̞̫͈y̭̺ͭc̦̹̟̦̭̫͊̿ͩeͥ̌̾̓ͨ
you really can't argue with C. and I don't hate perl, though really only for parsing text.

bash and ksh shell scripting is fairly straight forward. expect is nice.

php... getting better over the years... still a bit of a snail though.

but yeah, C is awesome... lets use that instead.
andre's avatar
14 years ago
link
andre
C is so unsafe... I wish stuff like http://cyclone.thelanguage.org/ would catch up and become mainstream.

There are many languages out there that make writing safe (and correct) software much easier... I wish the industry would support them but hey, who am I kidding...
maple's avatar
14 years ago
link
maple
i like large datasets
to me perl is ugly but i know it serves its purpose. dont mind shell scripting at all. not a fan of php. worked on it for years. and as you said "you really can't argue with C." i actually wish i was a better C developer. I do almost all web stuff these days or I'd be spending time working on improving my C skills.
asemisldkfj's avatar
14 years ago
link
asemisldkfj
the law is no protection
thanks for continuing to update this thread, maple!
bluet's avatar
13 years ago
link
bluet
I'm trying Emacs now. It's scary! :o
nny's avatar
13 years ago
link
nny
M̮͈̣̙̰̝̃̿̎̍ͬa͉̭̥͓ț̘ͯ̈́t̬̻͖̰̞͎ͤ̇ ̈̚J̹͎̿̾ȏ̞̫͈y̭̺ͭc̦̹̟̦̭̫͊̿ͩeͥ̌̾̓ͨ
Don't do it.
Chiken's avatar
13 years ago
link
Chiken
Don't Let Your Walls Down
yeah, im not a fan of emacs. ill stick with vi.
Carpetsmoker's avatar
13 years ago
link
Carpetsmoker
Martin
Resist the dark side!
maple's avatar
13 years ago
r1, link
maple
i like large datasets
im still on emacs these days. i wish i would have switched years ago. i do love vi still. alot. but i heard a quote before and i firmly believe this to be true.

"vi is for systems administrators and emacs is for developers"

as a person who went from being a systems admin to a developer and a vi user for over 10 years i feel like i can whole heartedly agree.

i tried emacs probably 5 times before i actually switched. just made myself use it for a month then it stuck. i hated it, it felt awkward and stupid. but now there are so many things that it excels at that its pretty much indispensable to me now.

@bluet -- just go get the emacs starter kit to begin with. and every once in a while read through the files to see what things do. if you dont understand dont worry about it. but as time goes on you will start to understand things then eventually start changing things, removing things, adding things. then i just started fresh at one point and just pulled in the things i wanted into a more simple format. now mine is much better (for me obviously) and cleaner.

here is mine http://github.com/adamrt/emacs.d

i've been doing some clean up on it last couple of days (i usually spend an hour or 2 a month to refine settings and add functionality and learn new features).

it starts with init.el and calls maple.el (which used to be much bigger - but now may just die).

then the two directories vendor and maple. vendor is 3rd party plugins and maple folder has my customization for specific modes and my keybindings etc.
maple's avatar
13 years ago
link
maple
i like large datasets
also, just fyi. i use it as my music player now (connected to mpd), vcs frontend (magit), python debugger (pyflakes), irc client (rarely use anymore), jabber/aim client, my shell (shell, not eshell), todo list (really nice for just quick entries and notes for later anywhere type -- Ctl-x t -- type todo, press enter, back to work), filebrowser (sometimes), may switch email client soon and more.

once they put a webkit browser in it i dont think ill ever leave it.

right now i only ever have open firefox (love firebug), emacs and skype (for people back home).
andre's avatar
13 years ago
link
andre
http://farm4.static.flickr.com/3628/344458826 … 77df_o.png
Carpetsmoker's avatar
13 years ago
link
Carpetsmoker
Martin
haha, what was that quote again? "Emacs is a great operating system, it just lacks a decent editor".
bluet's avatar
13 years ago
link
bluet
> once they put a webkit browser in it i dont think ill ever leave it.

http://www.haxney.org/2009/08/its-alive.html
lucas's avatar
13 years ago
link
lucas
i ❤ demo
haha
maple's avatar
11 years ago
link
maple
i like large datasets
I now use email in emacs too. mu4e is the client. Its fairly new but really nice. My org-mode skills are much higher now and I'm using it for lots of things.

Emacs has definitely improved my life by a small margin.
maple's avatar
6 years ago
link
maple
i like large datasets
Coming up on 10 years of Emacs! I had to look this thread up as I was showing a coworker emacs and I think my process of switching in this thread represents the switch well. Like stages of grief almost haha
lucas's avatar
6 years ago
link
lucas
i ❤ demo
haha good to hear from you!