TextPress ImageBox Plugin

TextPress jQuery ImgBox plugin support.


<span class="imagebox">
  <a href="/_uploads/my_image1.png">
    <img src="/_uploads/my_image1.thumbnail.png"/>
  <a href="/_uploads/my_image2.png">
    <img src="/_uploads/my_image2.thumbnail.png"/>

The needed step is to wrap your series ...

more ...

Webhelpers and Javascript Minification

Here’s a practical idea which I have in use in a project of mine.

Most of you probably use some javascript library or have some javascript files that you use in your pylons application.

There’s also some talk going on related to javascript files compression, and more recently, minification.

While I’m developing, I like to use the normal(non compressed) javascript files, because it helps on debugging. But for production, using compressed javascript files reduces page load times.

Pylons Webhelpers comes with a useful function to help you include javascript files on your templates, javascript_include_tag.

The idea I had was at first, make that function provide the minified version of the JS file if we’re not running our application in debug mode. If we are on debug mode, server the normal file.

So, I added a minified option to that function above, which does just that.

After a while, I wanted to know how I could minify my own javascript files, and I found out about JSMin. There’s also a python version of it.

That’s when I also thought, hell, I could minify my own javascript files upon request, and even cache that so the routine only runs once.

more ...

Rotating Trac Logs

So, you’re like me and like to have trac constantly logging to file and you hate those files getting huge?

It is assumed that you keep all your trac environments on the same base directory, for example /var/lib/trac/

Here’s a simple logrotate config file(normaly under ...

more ...

ZTE MF622 USB Modem Under Linux

I recently bought a 3G wireless card to use with my laptop, a ZTE, model MF622. Since the first time I tried Linux, also the first time I encountered this kind of problems with my USB ADSL modem, and this being an USB modem also, I knew I was going to have troubles.

At first I tried USB ModeSwitch which has experimental support for ZTE’s MF620 model with no luck. I then followed the instructions on the site to snoop the usb communication under M$ Win to get the messages being sent to the device so I could mimic that under Linux. Still, no luck.

I then tried to code a python script which used the libusb so that I could make the device switch to the modem configuration. Still, no luck.

I spent a lot of time on this subject and then one time I removed the usb_storage module while HAL was waiting for the device to settle down and guess what!? After a few seconds, the device changed itself to the modem configuration. All I needed now was to automate this procedure.

more ...

Irssi Notifier 0.2.0RC4 Released

Irssi Notifier 0.2.0RC4 Released

This is hopefully the last release candidate before the 0.2.0 version release.

It includes some bug fixes and some missing files on the distributed egg.

For detailed info on all changes please see the ChangeLog.

If you’d like to provide a ...

more ...