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
#!/bin/bash | |
# steamcmd doesn't handle the shebang line, so lets remove it :\ Woo | |
# Use Tail to strip first line (print all lines starting at 2) of our input file | |
# Call steamcmd with automatic login and automatic exit | |
steamcmd +login ${STEAMLOGIN:-thorsummoner0} +runscript <(tail -n+2 $1) +exit |
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
# Given your quid-deb-proxy is using the hostname `apt` and has avahi-daemon installed | |
# Change /etc/apt-fast.conf to include `--async-dns=false --http-proxy=apt.local` | |
_DOWNLOADER='aria2c -c -j ${_MAXNUM} --async-dns=false --http-proxy=apt.local -i ${DLLIST} --connect-timeout=600 --timeout=600 -m0' | |
# Using aysnc-dns will hit this line in aria2c: | |
# https://github.com/aria2/aria2/blob/a1ce6d2e7f8824b1c1cd18d4e531d84ba58a07df/src/AbstractCommand.cc#L788 | |
# Due to this behavor getting set: | |
# https://github.com/aria2/aria2/blob/a1ce6d2e7f8824b1c1cd18d4e531d84ba58a07df/src/AbstractCommand.cc#L788 | |
# |
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 inspect | |
depth = 0 | |
def props(obj): | |
global depth | |
depth += 1 | |
pr = {} | |
for name in dir(obj): | |
try: | |
value = getattr(obj, name) |
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
{'ERROR': 128, | |
'FAST_FORWARD': 64, | |
'FORCED_UPDATE': 32, | |
'HEAD_UPTODATE': 4, | |
'NEW_HEAD': 2, | |
'NEW_TAG': 1, | |
'REJECTED': 16, | |
'TAG_UPDATE': 8, | |
'_flag_map': {' ': 64, '!': 128, '*': 0, '+': 32, '-': 8, '=': 4}, | |
'flags': 4, |
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
#2d2d2d,#3E313C,#666666,#FFFFFF,#3E313C,#FFFFFF,#d64937,#D64937 |
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 sys | |
import png | |
import random | |
import itertools | |
def rand(entries): | |
for _ in range(entries): | |
val = random.choice([0, 255]) | |
assert val != 2 |
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 python | |
import argparse | |
import cairo | |
from gi.repository import Gtk | |
from gi.repository import Gdk | |
from gi.repository import GdkPixbuf | |
from gi.repository import GObject |
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 argparse | |
class ActionFlagWithNo(argparse.Action): | |
""" | |
Allows a 'no' prefix to disable store_true actions. | |
For example, --debug will have an additional --no-debug to explicitly disable it. | |
""" | |
def __init__(self, opt_name, dest=None, default=True, required=False, help=None): | |
super(ActionFlagWithNo, self).__init__( | |
[ |
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
# Byte-compiled / optimized / DLL files | |
__pycache__/ | |
*.py[cod] | |
*$py.class | |
# C extensions | |
*.so | |
# Distribution / packaging | |
.Python |
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
Oniguruma Regular Expressions Version 5.9.1 2007/09/05 | |
syntax: ONIG_SYNTAX_RUBY (default) | |
1. Syntax elements | |
\ escape (enable or disable meta character meaning) | |
| alternation | |
(...) group |