Skip to content

Instantly share code, notes, and snippets.

@hit9
hit9 / gist:cde563db0a84d97a0a4d771c2a86b8da
Last active November 27, 2023 07:45
建议的接口形式

如果不要求轨迹回传,可以只新增一个接口。

配送状态节点(粗颗粒度):

PENDING = 1 // 等待取货
DELIVERING = 5 // 已取货、配送中
ARRIVED = 10 // 已送达
CANCELED = 99 // 已取消
@hit9
hit9 / ngx-lua.sh
Created March 9, 2015 10:57
Script to compile nginx on ubuntu with lua support.
#!/bin/sh
# Script to compile nginx on ubuntu with lua support.
NGX_VERSION='1.6.2'
LUAJIT_VERSION='2.0.3'
LUAJIT_MAJOR_VERSION='2.0'
NGX_DEVEL_KIT_VERSION='0.2.19'
LUA_NGINX_MODULE_VERSION='0.9.15'
# coding: utf-8
from flask import Flask
from werkzeug.wsgi import pop_path_info, peek_path_info
from werkzeug.serving import run_simple
app = Flask(__name__)
class PathDispatcher(object):

Getting Started with NPM (as a developer)

If you haven't already set your NPM author info, now you should:

npm set init.author.name "Your Name"
npm set init.author.email "you@example.com"
npm set init.author.url "http://yourblog.com"

npm adduser

import sys
from PySide.QtCore import QObject, Slot
from PySide.QtGui import QApplication
from PySide.QtWebKit import QWebView
html = """
<html>
<body>
<h1>Hello!</h1><br>
/)
/ )
/ )
/ )
/
/ Quill
/ ~ ~ ~
/)
/ )
(\ / )
( \ / )
( \/ / )
(@) )
/ \_ \
// \\\
(( \\
~ ~ ~ \

Follow these steps to install graphite on OS X Lion.

Prerequisites

  • Python 2.7
  • Brew
  • Git

Install dependencies

Install Cairo

@hit9
hit9 / 00-index.txt
Created December 8, 2013 14:06 — forked from knzm/00-index.txt
- Install xhtml2pdf (former "pisa").
http://www.xhtml2pdf.com/
- Install Takao Font (TakaoPGothic.ttf).
https://launchpad.net/takao-fonts/
- Modify conf.py as below.
- Modify Makefile as below.
@hit9
hit9 / gist:7639670
Created November 25, 2013 10:58 — forked from kran/gist:6291095
xfconf-query -c xsettings -p /Gtk/KeyThemeName -s Emacs