Skip to content

Instantly share code, notes, and snippets.

View pahaz's full-sized avatar
🛠️
Yo ho ho

Pavel White pahaz

🛠️
Yo ho ho
View GitHub Profile
import os
__author__ = 'pahaz'
from dulwich.server import Backend, UploadPackHandler, ReceivePackHandler
from dulwich.repo import Repo
from dulwich import log_utils
from dulwich.server import (
TCPGitServer,
)
@pahaz
pahaz / dowloader.py
Created November 19, 2014 09:55
hack parsing task
import threading
import requests as r
import re
__author__ = 'pahaz'
def download(_from, _to, lock, f):
for i in range(_from, _to):
s = r.session()
@pahaz
pahaz / AsciiArtImage.cs
Last active August 29, 2015 14:09
Simple Ascii Art Image
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
class AsciiArtImage
{
static int[][] makeZebraImg(int width, int height)
{
@pahaz
pahaz / Redactor.cs
Last active August 29, 2015 14:10
Simple image redactor
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
class Redactor
{
static void Main(string[] args)
{
@pahaz
pahaz / hangmanpics.txt
Last active August 29, 2015 14:11
Виселица
HANGMANPICS
+---+
| |
|
|
|
|
=========
@pahaz
pahaz / ClickerGame.cs
Last active August 29, 2015 14:11
Simple clicker game
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace ClickerGame
{
class Program
@pahaz
pahaz / HTTPServer.cs
Last active August 29, 2015 14:11
Simple HTTP Server
using System;
using System.IO;
using System.Net;
using System.Net.Sockets;
using System.Text;
class HTTPServer
{
public static void Main()
{
@pahaz
pahaz / dz1.cs
Created February 21, 2015 15:51
awdadawda
using System.IO;
using System;
class Program
{
static void Main()
{
int z;
// afawfawfawfawf
@pahaz
pahaz / transliterate.py
Created February 22, 2015 19:28
Python safe transliterate print (kill UnicodeEncodeError)
#!/usr/bin/env python3
# encoding=utf-8
from __future__ import print_function
from __future__ import unicode_literals
import string
ru_lang_translit_map = {
"Я": "Ja", "Ю": "Ju", 'Э': 'E', 'Ь': '\'', 'Ы': 'Y', 'Ъ': '\'', "Щ": "Sch",
"Ш": "Sh", "Ч": "Ch", "Ц": "Ts", 'Х': 'H', 'Ф': 'F', 'У': 'U', 'Т': 'T',
'С': 'S', 'Р': 'R', 'П': 'P', 'О': 'O', 'Н': 'N', 'М': 'M', 'Л': 'L',
@pahaz
pahaz / Game.cs
Last active August 29, 2015 14:16 — forked from LevShab/Game.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Game
{
class Program
{