Skip to main content

Ralsina.Me — Roberto Alsina's website

Posts about linux (old posts, page 16)

Why I STILL use Arch Linux

Yes­ter­day I had one of those mo­ments where I feel very hap­py about my dis­tro of choice, Arch Lin­ux. Since the last time I post­ed about Arch seems to have been over two years ago (time flies when you are hav­ing fun!), I think it's time to ex­plain it.

I want­ed to test rst2pdf against re­port­lab from SVN, wor­daxe from SVN and do­cu­tils from SVN, and I want­ed it to be sim­ple.

So­lu­tion: I just pack­aged them in AUR!

Now, whenever I need to check rst2pdf agains wordaxe trunk, I just need to yaourt -S python-­wor­dax­e-svn and I can go back to stable wordaxe with yaourt -S python-­wor­daxe.

The svn pack­age will al­ways be the cur­rent trunk with­out any mod­i­fi­ca­tion­s, and I can switch back and forth in about 45 sec­ond­s, with­out mess­ing up my sys­tem's pack­ages.

Also, I can keep my installed SVN packages updated by doing yaourt -Su --de­v­el every now and then.

How would I have done that us­ing De­bian or a RPM dis­tro? I sup­pose by go­ing around the pack­ag­ing sys­tem (which I hate) or by do­ing a pri­vate re­po (which is so ... lame?) or by do­ing a pub­lic re­po (which is freak­ing work).

Re­al­ly, if you are a coder, I can't think of a Lin­ux dis­tro that makes life eas­i­er than Arch. Pret­ty much ev­ery­thing is there (12K pack­ages in un­sup­port­ed!) and if it is­n't, it's a 5-minute job to slap it in­to AUR and help the com­mu­ni­ty.

Sup­pose you are do­ing a KDE ap­p. On most dis­tros you need to in­stall your own from-­source copy of kdelibs to have the lat­est and make sure it's not screwed by dis­tro-spe­cif­ic patch­es.

On Arch? Patch­ing up­stream is frowned up­on. Not hav­ing the lat­est ver­sion is frowned up­on. So it's pret­ty much the ide­al en­vi­ron­ment to de­vel­op against KDE, or GNOME, or PyQt or what­ev­er.

If my life was not 150% com­mit­ted al­ready, I would try to be­come an Arch de­vel­op­er, or at least a TU (Trust­ed User). Maybe next life!

Grrr... I want one of these. I just need a reason.

I just saw this post about the Shee­vaP­lug. I need one. First I need a rea­son to need it.

  • Back­­up server? Add a USB disk en­­clo­­sure, put ev­ery­thing in a met­al box, in­­stall bac­u­la and-or rdif­f-back­­up?

  • Same hard­ware, Home MPD server?

  • Idem, home SAN?

  • Por­­ta­ble de­­mo server? I could in­­stall some so­lu­­tions on SD cards and show them for clients with this and my net­­book.

Sug­ges­tions ac­cept­ed...

Blog readership statistics.

I am not sure if this is good or bad:

feedburner

On one hand, I have more sub­scribers than ev­er, even con­sid­er­ing when this blog was in plan­etkde (BTW: maybe I should add my pyqt feed there again? Nah, I don't qual­i­fy as "ac­tive KDE con­trib­u­tor")

The dip in the last three monts was be­cause I just post­ed noth­ing, and now I am post­ing again, it's do­ing well.

On the oth­er hand, I am at 50-­some sub­scriber­s, which is a bit pa­thet­ic for a blog that has ex­ist­ed for over 9 years ;-)

On the grip­ping hand (Lar­ry Niv­en FTW!) I am hav­ing more fun with the blog than I had in quite a while, so I would post even if noone read it.

And in case you are won­der­ing what that peak of over 6000 reach (the av­er­age is un­der 100!) it's this. That post had over 12000 vis­i­tors. My sec­ond most pop­u­lar sto­ry had on­ly 3800.

analytics

Here's the most pop­u­lar con­tent in the last 2 years or so, se­lect­ed from 783 posts (784 with this one) and 47 longer sto­ries:

  1. 12228 vis­i­­tors: Win­­dows: My eX­Pe­ri­ence

    So I wan­t­ed to see what win­­dows looked like. Don't wor­ry, I feel bet­ter now.

  2. 3797 vis­i­­tors: Mak­ing Lin­ux sys­tems that don't suck. Part II

    A rant on cron and at. I nev­er imag­ined this would be num­ber 2.

  3. 2968 vis­i­­tors: BOP: Ball Ori­en­t­ed pro­­gram­ming

    I am rather proud of this one: a pyqt-based graph­i­­cal, an­i­­mat­ed in­­ter­preter for FLIP, a lan­guage based on balls :-)

  4. 2888 vis­i­­tors: Good News: Lin­ux gives life to old hard­ware. Bad News: Maybe in some cas­es it should­n't.

    Sil­­ly, yes, but a cool pic­­ture :-)

  5. 1870 vis­i­­tors: Py­­Cel­l­s: The Python Spread­­Sheet re­­dux

    My sec­ond or third at­tempt at writ­ing a toy spread­­sheet us­ing python. I have been at it for about 5 years, ap­­par­en­t­­ly.

    This is pop­u­lar... even when the code it de­scribes is based on a com­­plete­­ly bro­ken li­brary!

  6. 1841 vis­i­­tors: Squid au­then­ti­­ca­­tion via POP or IMAP

    This was al­ready about 4 years old when I start­ed coun­t­ing, so I have no idea how many vis­i­­tors it re­al­­ly had. It is a handy scrip­t, I still use it some­­times!

  7. 1813 vis­i­­tors: The Lin­ux Boot­ing Process Un­veiled

    I re­al­­ly ex­pec­t­ed this one to be much high­­er. It's even linked from wikipedi­a! Ev­ery day it has 2 or 3 hit­s. Then again, the first 3 years are not be­ing coun­t­ed ;-)

  8. 1706 vis­i­­tors: Queue Man­age­­ment for Qmail

    While the tool it in­­tro­­duces is lame nowa­­days, the ideas are sound, and it ex­­plains a re­al prob­lem.

  9. 1548 vis­i­­tors: Cus­­tom wid­gets us­ing PyQt

    Very ob­­so­lete, noone should read that.

  10. 1505 vis­i­­tors: How to make your own dis­­tro in 3 not-­­so sim­­ple steps

    Oh, this one. It is wrong. It gives bad ad­vice. Yet noone seems to no­tice ;-) Not my best idea, not my best ef­­fort, still get email about it ev­ery month or so.

Old fashioned mail: Cone

I had one too many prob­lems with kmail from KDE4 in my eee with Kubun­tu, and sylpheed-­claws is just un­us­able in a small screen (the huge wid­get­s! the non-hid­able things all over the in­ter­face!) I de­cid­ed to get old fash­ioned and try a con­sole mail read­er.

I was a pine us­er for many years, and a mutt us­er for a while, and I was deeply dis­ap­point­ed that the last three years have been bad for these pro­gram­s.

Just be­cause you run in a ter­mi­nal, there's no rea­son to be hard to con­fig­ure! Af­ter spend­ing 20 min­utes try­ing to get a de­cent IMAP ac­count set­up (just two IMAP ac­counts) in alpine and an­oth­er 10 won­der­ing if mutt re­al­ly had no place in the UI for ac­count con­fig­u­ra­tion (and whether the De­bian/KUbun­tu de­fault "com­ment­ed" con­fig file is the prod­uct of hard drugs), I tried Cone.

It was blis­s. It was all I re­mem­bered from pine years ago (on lo­cal ac­counts) on­ly over IMAP.

Easy to con­fig­ure, easy to use, quick, ca­pa­ble. I was in love all over again.

While I will keep us­ing KMail on my main note­book un­der Arch Lin­ux where I had no re­li­a­bil­i­ty prob­lems what­so­ev­er, I have Cone con­fig­ured in my server's shell ac­count and in the eee.

Linux as a windows crutch: Sending SMS

Sup­pose you want to send SMS mes­sages from win­dows through a blue­tooth con­nec­tion to a phone.

I am sure you can make it work. On the oth­er hand, I al­ready had it work­ing on Lin­ux... so you can just use this on a friend­ly Lin­ux box, and send SMS mes­sages by ac­cess­ing a spe­cial URL:

#!/usr/bin/env python
from colubrid import BaseApplication, HttpResponse, execute
import os

class SMSApplication(BaseApplication):

  def process_request(self):
      numero = self.request.args.get('numero')
      mensaje = self.request.args.get('mensaje')
      [entrada,salida]=os.popen4('/usr/bin/gnokii --sendsms %s'%numero,mode='rw')
      entrada.write(mensaje)
      entrada.flush()
      entrada.close()
      msg=salida.read()
      response = HttpResponse(msg)
      response['Content-Type'] = 'text/plain'
      return response

if __name__ == '__main__':
  execute(SMSApplication,debug=True, hostname='mybox.domain.internal', port=8080,reload=True)

If someone opens http://my­box.­do­main.in­ter­nal:8080/?nu­mero=1234?­men­saje=ho­la%20­mun­do it sends "hola mundo" to the 1234 number.

I sup­pose I could call this a web tele­pho­ny ser­vice or some­such, but it's ac­tu­al­ly just the 5'­so­lu­tion that came to mind.

It us­es a sil­ly lit­tle not-a-we­b-frame­work called col­u­brid in­stead of some­thing you may know, be­cause I want­ed to keep it sim­ple, and it does­n't get much sim­pler than this.


Contents © 2000-2020 Roberto Alsina