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
| package main | |
| import ( | |
| "crypto/salsa20" | |
| "crypto/sha512" | |
| "encoding/binary" | |
| "unsafe" | |
| ) | |
| const ( |
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
| #!/usr/bin/env python3 | |
| import sys | |
| import os | |
| import subprocess | |
| from time import sleep | |
| import threading | |
| import time | |
| HOME = os.environ['HOME'] | |
| CACHE = '{}/.cache/vlcwrapper'.format(HOME) |
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/bash | |
| DEFAULT_WS="6:y" | |
| filename=$(playerctl metadata xesam:url) | |
| ext="${filename##*.}" | |
| case "$ext" in | |
| avi|mp4|mkv) | |
| t=v | |
| ;; |
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 os, random | |
| from time import sleep | |
| def command(com): | |
| return os.system('adb %s > /dev/null 2>&1' % com) | |
| def reboot(): | |
| return command('reboot') | |
| def shell(com): |
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
| #!/usr/bin/env python3 | |
| from twx.botapi import TelegramBot, send_message | |
| import time | |
| from collections import Counter | |
| polls = {} | |
| def aggregate_votes(votes): | |
| return '\n'.join('%s: %s' % (k,v) for k,v in sorted(Counter(votes.values()).items(), key=lambda x:x[1])) |
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
| #!/usr/bin/env python3 | |
| from twx.botapi import TelegramBot, send_message | |
| import time | |
| d = {} | |
| dr = {} | |
| bot = TelegramBot('bot-token') | |
| bot.update_bot_info().wait() |
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
| #!/usr/bin/env python | |
| def calc(gross, delivery, d): | |
| """ | |
| usage: | |
| >>> calc(120, 9, { | |
| 'Ashraf': 40, | |
| 'Thabet': 20, | |
| 'Awadi': 20, | |
| 'Ghanem': 20, |
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
| #!/usr/bin/env bash | |
| set -e | |
| function usage { | |
| echo "usage: $0 [create|remove] netns_name [network_ip]" | |
| exit 1 | |
| } | |
| if [ "$#" -lt "1" -o "$1" = "-h" -o "$1" = "--help" ]; then | |
| usage |
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
| // ==UserScript== | |
| // @name random_order | |
| // @namespace otlob | |
| // @description randomise order | |
| // @include https://www.otlob.com/* | |
| // @version 1 | |
| // @grant none | |
| // @authors Mohamed Elawadi <mohamed@elawadi.net>, Ahmed Thabet <xmonader@gmail.com> | |
| // ==/UserScript== | |
| Element.prototype.documentOffsetTop = function () { |
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
| function searchDeep(obj,query,objName){ | |
| var a = [] | |
| var b = function(obj,query,c){ | |
| if(~(a.indexOf(obj))) return [] | |
| a.push(obj) | |
| var d = [] | |
| if(query in obj){ | |
| d.push(c) | |
| } | |
| for(var j in obj){ |