Skip to content

Instantly share code, notes, and snippets.

@arunpersaud
arunpersaud / transfer_issues_redmine_to_github
Created October 1, 2017 23:43
move issues from redmine to github
# Used this script to transfer issues from my old redmine installation to github
# just used two existing codes to export and import and just had to adapt this a tiny bit
from redminelib import Redmine # from https://python-redmine.com/resources/index.html
import urllib.request
import urllib.error
import urllib.parse
import json
import base64
import sys
@arunpersaud
arunpersaud / computed attributes
Last active August 29, 2015 14:19
how to simplify computed attributes
class mytest():
def init(self):
pass
def __getattr__(self, attr):
print("looking for ", attr)
print("keys: ", self.__dict__.keys())
if not ("_"+attr) in self.__dict__.keys():
if attr in ['a', 'b']: # would be nice to automate the next lines with a decorator on do_calc