Skip to content

Instantly share code, notes, and snippets.

View mdornseif's full-sized avatar

mdornseif mdornseif

View GitHub Profile
@mdornseif
mdornseif / osm_shortlink.py
Created May 26, 2013 13:40
Implementation of OpenStreetmap Shortlinks in Python
@mdornseif
mdornseif / mt940toOFX.py
Last active July 14, 2020 13:42
Convert SWIFT MT940 data to OFX.
#!/usr/bin/env python
# encoding: utf-8
"""
mt940toOFX.py - Dieses Progrtamm liesst MT940 SWIFT Kontostände und konvertiert sie in OFX.
OFX wurde mit xero.com getestet.
Created by Maximillian Dornseif on 2010-06-05.
Copyright (c) 2010, 2013, 2014 HUDORA. All rights reserved.
"""
{
"meta": {
"code": 200
},
"data": {
"created_at": "2013-06-07T14:15:00Z",
"num_stars": 0,
"num_replies": 0,
"source": {
"link": "http:\/\/tigerbears.com\/felix",
{
"meta": {
"code": 200
},
"data": {
"created_at": "2013-06-07T14:14:04Z",
"num_stars": 0,
"num_replies": 0,
"source": {
"link": "http:\/\/riposteapp.net",
{
"meta": {
"code": 200
},
"data": {
"created_at": "2013-06-07T14:05:17Z",
"num_stars": 1,
"num_replies": 6,
"source": {
"link": "http:\/\/im-fluss.appspot.com",
"images": {
"low_resolution": {
"url": "http://distillery.s3.amazonaws.com/media/2010/07/16/4de37e03aa4b4372843a7eb33fa41cad_6.jpg",
"width": 306,
"height": 306
},
"thumbnail": {
"url": "http://distillery.s3.amazonaws.com/media/2010/07/16/4de37e03aa4b4372843a7eb33fa41cad_5.jpg",
"width": 150,
"height": 150
{
"meta": {
"code": 200
},
"data": {
"created_at": "2013-06-09T07:39:00Z",
"num_stars": 0,
"num_replies": 0,
"source": {
"link": "http:\/\/im-fluss.appspot.com",
{
"meta": {
"code": 200
},
"data": {
"created_at": "2013-06-09T21:35:09Z",
"num_stars": 1,
"num_replies": 0,
"source": {
"link": "http:\/\/im-fluss.appspot.com",
{
"meta": {
"code": 200
},
"data": {
"created_at": "2013-06-23T11:12:04Z",
"num_stars": 0,
"num_replies": 0,
"source": {
"link": "http:\/\/im-fluss.appspot.com",
#!/usr/bin/env python
# encoding: utf-8
import sys
def main():
if len(sys.argv) < 2:
sys.stderr.write('Usage: %s filename\n' % sys.argv[1])
sys.exit()