Skip to content

Instantly share code, notes, and snippets.

View mckelvin's full-sized avatar

GitHubLeakedPAN, GitHubLeakedMyautsai mckelvin

View GitHub Profile
@mckelvin
mckelvin / remove_jietumacapp.sh
Last active October 25, 2022 03:11 — forked from ITJesse/remove_jietumacapp
删除 QQ for Mac 的流氓截图
#!/bin/sh
chmod 0000 "/Applications/QQ.app/Contents/Library/LoginItems/QQ jietu plugin.app/Contents/MacOS/QQ jietu plugin"

Steps to upgrade vim in arch linux for python runtime support

Python support is needed by vim in order to run things like Conque and Slimv. Arch keeps vim slim by only providing Python support in gvim. But you may prefer vim to gvim, so here's what's needed.

More ABS info.

# Install and run abs (sync)

sudo pacman -S abs

@mckelvin
mckelvin / test.py
Created February 16, 2013 02:55 — forked from irachex/test.py
# coding: UTF-8
MAX_ELE = 20
count = {}
def traverse(dep, ele):
if ele > MAX_ELE: return
count[ele] = count.get(ele,0) + 1
for i in range(2 * dep + 1 - ele):
# traverse all child nodes [1+ele, 2 * dep + 1]
traverse(dep + 1, i + 1 + ele)
@mckelvin
mckelvin / TinyHTTPProxy.py
Created November 12, 2012 05:49 — forked from irachex/TinyHTTPProxy.py
Tiny HTTP Proxy. Usuage: python TinyHTTPProxy.py -p 11028
#!/usr/bin/python
__doc__ = """Tiny HTTP Proxy.
This module implements GET, HEAD, POST, PUT and DELETE methods
on BaseHTTPServer, and behaves as an HTTP proxy. The CONNECT
method is also implemented experimentally, but has not been
tested yet.
Any help will be greatly appreciated. SUZUKI Hisao