Skip to content

Instantly share code, notes, and snippets.

Section "Files"
ModulePath "/usr/lib/xorg/modules"
FontPath "/usr/share/fonts/X11/misc"
FontPath "/usr/share/fonts/X11/cyrillic"
FontPath "/usr/share/fonts/X11/100dpi/:unscaled"
FontPath "/usr/share/fonts/X11/75dpi/:unscaled"
FontPath "/usr/share/fonts/X11/Type1"
FontPath "/usr/share/fonts/X11/100dpi"
FontPath "/usr/share/fonts/X11/75dpi"
[{'bet': 0,
'game_id': 358,
'money': 200000,
'queuetime': 1323093392.1033559,
'serial': 4226,
'type': 'PacketPokerPlayerChips'},
{'bet': [],
'game_id': 358,
'length': 19,
'money': [500, 8, 1000, 4, 2000, 1, 2500, 4, 5000, 4, 10000, 6, 25000, 4],
@yacc143
yacc143 / test-pokeravatar.py
Created October 28, 2011 14:55
test-pokeravatar.py
#!/home/andreas/customers/pokermania/bin/python
# -*- mode: python -*-
#
# Copyright (C) 2007 - 2010 Loic Dachary <loic@dachary.org>
# Copyright (C) 2008, 2009 Bradley M. Kuhn <bkuhn@ebb.org>
# Copyright (C) 2008 Johan Euphrosine <proppy@aminche.com>
#
# This software's license gives you freedom; you can copy, convey,
# propagate, redistribute and/or modify this program under the terms of
# the GNU Affero General Public License (AGPL) as published by the Free
from twisted.python import log
import sys
class LogCollector(list):
def __init__(self):
list.__init__(self, [])
self.saved = []
def __call__(self, ev):
self.append(ev)
(poker):~/customers/pokermania/poker-network/poker-network$ egrep ',19384|,47045' /tmp/node.client.log
1:-->,1318444334442,7934,BOT144,390,tourn,47045,{"type":"PacketPokerLongPoll"},92238
1:-->,1318444334452,7891,BOT101,390,tourn,19384,{"type":"PacketPokerLongPoll"},96549
1:<--,1318444354451,7934,BOT144,390,tourn,47045,[],,112247
1:<--,1318444354457,7891,BOT101,390,tourn,19384,[],,116554
@yacc143
yacc143 / gist:1265577
Created October 5, 2011 20:23
error checking runs
root@andidesk:~# md5sum --check <checkfiles.log | grep -v OK$
/home/torrents/00667: FEHLSCHLAG
/home/torrents/00722: FEHLSCHLAG
/home/torrents/01542: FEHLSCHLAG
/home/torrents/01555: FEHLSCHLAG
/home/torrents/01632: FEHLSCHLAG
/home/torrents/01648: FEHLSCHLAG
/home/torrents/02445: FEHLSCHLAG
/home/torrents/02654: FEHLSCHLAG
/home/torrents/02701: FEHLSCHLAG
@yacc143
yacc143 / createCheckfiles
Created October 5, 2011 18:12
a short hdd corruption tester
#!/bin/bash
LOGFILE=${LOGFILE:-/root/checkfiles.log}
if [[ $# -ne 2 ]]
then
echo $#
echo $@
fi
@yacc143
yacc143 / gist:1250201
Created September 29, 2011 07:37
my freezing problem
[76022.953882] ata4.00: exception Emask 0x0 SAct 0x7fffffff SErr 0x0 action 0x6 frozen
[76022.953898] ata4.00: failed command: READ FPDMA QUEUED
[76022.953915] ata4.00: cmd 60/08:00:e0:b2:cb/00:00:02:00:00/40 tag 0 ncq 4096 in
[76022.953918] res 40/00:00:00:4f:c2/00:00:00:00:00/00 Emask 0x4 (timeout)
[76022.953925] ata4.00: status: { DRDY }
[76022.953931] ata4.00: failed command: READ FPDMA QUEUED
[76022.953944] ata4.00: cmd 60/08:08:00:b3:cb/00:00:02:00:00/40 tag 1 ncq 4096 in
[76022.953947] res 40/00:00:00:00:00/00:00:00:00:00/00 Emask 0x4 (timeout)
[76022.953953] ata4.00: status: { DRDY }
[76022.953959] ata4.00: failed command: READ FPDMA QUEUED
@yacc143
yacc143 / gist:1248325
Created September 28, 2011 15:58
grep for fun
(poker):~/customers/pokermania/poker-network/poker-network/pokernetwork$ grep LongPollReturn *.py
pokerpackets.py:class PacketPokerLongPollReturn(Packet):
pokerpackets.py:Packet.infoDeclare(globals(), PacketPokerLongPollReturn, Packet, "POKER_LONG_POLL_RETURN", 168) # 168 # 0xa8 # %SEQ%
pokerrestclient.py: self.sendPacketData('{ "type": "PacketPokerLongPollReturn" }')
(poker):~/customers/pokermania/poker-network/poker-network/pokernetwork$