Latest Publications

[pySM] Updates

This person has been very busy, and still little work seems to be done.

In a nutshell, we’ve been busy getting the main website for pySM online. pySM is me and Tim‘s project into system management (There are some posts about it in this blog)

However, soon after getting quite the lot of url’s and basic apps online, I decided to change the url structure to become a littlebit more simple. Fact is that we were trying to overachieve, something that seems to happen to us a lot :(

Anyhow, pySM is currently online on 2 (yes, 2 url’s, instead of the douzen-or-so earlier) links:

  • pysm.be << Main site + Blog, makes sense that people interested in the project will directly see the progress. However we will probably in the future try to maintain a proper website with introduction, links, screenshots, documentation, world domination plans, etc…
  • trac.pysm.be << Trac site, contains documentation (raw material basically) and a webview for the bazaar repository. Tickets can be created over there too, although I don’t really see the use for the moment.

I hope that having this simpler structure will enable us to work more on pySM to get our first _decent_ version out. After that, we can try to overachieve again :)

Best of regards,
cpf

[pySM] Sites

Today all pysm sites (which used to be only trac) has been moved.

The “old” url (www.pysm.be) has been moved to the server hosting codercpf.be (Yes, this site)

We’ve changed the old only trac to seperated sites:

Update!

I put some url’s here last time, but those changed. For sake of having consistency, and not sending people to the wrong places, here are the updated ones :) (And the post announcing it on this blog)

  • pysm.be << Main site + Blog, makes sense that people interested in the project will directly see the progress. However we will probably in the future try to maintain a proper website with introduction, links, screenshots, documentation, world domination plans, etc…
  • trac.pysm.be << Trac site, contains documentation (raw material basically) and a webview for the bazaar repository. Tickets can be created over there too, although I don’t really see the use for the moment.

While we were at it, we changed the previous Subversion repository to a bazaar repo. Makes it a lot easier for us developers, although on first glance there’ll be little difference between the current bazaar repo and the Subversion way of doing things.

This will only be a small step into our attempt to rule the world using pysm!

Logo theft

Update: The site has removed the logo. Arch is victorious (linky)

As it appears, there is someone (in particular a company named Ace International Tutoring Pty Ltd) as outragious as it might seem, it is true.

As for the original article, it explains how the devs and official archlinux crew have come to the conclusion that this logo is indeed originaly theirs, and it has been “stolen” by someone thinking he can get away with it…

DIGG THE ARTICLE :)

Migrate from thunderbird to icedove in debian

Long title for a short post. I tried to search on google, and since I found nothing decent.

To migrate from thunderbird to icedove in debian linux, one only needs to rename the config directory of thunderbird:

mv .thunderbird .mozilla-thunderbird

Although I think this is stupid (I’d have prefered to see .icedove instead of .mozilla-thunderbird)

Enjoy your path towards ice* enlightenment…

PyDmenu: Python yeganesh clone

So, since I’m a long and happy yeganesh user, but I recently moved to debian and didn’t want to have the haskell overhead in my system, I wrote my own little implementation in python.

What is it?

PyDmenu tries to clone the yeganesh behavior. However, it has its own ups and downs. Currently, the code is made to work, not made to look good (it will look good in the future though)

It’s a shell above the dmenu application which is basically a simple launcher.

How to use?

Download the current .tar.bz2 file, untar:

$ tar xjfv pydmenu.tar.bz2

Using it like this:

$(/path/to/pydmenu.py)

will automatically execute the selected item. I have this in a script bound to mod4+p.

What else

The only thing handy would be to know that it creates a simple cPickle file in ~/pydmenu_save

To change any behavior you should edit the pydmenu.py file, the font, colors, etc… are in the DMENU array, only requirement there is to keep dmenu as first.

Enjoy, and please leave any comments (/emails) if something went wrong somewhere.

Linux: start new X with WM

Tried to keep the title short. In this article I’ll be trying to explain how to start a new X screen with some WM in it.

I wanted to use it to launch a new X screen for gaming purposes.

The code

In a nutshell, this is code that resembles the most basic functionality of startx (without the use of xinitrc of course). I found a serious lack of documentation about this… Although it is far from hard :)

Xorg :1 -ac -config xorg-game.conf &
DISPLAY=:1 openbox

This is actually really basic. It basically tells Xorg to start a new screen. Instead of :0 (standard), this will launch on :1 -> next we only need to make a wm (in this case openbox) start in that screen.

The script will take you directly at the new screen. Getting back at your first requires ctrl+alt+f7, your new one is at ctrl+alt+f8, and the next would be at ctrl+alt+f9, and so on.

PySM: sending IQ stuff

So, using sleekxmpp to send IQ set / get is quite simple, but requires some manual labor…

This is what I came up with, it’s all quite arbitrary, and can be put in a function easily. But at least now I finally figured out how to send IQ stuff. Receiving some might prove harder…

# Because the backbone works with this... >.>
from xml.etree import cElementTree as cET
[...]
iq = self.makeIqSet()
iq.attrib['from'] = self.fulljid
iq.attrib['to'] = 'test@localhost/bla'
query = self.makeIqQuery(iq, "pysm:iq:shutdown")
shutdown = cET.Element('shutdown')
query.append(shutdown)
shutdown.attrib['when'] = 'now'
self.send(iq)

The shutdown stuff is nothing at the moment, it doesn’t really do anything. The current server just displays the received xml…

Theme day 6: pySM + archer startpage

The 6th day is already nearly finished, and I haven’t really posted anything about it yet :o

So, as the title says I’ll be (have been) working on pySM and the archer startpage

Startpage

The startpage is now finally finished for as far as I wanted it. However, it’s possible that I’ll be adjusting the theme to a darker one.

The html entities are decoded, so everything in the feeds will be displayed properly in the pages. Links are clickable like they were for archlinux, titles are clickable to go to the original page, etc…

If there’s any comments on the layout, hit me at the forums

PySM

There’s little work been done this morning. However, a lot of work will be done on this from now.

Although I consider this version of the XMPP server complete enough to function in a simple environment, a lot of work will be required to get it at least scaled to a presentable result. Also, currently, I have no idea on how to make 2 clients communicate, so I won’t be able to patch through the most essential things at the moment. But since I can now connect, and test clients, I’ll be focussing on getting clients connected, and having clients send through valid iq requests. This shouldn’t be hard, but since I’d like to go on with sleekxmpp it might require some adjustments to their code to make that easier.

After that, I should still have some time to focus on module management. Since I’d like to have a sort of eventhandler in the server, those events will be linked to a module, which in return will be loaded and maintained by a module manager. So perhaps it’s not really the most difficult part, but it should work good, and be quite pluggable.

When that’s done, I hope to have some time left to figure out some way to have 2 clients communicate through the server. Patching through messages and iq requests and responses.

Anyhow, a lot of work needs to be done, and it’s not going to work itself, so I’ll be starting now :)

PySM: XMPP server connection established!

I’m totally surprised :) I managed to get my XMPP server implementation to a level that I’m capable of connecting with an XMPP client written in sleekxmpp!

The current result:

4841 cpf@phoenix % wc -cmlLw server.py
273   680 10520 10520    82 server.py

Translated:

  • 273 newlines
  • 680 words
  • 10520 bytes (and thus 10520 characters)
  • Maximum line length of 82 (which is not optimal, it should be 79…)

I feel quite satisfied. But I’m directly moving on. I’m going to see if I can scale sleekxmpp to send iq requests easily. Because that’s what our servers will probably do most of the time :)

After that, I’ll be looking into creating a class to manage, maintain and load modules dynamically and such. Will keep y’all posted :)

Archer startpages

So, in reaction to a post on the archlinux forums I created a small page on codercpf.be which hosted some static files best compared to an “archlinux startpage” at arch.codercpf.be

Now, because I wanted to create a startpage with the news updates and package updates too, I created such app in Django. It’s hosted at archer.codercpf.be

It was pretty easy to create, practical to start off, but damn. I hate django’s deploy stuff. I HATE IT. Constantly having problems with the media stuff.

Anyhow, now’s not the time to rant about it. I know the django devs are working hard to make django better and better, and I really like it.

So, the source is released in the public domain here: archer.codercpf.be/stuff/archer.tar.bz2 there’s not really a license, the code is simple enough :)