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 http.server import * | |
from http import HTTPStatus | |
import os, sys, io, socket, urllib.parse, html | |
class ApacheLikeHTTPRequestHandler(SimpleHTTPRequestHandler): | |
def list_directory(self, path): | |
"""Helper to produce a directory listing (absent index.html). |
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
linker_list | |
*.o |
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
#include <windows.h> | |
#include <spawn.h> | |
#include <sys/wait.h> | |
int main(int argc, char** argv, char** envp) | |
{ | |
if(argc < 2) | |
{ | |
SetThreadExecutionState(ES_SYSTEM_REQUIRED); | |
return 0; |
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
--local socket = require'socket' | |
-- http://lua-users.org/wiki/SplitJoin | |
-- explode(separator, string) | |
local function explode(d,p) | |
local t, ll | |
t={} | |
ll=0 | |
if(#p == 1) then | |
return {p} |
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
cd /opt/gitlab && patch -p2 < this-patch | |
--- opt/gitlab/embedded/lib/ruby/gems/2.5.0/gems/gitlab-grit-2.8.2/lib/grit_ext.rb.orig 2018-12-22 01:24:08.000000000 +0500 | |
+++ opt/gitlab/embedded/lib/ruby/gems/2.5.0/gems/gitlab-grit-2.8.2/lib/grit_ext.rb 2018-12-26 13:21:46.792000000 +0500 | |
@@ -22,7 +22,8 @@ | |
# encoding message to detect encoding | |
if detect && detect[:encoding] | |
- message.force_encoding(detect[:encoding]) | |
+ message.force_encoding("windows-1251") | |
+ message.encode("utf-8", "windows-1251", undef: :replace, replace: "", invalid: :replace) |
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
pkgname=libva1-ubuntu | |
pkgver=1.7 | |
pkgrel=1 | |
pkgdesc="Old libva from Ubuntu 16.04 for apps not supporting libva2 (esp. Parsec.tv)" | |
arch=('x86_64') | |
url="https://linux.palemoon.org" | |
license=('GPL' 'BSD') | |
depends=() | |
mirror="http://archive.ubuntu.com/ubuntu" | |
source=( |
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 | |
if [ -n "$BLOCK_BUTTON" ]; then | |
case $BLOCK_BUTTON in | |
1) yandex-disk start ;; | |
2) yandex-disk stop ;; | |
esac | |
fi 2>&1 >/dev/null | |
T=`LC_ALL=C yandex-disk status | head -n2` |
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
From 436f5d97ba3c0ebdfbd233f31751ca2ad5b6feba Mon Sep 17 00:00:00 2001 | |
From: =?UTF-8?q?=D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B0=D0=BD=D0=B4=D1=80?= | |
=?UTF-8?q?=D0=BE=D0=B2=20=D0=9E=D0=BB=D0=B5=D0=B3?= | |
<[email protected]> | |
Date: Tue, 12 Jul 2016 11:34:12 +0500 | |
Subject: [PATCH] execve patch series | |
--- | |
linux-user/main.c | 36 +++++++++++ | |
linux-user/qemu.h | 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
$ python vkfast.py | |
Python 2.7.11+ (default, Apr 17 2016, 14:00:29) | |
[GCC 5.3.1 20160413] on linux2 | |
Type "help", "copyright", "credits" or "license" for more information. | |
(InteractiveConsole) | |
>>> res = vk.messages.getDialogs() | |
>>> print res.response[1].body | |
<last chat's last message> |
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 | |
import os, sys | |
FILE=os.path.join(os.environ.get('HOME', ""), '.cache/trafficcount') | |
DEVICE=os.environ.get('BLOCK_INSTANCE','wlp13s0') | |
FILE2=os.path.join(os.environ.get('HOME', ""), '.cache/trafficcount_limit') | |
def parseSize(s): | |
TABLE={ 'K':2**10, | |
'M':2**20, | |
'G':2**30, |
NewerOlder