

A vim interface for gmail: Vmail - ezl
http://www.danielchoi.com/software/vmail.html

======
3amOpsGuy
When will we get a "programer's web browser"?

I mean a full blown browser of current generation abilities, but with the
option of completely keyboard driven interaction. Concise input of small
commands (navigation, data extraction, exploring and massaging of extracted
data, data uploading etc.) that can be composed to form more complex
interactions.

It should have full interoperability with the CLI, don't go re-inventing grep,
sed etc. but instead stand on their shoulders by interoperating fluently with
them. In practice i expect this means the "programer's browser" functions as a
full blown terminal emulator too.

If it were a text editor (and it should be a competent one of those, but the
web is more than a textual medium so some implementations should certainly
offer richer functionality than plain text editing) then the net and its many
protocols would be its filesystem.

It should be extensible, but only by 1 language. Competing programer's
browsers could offer alternative extension languages as their differentiator.

It should be entirely open for extension, by that i mean more than plugins, i
should be able to rip out core parts of it to be replaced with alternative
implementations (A's needs won't match B's needs and so on).

It shouldn't go too far though, it shouldn't be a full blown operating system:
why re-invent the wheel, reuse the thousands of man years effort in existing
OS's. It should be multi platform.

We almost have the requisite component parts available now, who's going to get
the ball rolling with the new wave of "programer's browsers"?

~~~
mikeplus48
There's luakit, uzbl, surf and jumanji from the top of my head, but I don't
think any of these have "full interoperability with the CLI". luakit is
definitely my favourite as it has been much more reliable than uzbl and easier
to configure/extend (in lua).

~~~
richo
Pentadactyl and Vimium if you want a "real browser" underneath too.

------
baydinalex
I love it. For decades, my flame war offensives against the evil crusaders of
Emacs have stalled out against their Maginot Line of "But Emacs can be your
mail client too!" This is like a Blitzkrieg of flame war glory. PARIS PREPARE
TO BE MINE!!!

~~~
yakiv
Victory shall not be yours until your precious Vim has both Tetris and Towers
of Hanoi. Emacs shall prevail.

~~~
rbonvall
Then victory was ours circa 2004 ;)

Tetris in Vim: <http://www.vim.org/scripts/script.php?script_id=172>

Towers of Hanoi: <http://www.vim.org/scripts/script.php?script_id=900>

~~~
yakiv
Hmm . . . the battle may be closer than I thought. Vim still must be inferior
somehow, right? :)

------
algorias
> To save you keystrokes, Vmail provides alternative key mappings for ,* , ,#,
> and ,!

Unfortunately, vmail doesn't seem to consider internationalization important
at all. US users save a single press of the shift key when starring messages
(,8 instead of ,*), but on a german keyboard, where the star is shift-3
instead of shift-8, the shift-less version of starring trashes the message
instead. Not a typo I'm eager to make.

Problems like this are, sadly, way too common.

~~~
ninjin
One, just as another user pointed out, remapping is easy.

Two, I personally think that most international keyboards I have used have
been any good at all for the tasks we face as programmers/hackers/developers.
They put an emphasis on producing text, not code, and if you spend most of
your day typing code and English anyway I can't see why we should "waste"
precious keyboard real-estate.

I ditched my Swedish layout during my first year at university, went US-style
and remapped the three keys that I needed to type "native" characters to
Start-key combos. I haven't looked back since. It was also the point where I
started touch-typing.

~~~
Derbasti
I did that, too. But I constantly switch back and forth when I'm writing
German code (think LaTeX). Pure coding is fine, and so is pure prose, but
whenever the two mix, its a pain.

------
kecebongsoft
While this is awesome, I am one of those guys who feel uncomfortable to store
my raw password in a dotfile, not to mention I'm managing my dotfiles in
Github, authentication in every run doesn't seem convenient either. I see that
this happens in other places such as Github gists-terminal and some twitter-
terminal clients. Is there any way we can store these credentials locally in a
safer way like SSH keys?.

~~~
dmmalam
OSX has keychain which is designed for these scenarios.

[http://www.dribin.org/dave/blog/archives/2006/01/16/keychain...](http://www.dribin.org/dave/blog/archives/2006/01/16/keychain_cli/)

[https://developer.apple.com/library/mac/#documentation/Secur...](https://developer.apple.com/library/mac/#documentation/Security/Conceptual/keychainServConcepts/01introduction/introduction.html)

~~~
chimeracoder
Several Linux tools for this purpose have existed for a while as well - gnome-
keyring (now seahorse)[1], KWallet, etc.

[1] <https://wiki.archlinux.org/index.php/GNOME_Keyring>

~~~
donniezazen
It came to my notice a few days ago that Gnome stored my Google Password in
Gnome Keyring as simple text.

~~~
chimeracoder
How did you come to this conclusion? If you've found a bug, please file a
ticket.

Gnome keyring definitely uses encryption to store passwords; they take
security pretty seriously:
<https://live.gnome.org/GnomeKeyring/SecurityPhilosophy>

~~~
kecebongsoft
I think what he meant was seahorse. I just tried it out and I can see my raw
passwords by clicking properties and ticking 'Show Password'. Shocked as well,
not to mention seahorse is launched without asking my password.

~~~
chimeracoder
> I can see my raw passwords by clicking properties and ticking 'Show
> Password'.

As opposed to what? They need to have access to the plaintext passwords
somewhere; it's just encrypted when it's stored on disk.

> Shocked as well, not to mention seahorse is launched without asking my
> password.

The default keychain uses your login password, and it's unlocked at login.
This is easy to change if you want to have to unlock it every time you use it.

------
pge
for vim fans, another option is mutt or alpine with vim as your editor. Both
work with gmail.

~~~
antidoh
Yeah. This is cool and all, but it's kind of like modifying your cigarette
lighter to carry passengers.

~~~
freshhawk
You could also look at it like carrying a cigarette lighter with you that you
like rather than using whatever fire making tool is around when you need one.

------
thezilch
Does it have support for two-factor auth? In the event of 2FA/MFA, I'm
assuming one needs to generate an application-specific password and keep that
in the .rc?

Alternatively, I see there are requests for using OAuth, which would be a
similar approach to have a "token" that can be revoked.

~~~
chimeracoder
> In the event of 2FA/MFA, I'm assuming one needs to generate an application-
> specific password and keep that in the .rc?

As far as I am aware, this is currently a limitation of any third-party client
that connects to Gmail.

~~~
ephemient
OAuth authentication for IMAP (via SASL):
[https://developers.google.com/google-
apps/gmail/oauth_overvi...](https://developers.google.com/google-
apps/gmail/oauth_overview)

I don't know if there are many clients that support it yet, though.

------
tmcw
Same guy as ViTunes. <3 <http://danielchoi.com/software/vitunes.html>

------
freshhawk
I hope you at least felt some pain in your soul when you wrote a vim plugin
for email that was gmail only.

Why on earth would you do that?

~~~
alpb
Welcome to Hacker News.

~~~
pestaa
Well, consider GP's assessment as envy of those who use Gmail and therefore
can benefit from this nice piece of software.

~~~
freshhawk
Yes, that's what I was told when I made similar comments about IE only
websites years ago as well.

How short of a memory does this community have if they don't understand what
comes after "embrace" and "extend"?

~~~
FuzzyDunlop
So the guy who wrote it uses gmail. There's no ulterior motive there. Just a
person who uses gmail who wanted to use it in vim

~~~
freshhawk
Oh certainly no ulterior motive, but these things never have ulterior motives,
just good people not doing what they should. I was just curious why it
wouldn't be just as easy to make it use imap rather than being gmail specific.
The idea of making an email client that only worked with email addresses from
a single domain would not even have occurred to me.

~~~
d0m
Sometime more specialized/specific is better.

For instance, Gmail _does_ support IMAP but also has non-IMAP features. Being
too abstract would mean avoiding providing these features.

Another point is the easiness of installation/configuration/usability. For
instance, with Emacs, you can use GNUs to read gmail. However, it is so
generic (you can read usenet news and any kind of e-mail), that it's really a
pain to get started. There are terminology confusions (i.e. you need several
hacks to have a gmail-like inbox) and overall, it just doesn't _feel_ like
g-mail..

Also, by starting very specific for our own problem, it's easier to create a
meaningful product that solves a real need. (Like startup!) I think it's
easier to start specialized and then grow larger, than start too brood.

------
tommorris
This is pretty awesome. I've used Mutt in the past but always found it a
little bit over-the-top. This is very, very simple to setup and does the job
pretty well.

But better than that... oh my word, the documentation. How I wish every
command line app had that kind of documentation. Just one page that documents
the shit out of it.

There's only one thing that would make it better: if that documentation came
bundled with the RubyGem so I could read it offline with `ri`.

------
purephase
This is insane. Amazing, but insane.

------
wheeee
Does this mean that vim is now officially finished?

~~~
tambourine_man
Zawinski's Law

Every program attempts to expand until it can read mail. Those programs which
cannot so expand are replaced by ones which can.

~~~
alexpopescu
Is there a generalization of Zawinski's Law postulating that "Every program
should expand until it can read itself"?

------
dysoco
Wow, I love the idea. I have always wanted to manage my mail via terminal, but
didn't want to set up Mutt or something similar.

~~~
ef4
Setting up mutt for GMail these days is no harder than setting up vmail. This
is a complete config file for mutt that will connect to your gmail account:

    
    
        set folder=imaps://imap.gmail.com:993
        set spoolfile=+INBOX
        set imap_user='your_username@gmail.com'
        set smtp_url = "smtp://your_username@smtp.gmail.com:587/"
    

If you don't want to enter your password every time, you can set it as
imap_pass (for reading) and smtp_pass (for sending).

~~~
leephillips
Exactly. I don't understand the advantage of "vmail" over mutt, which is
extremely powerful and mature, and of course can be configured to use vim, --
but I admit I just skimmed the link, so I could be missing something.

Note also that you must use caution when using Google's smtp and other network
services, as they tend to do whatever they want, regardless of RFCs and
standards[1].

[1]<http://lee-phillips.org/gmailRewriting/>

------
eggoa
To me, here at work on a Windows machine, that looks like way too many
dependencies for me. Looks cool, though.

~~~
bprater
With as much ram as people have on their machines these days, try
virtualizing!

~~~
lowboy
Especially with utilities such as Vagrant[0], for which there are many ready-
made boxes[1] that make short work of spinning up new VMs. My main development
"box" is a VM on a win host and it works wonderfully.

[0]: <http://vagrantup.com/>

[1]: <http://www.vagrantbox.es/>

------
alexpopescu
iawesome!thanks danielESC:wq

~~~
tsm
0~fti ^]2w~A!^]:x<RET>

------
jebblue
>> vmail important from barackobama@whitehouse.gov

Mmm...yeah I think I'll pass but hey, good idea up to that point.

------
tbirdz
It would be great if this had integrated gpg signing and encryption,
especially as firegpg doesn't work w/ gmail any more.

------
mathteacher1729
Perhaps it is a silly question, but what advantages does this offer over
Gmail's rather robust set of keyboard shortcuts?

------
Tichy
Why gmail and not email?

------
skrebbel
cool! plain curiosity: why gmail-only instead of imap?

------
tibbon
Also by Dan: instantwatcher.com

------
rymith
Thanks to google killing free Google Apps accounts, I won't get a chance to
use this. It's really sad because this is exactly what I was looking for.

~~~
richo
How is this better than mutt with EDITOR=vim ?

Not a smartass question.

~~~
rymith
I honestly haven't used mutt in a while, but I used to have a lot of issues
with it. I should give it another go.

~~~
richo
If you're on OSX, my fork of homebrew has some patches to make threading et al
work.

[https://github.com/richo/homebrew/blob/master/Library/Formul...](https://github.com/richo/homebrew/blob/master/Library/Formula/mutt.rb)

