Skip to content

Instantly share code, notes, and snippets.

View cloverstd's full-sized avatar
🀄
Working for living

cloverstd cloverstd

🀄
Working for living
View GitHub Profile
# -*- coding: utf-8 -*-
# http://boxcar.io
# send message to mobile
__author__ = "Cloverstd"
import urllib
import urllib2
import json
@cloverstd
cloverstd / qiniu_download.sh
Created July 24, 2014 01:48
七牛批量下载
#!/bin/bash
key="infopush.debug.log.2014-07-"
suffix=".tar.gz"
for ((j=16; j<24; j++)); do
key_day=${key}${j}"-"
for ((i=0; i<24; i++)); do
if ((${i} < 10));then
key22="22/"${key_day}"0"${i}
@cloverstd
cloverstd / main.py
Last active August 29, 2015 14:06
IFTTT webhook by Python with Tornado
#!/usr/bin/env python
# encoding: utf-8
from tornadorpc.xml import XMLRPCHandler
import tornado.ioloop
import tornado.httpserver
import tornado.web
@cloverstd
cloverstd / public_key
Last active August 29, 2015 14:20
gench key
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDolyzLgc+keal0kSgpG24smd8pk0c7jgzcebRMrWiTqYpcu8ber6KjUf8nBLKVvx8t2K40c+xIUA7ptMryXiAz6tCckFC2rTmp7S7gqdjpEk0HgGU+m/WliZDyV1X0cYqiG2y/KlizDxgR40uAYXhRgT3dfrcQi5GO9qg+dUDip9lBsF2f/lnOOmYOVJMEHu77NklyWOMa3DJF1BiTxe+CtFd4sU0P7oidemik099HqWSf3lgxYqu/rgqCumLIHWF/CI8714xlfe64lcsTwMJsd7xL0qgTYvDmLmynFKwQEsDgvcZcRNEEI5pkC9kZ9/rQBDr8yaobArRo7QGXM3KD cloverstd@gmail.com
@cloverstd
cloverstd / jobs.py
Last active August 29, 2015 14:20
python-rq with tornado asynchronous
#!/usr/bin/env python
# encoding: utf-8
import time
def test(interval):
for i in xrange(int(interval)):
print i
time.sleep(1)
@cloverstd
cloverstd / shanbay2rss.py
Last active October 3, 2015 15:03
扇贝打卡 RSS 源
#!/usr/bin/env python
# encoding: utf-8
from __future__ import absolute_import, unicode_literals
import tornado.ioloop
import tornado.httpserver
from tornado.options import parse_command_line, define, options
import tornado.httpclient
import tornado.web
import tornado.gen
@cloverstd
cloverstd / surge.conf
Created October 4, 2015 04:04 — forked from janlay/README.md
Yet another config for Surge.app
[General]
# warning, notify, info, verbose
loglevel = notify
[Proxy]
# http, https, socks5
Proxy = custom, 1.2.3.4, 443, rc4-md5, password, http://server/custom.module
[Rule]
# Block privacy trackers
@cloverstd
cloverstd / gist:2849259
Created June 1, 2012 05:47 — forked from zythum/gist:2848881
google收录的敏感词
@cloverstd
cloverstd / rc,lua
Created July 16, 2012 13:24 — forked from fanzeyi/rc,lua
awesome.config
-- Standard awesome library
require("awful")
require("awful.autofocus")
require("awful.rules")
-- Theme handling library
require("beautiful")
-- Notification library
require("naughty")
naughty.config.default_preset.width = 400
@cloverstd
cloverstd / call.html
Created October 16, 2015 01:51
Flask macro gist
{% import 'pagination.html' as pagination %}
{% call(page) pagination.paginate(page, last_page) %}
{{url_for('manage.order_list')}}?page={{page}}&status={{status}}
{% endcall %}