This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class StateLatch(object): | |
def __init__(self, changes_until_latched=2): | |
self._state = None | |
self.latch_count = changes_until_latched | |
@property | |
def state(self): | |
return self._state | |
@state.setter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am jpf on github. | |
* I am jfranusic (https://keybase.io/jfranusic) on keybase. | |
* I have a public key whose fingerprint is 535A 06B0 6A4A CE7C D80C CEA2 60C5 039A 605A A1DA | |
To claim this, I am signing this object: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import subprocess | |
import re | |
import collections | |
class NSPlistParser(): | |
'''Thanks to @rndmcnlly for writing this!''' | |
def __init__(self): | |
# these will all get interpreted as raw literal values in the parser |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
A DCW @001@ * VARIABLE "A" | |
B DCW @001@ * VARIABLE "B" | |
C DCW @000@ * VARIABLE "C" | |
COUNT DCW @000@ * VARIABLE "COUNT" | |
START MCS A,201+3 * MOVE A VARIABLE TO PRINT BUFFER | |
W * PRINT | |
LOOP BCE DONE,COUNT-1,1 * WHILE COUNT < 10 | |
MCS B,201+3 * MOVE B VARIABLE TO PRINT BUFFER | |
W * PRINT | |
A @1@,COUNT * COUNT++ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# * * * * * command to be executed | |
# - - - - - | |
# | | | | | | |
# | | | | +- - - - day of week (0 - 6) (Sunday=0) | |
# | | | +- - - - - month (1 - 12) | |
# | | +- - - - - - day of month (1 - 31) | |
# | +- - - - - - - hour (0 - 23) | |
# +- - - - - - - - minute (0 - 59) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python2 | |
# vim: set noexpandtab:ts=4 | |
# This Source Code Form is subject to the terms of the Mozilla Public | |
# License, v. 2.0. If a copy of the MPL was not distributed with this | |
# file, You can obtain one at http://mozilla.org/MPL/2.0/. | |
# Contributors: gdestuynder@mozilla.com | |
import ConfigParser | |
import base64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
oktachloride | |
oktachord | |
oktachordal | |
oktachronous | |
Oktacnemus | |
oktacolic | |
oktactinal | |
oktactine | |
Oktactiniae | |
oktactinian |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import time | |
import okta | |
# Get your very own Okta organization at: http://developer.okta.com | |
client = okta.AuthClient("https://example.okta.com", | |
"your-api-token") | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#rsyslog SERVER | |
# Activate kernel logging | |
$ModLoad imklog | |
# Activate TCP logging | |
$ModLoad imtcp | |
# Activate UDP logging | |
$ModLoad imudp | |
# Activate unix socket logging (used by syslog(3) system calls) | |
$ModLoad imuxsock | |
# Activate the 'ommail' module, used to forward messages via SMTP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# How to override DNS on Mac OS X 10.5 | |
sudo dscl localhost -create /Local/Default/Hosts/site.dom IPAddress 127.0.0.1 |
OlderNewer