Technical notes, my online memory
Wednesday, May 29, 2013
Puppet: service checking on OS X without using the inbuilt service stanza
›
Normal service enforcement is easy with puppet, it looks like this for an OS X launchdaemon: class something::myservice { File { owner ...
Friday, May 17, 2013
pdb and gdb conditional breakpoints
›
Use a debugger enough and you'll eventually be in a loop looking for a certain condition. And it's too tedious to walk through all ...
Tuesday, May 14, 2013
python set a variable conditional on another variable
›
Tiny python snippet. If you're doing this: if value: output = value else: output = 'somethingelse' Do this instead: outp...
Monday, May 13, 2013
Basic python chmod for windows
›
A basic python version of chmod for Windows using pywin32 : import ntsecuritycon import win32security DACL_PRESENT = 1 DACL_DEFAULT = 0 ...
Tuesday, May 7, 2013
Python: stub out windows libraries for testing on linux
›
Here's a quick way to stub out windows libraries when you are testing on Linux. This code creates empty modules using imp . import i...
Monday, May 6, 2013
Google coding style guides
›
I didn't actually realise how important code style guides were until I saw one consistently applied with style-checking tools: it makes ...
Chrome browser commandline switches
›
Chrome has a prodigious number of command line switches to control all sorts of behaviour. I recently ran into this one , which I think wi...
‹
›
Home
View web version