This file contains hidden or 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 zipfile | |
class StreamedBytesIO(object): | |
def __init__(self): | |
self._b = bytearray() | |
self._pos = 0 | |
def seek(self, *args): | |
raise AttributeError('sorry') |
This file contains hidden or 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 gevent | |
import gevent.local | |
import gunicorn.app.wsgiapp | |
import psycopg2 | |
import psycopg2.errors | |
import psycopg2.extensions | |
import sqlalchemy.util |
This file contains hidden or 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
# actually displayed colors corresponding to black, white, magenta etc. | |
# are changed by alacritty | |
if status --is-interactive; and test $TERM = alacritty | |
# the completion itself, i.e. the proposed rest of the string | |
set fish_pager_color_completion normal | |
# background of the selected completion | |
set fish_pager_color_selected_background --background=bryellow | |
# the completion description | |
set fish_pager_color_description brblack |
This file contains hidden or 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/sh | |
# initially empty image with 8GiB max size | |
truncate -s 8GiB sda.img | |
# make dos (mbr) table with one partition | |
cfdisk sda.img | |
# mount image as loopback | |
DEV=$(sudo losetup --find --show --partscan sda.img) | |
# make root fs |
This file contains hidden or 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/libpython.py 2022-03-23 18:38:36.000000000 +0300 | |
+++ b/libpython.py 2022-04-09 17:34:59.590014916 +0300 | |
@@ -370,10 +370,14 @@ | |
'frozenset' : PySetObjectPtr, | |
'builtin_function_or_method' : PyCFunctionObjectPtr, | |
'method-wrapper': wrapperobject, | |
+ 'module': PyModuleObjectPtr, | |
} | |
if tp_name in name_map: | |
return name_map[tp_name] |
This file contains hidden or 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/fish | |
if test (count $argv) -lt 1 | |
echo run-sus-command '*proc*' >&2 | |
exit 1 | |
end | |
# running as current (unprivileged?) user | |
set args --user | |
# running in foreground |
OlderNewer