This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zk@qi ~/.vim ‹2d master 5a4a480753› | |
› cloc . | |
5927 text files. | |
5550 unique files. | |
13970 files ignored. | |
http://cloc.sourceforge.net v 1.56 T=20.0 s (43.2 files/s, 8243.4 lines/s) | |
------------------------------------------------------------------------------- | |
Language files blank comment code | |
------------------------------------------------------------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
async = require 'async' | |
async.waterfall [ | |
(cb) -> | |
cb null, 1 | |
(one, cb) -> | |
cb null, one, 2 | |
(one, two, cb) -> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'), | |
uglify = require('uglify-js2'), | |
code = fs.readFileSync('./orig.js', 'utf8'); | |
var ast = uglify.parse(code); | |
// List all functions | |
var functions = []; | |
var walker = new uglify.TreeWalker(function(node){ | |
if (node instanceof uglify.AST_Defun) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function foo(x) { | |
return x; | |
} | |
function bar() { | |
return foo.call(this, 42); | |
} | |
var calls = []; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from inspect import isclass | |
from tastypie.resources import ModelResource | |
from django.conf import settings | |
from itertools import chain | |
def generate_urls(): | |
for app in settings.INSTALLED_APPS: | |
if not app.startswith('django'): | |
try: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class TidyHtml5 < Formula | |
head 'git://github.com/w3c/tidy-html5.git' | |
homepage 'http://w3c.github.com/tidy-html5/' | |
def install | |
system "make", | |
"-Cbuild/gmake", | |
"-j1", # make fails with this Makefile when jobs > 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = | |
staticPath: './public' | |
bundles: | |
'/app.css': | |
main: './assets/css/app.styl' | |
'/app.js': | |
main: './assets/js/app.coffee' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
servers = ( | |
{ | |
address = "innerirc.net"; | |
chatnet = "innerirc"; | |
port = "6697"; | |
use_ssl = "yes"; | |
ssl_verify = "no"; | |
autoconnect = "no"; | |
}, | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#user http; | |
worker_processes 4; | |
#worker_cpu_affinity 0100 1000; | |
#error_log logs/error.log; | |
#error_log logs/error.log notice; | |
#error_log logs/error.log info; | |
#pid logs/nginx.pid; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let g:disable_arrow_keys = 1 | |
so ~/.vim/vimrc | |
nnoremap ; : | |
vnoremap ; : | |
nnoremap J <c-d> | |
nnoremap K <c-u> | |
vnoremap J <c-d> |