Skip to content

Instantly share code, notes, and snippets.

View leoncamel's full-sized avatar
Focusing

Xiaolin Zhang leoncamel

Focusing
  • Beijing
View GitHub Profile
brew --config
HOMEBREW_VERSION: 0.9
HEAD: 28a2dfd8b6fa0225bc6cc8d196652ec0c87e39b9
HOMEBREW_PREFIX: /Users/leoncamel/bin/homebrew
HOMEBREW_CELLAR: /Users/leoncamel/bin/homebrew/Cellar
CPU: quad-core 64-bit arrandale
OS X: 10.7.3
Kernel Architecture: x86_64
Xcode: 4.3
GCC-4.0: N/A
require 'formula'
class Highlight < Formula
url 'http://www.andre-simon.de/zip/highlight-3.8.tar.bz2'
homepage 'http://www.andre-simon.de/doku/highlight/en/highlight.html'
sha1 '007a008f1846485e86ad9347f98f69a22afeb718'
depends_on 'boost'
depends_on 'lua'
;;; win-switch.el --- fast, dynamic bindings for window-switching/resizing
;; Copyright (C) 2011, 2012 Christopher R. Genovese, all rights reserved.
;; Author: Christopher Genovese <genovese@cmu.edu>
;; Maintainer: Christopher R. Genovese <genovese@cmu.edu>
;; URL: http://www.stat.cmu.edu/~genovese/emacs/win-switch/
;; Version: 1.0.2
;; Update#: 12
diff --git a/lisp/term/ns-win.el b/lisp/term/ns-win.el
index df0ddd7..c576f02 100644
--- a/lisp/term/ns-win.el
+++ b/lisp/term/ns-win.el
@@ -930,6 +930,10 @@ See the documentation of `create-fontset-from-fontset-spec' for the format.")
(add-to-list 'frame-creation-function-alist '(ns . x-create-frame-with-faces))
(add-to-list 'window-system-initialization-alist '(ns . ns-initialize-window-system))
+(declare-function ns-toggle-fullscreen-internal "nsfns.m" ())
+(defun ns-toggle-fullscreen ()
diff --git a/lib/unistd.in.h b/lib/unistd.in.h
index 77e5675..759080a 100644
--- a/lib/unistd.in.h
+++ b/lib/unistd.in.h
@@ -382,17 +382,12 @@ _GL_WARN_ON_USE (dup3, "dup3 is unportable - "
# if !@HAVE_DECL_ENVIRON@
/* Set of environment variables and values. An array of strings of the form
"VARIABLE=VALUE", terminated with a NULL. */
-# if defined __APPLE__ && defined __MACH__
-# include <crt_externs.h>
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
def build_argparser():
parser = argparse.ArgumentParser()
parser.add_argument('--foo', action='store_true', help='foo help')
#!/bin/bash
#
# Reference : http://www.transtats.bts.gov/DL_SelectFields.asp?Table_ID=236&DB_Short_Name=On-Time
#
now=`date +"%Y-%m-%d" -d "01/01/1987"`
end=`date +"%Y-%m-%d" -d "05/01/2015"`
# end=`date +"%Y-%m-%d"`
#!/usr/bin/env python
# Reference:
# [1] http://matplotlib.org/examples/pylab_examples/multipage_pdf.html
# This should be executed before other matplotlib imports
import matplotlib
matplotlib.use('Agg')
import datetime
@leoncamel
leoncamel / gist:dfc0492777bc2db97739
Created July 14, 2014 11:09
Docker build by docker-py
import docker
c = docker.Client(base_url="http://localhost:port", version="1.11")
print(c.version())
for i in c.build(fileobj=open("file.tar"), stream=True, custom_context=True):
print(i)