Extracting SGN files used by the Israeli Court System

The Story

One of my friends has some dealings with the Israeli courts.
The noteworthy (and annoying) part of their digital documents is that these documents are using a novel format instead of some industry standard.
Files arriving by email have the SGN suffix, and the email includes the following …

more ...

The BIG BUTTON with Arduino

I've created a dramatic big button, that actually sends key presses to the computer.
It's connected to the computer via USB, and programmable via the same connection, meaning we can change the key presses it sends as we like.

The button

I got a factory button from eBay. The listing …

more ...

Adding a child element in XSLT

I recently had to edit a big XML file, and add a child elemnt to every element within. To simplify matters, say I had something like this:

<?xml version="1.0" encoding="UTF-8"?>
<rooty xmlns:ppl="some_identifier">
    <age …
more ...

Disqus instead of Juvia


I switched from Juvia to Disqus after losing all of my blog's comments

Why I lost all of my blog's comments

Basically, I was a fool.
I had my Juvia setup running on a single server in AWS, with a standalone mySQL server.
My setup auto-updated every time …

more ...

Sortiq - sort, uniq, sort

This is a small snippet I find extremely useful. You should have it in your ~/.bashrc:

sortiq() { sort | uniq -c | sort -rn ; }

It will count the instances of each line, sorting them from most common to least common.

What is this for

It answers the question "How much of each …

more ...

Driven by anger - my modus machinor

modus machinor - my adjustment of "modus operandi" for "engineering"

I recently noticed that I'm doing engineering work out of anger.
However, it seems like I'm doing a good job, so I thought I'd share my method, which I worked hard on.
You might recognize yourself in some of this, but …

more ...

Populating a NetworkX graph with a scanner

I had a graph living outside Pythonland (a commit tree with dependencies) and wanted to do graphy things to it. To do that, I first had to put the data into a NetworkX graph. I wrote this code bit to discover a graph-like structure and put into a NetworkX (or …

more ...

Getting Magent Links from Deluge

My latest weekend-hack is a plugin that shows the magnet link for a torrent entry


I had something torrented a long time ago, and a friend asked me for the torrent.
However, I haven't kept the original .torrent file, she was tech-oriented enough so I can give her the …

more ...

Prettify HTML pages with BeautifulSoup

The story

Today I wrote some HTML page by hand (my new homepage).
I then used this script to make the HTML code nicer:

The script

This requires the BeautifulSoup module for python

#!/usr/bin/env python

import sys
from bs4 import BeautifulSoup

def bs_file(filename):
    with open(filename, 'r …
more ...

My tips on Getting a Job

A lot of people (>3) asked me in the last month or so about how to land a first job after leaving the army / graduating from university, so I thought I'd write a post about it.
I think this post will mainly be helpful for those who look for their …

more ...