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 | |
USER='devconfcz' | |
PASSWORD='Brno2019' | |
curl https://147.229.254.98/login.php \ | |
-H 'Host: wifigw.cis.vutbr.cz' \ | |
-H 'Content-Type: application/x-www-form-urlencoded' \ | |
--data "user=${USER}&auth=any&password=${PASSWORD}" \ | |
--compressed -k -o /dev/null |
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
@namespace xul url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul); | |
#tabbrowser-tabs { | |
visibility: collapse; | |
} | |
#sidebar-box[sidebarcommand="_0ad88674-2b41-4cfb-99e3-e206c74a0076_-sidebar-action"] #sidebar-header { | |
visibility: collapse; | |
} |
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 | |
name='John Doe' | |
email='[email protected]' | |
path=$( dirname $0 ) | |
while [ -n "$1" ]; do | |
case "$1" in |
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
select | |
number_id, | |
sum(case when gate = 1 then points end) gate1, | |
sum(case when gate = 2 then points end) gate2, | |
sum(points) points_total | |
from check | |
group by number_id; |
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
function SETTLE_UP(data) { | |
var min = 0; | |
var max = 0; | |
var debter = 0; | |
var crediter = 0; | |
var amount = 0; | |
var names = data[0]; | |
var values = data[1]; | |
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 simplejson as json | |
import lxml | |
class objectJSONEncoder(json.JSONEncoder): | |
"""A specialized JSON encoder that can handle simple lxml objectify types | |
>>> from lxml import objectify | |
>>> obj = objectify.fromstring("<Book><price>1.50</price><author>W. Shakespeare</author></Book>") | |
>>> json.dumps(obj, cls=objectJSONEncoder) | |
'{"price": 1.5, "author": "W. Shakespeare"}' | |
""" |
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
(lambda _, __, ___, ____, _____, ______, _______, ________: | |
getattr( | |
__import__(True.__class__.__name__[_] + [].__class__.__name__[__]), | |
().__class__.__eq__.__class__.__name__[:__] + | |
().__iter__().__class__.__name__[_____:________] | |
)( | |
_, (lambda _, __, ___: _(_, __, ___))( | |
lambda _, __, ___: | |
chr(___ % __) + _(_, __, ___ // __) if ___ else | |
(lambda: _).func_code.co_lnotab, |
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
<VirtualHost *:80> | |
ServerAdmin [email protected] | |
DocumentRoot /var/www/flask/lillyleague | |
ServerName atea.skrle.cz | |
WSGIDaemonProcess lillyleague user=jask group=jask threads=1 home=/var/www/flask/lillyleague | |
WSGIScriptAlias / /var/www/flask/lillyleague/wsgi.py | |
WSGIPassAuthorization On | |
<Directory /var/www/flask/lillyleague> |
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 | |
# author: jask | |
# WARNING: this script is intended to use only for those who have deep understanding how it works, so enjoy the fun with it ;) | |
interpret='bash' | |
#ssh_args='-i .ssh/atollon' | |
#user='jask' | |
usage(){ |
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 re | |
import string | |
import sys | |
class Flipper(object): | |
flip_re = re.compile('\[([a-z]{2})\]') | |
def __init__(self, board_size=19): | |
self.board_size = board_size |