Saturday, March 26, 2011

Sending a gmail message from the good old command line. Part 1

  • What if you want a real time application to send you a mail if it encounters trouble?

I'll be using alpine and my gmail account for this purposes, I'm using Ubuntu Maverick. We need the alpine source code that can be downloaded here:

Once downloaded and extracted we need to apply this patch

Place the patch wherever you like, open a terminal there,  and issue the following command:

patch -p1 -d "path where you extracted the alpine source code" <alpine-2.00.outgoing.patch

in my case, I used this:

patch -p1 -d /home/jocker/alpine-2.00 <alpine-2.00.outgoing.patch

and if everything goes right you'll see the following output:

[sourcecode language="diff"]

patching file alpine/alpine.c
patching file alpine/arg.c
patching file alpine/busy.c
patching file alpine/confscroll.c
patching file alpine/osdep/termin.gen.c
patching file alpine/osdep/termin.gen.h
patching file alpine/osdep/termin.unx.c
patching file alpine/osdep/termout.unx.c
patching file alpine/radio.c
patching file alpine/reply.c
patching file alpine/roleconf.c
patching file alpine/send.c
patching file alpine/status.c
patching file pico/composer.c
patching file pico/display.c
patching file pico/edef.h
patching file pico/osdep/getkey.c
patching file pico/osdep/terminal.c
patching file pico/pico.c
patching file pico/pico.h
patching file pith/send.c
patching file pith/state.c
patching file pith/state.h
patching file pith/store.c


Or else, take a look here:

I followed  it to the letter but didn't work for me, it might for you.

Now we make sure we have anything we need to build it (again I'm using Ubuntu Maverick)

[sourcecode language="bash"]

sudo apt-get build-dep alpine


Now let's compile it  and install it with the well known combination:

[sourcecode language="bash"]



sudo make install


Then just type:


you should see the main menu now.

[caption id="attachment_162" align="aligncenter" width="300" caption="Alpine Main Menu"][/caption]

I'll post the next part (configuring it to use gmail) tomorrow. Or google it if you don't feel like waiting 'till tomorrow.






No comments:

Post a Comment