Playing with TextMate is fun, but I can't find any bundle that can make running a single-file unit test or functional test easily.
So I want to custom a command:
| user system total real | |
| rsec result: 32918.38 | |
| 0.109000 0.000000 0.109000 ( 0.107006) | |
| rsec rpn: 32918.38 | |
| 0.140000 0.000000 0.140000 ( 0.154009) | |
| treetop result: 32918.38 | |
| 1.638000 0.000000 1.638000 ( 1.638094) |
Playing with TextMate is fun, but I can't find any bundle that can make running a single-file unit test or functional test easily.
So I want to custom a command:
| # mac port installs bash_completion in /opt/local | |
| if [ -f /opt/local/etc/bash_completion ]; then | |
| . /opt/local/etc/bash_completion | |
| # * | |
| export GIT_PS1_SHOWDIRTYSTATE=1 | |
| # $ | |
| export GIT_PS1_SHOWSTASHSTATE=1 | |
| # % | |
| # export GIT_PS1_SHOWUNTRACKEDFILES=1 | |
| export PS1='\[\e[32m\]λ \w\[\e[36m\]$(__git_ps1 " (%s)") [$(~/.rvm/bin/rvm-prompt i v)]\[\e[0m\]\n\[\e[32m\]→\[\e[0m\] ' |
| require "eventmachine" | |
| module SSLHandler | |
| # an SSLHandler is created for every request | |
| def initialize | |
| @state = :head | |
| end | |
| def receive_data data | |
| case @state |
| require "mongo" | |
| class Pager | |
| db = Mongo::Connection.new.db 'pager' | |
| DOCS = db.collection 'docs' | |
| INDEX = db.collection 'index' | |
| STATE = db.collection 'state' | |
| THRESHOLD = 1000 | |
| STATE_LOCK = Mutex.new |
| alias base64="openssl base64" | |
| alias aes="openssl aes-256-cbc" |
| javascript: | |
| prj='/Users/z/prj_name'; | |
| gem='/Users/z/.rvm/gems/ree-1.8.7-2011.03'; | |
| ps=document.getElementById('backtrace').getElementsByTagName('p'); | |
| for(i=0;i<ps.length;i++){ | |
| h=ps[i].innerHTML; | |
| if(h.match(/^\s*<a[^>]+>/)){ | |
| h=h.replace(/^\s*<a[^>]+>/, '').replace(/<\/a>$/, ''); | |
| prefix=prj; |
| javascript:(function(){ | |
| var R = /\[;.+?;\]|\\\[.+?\\\]|\$\$.+?\$\$|\$.+?\$|./g; | |
| /* var R = /\[;.+?;\]|\\\[.+?\\\]|\$\$.+?\$\$|./g; */ | |
| var spanClick = function(){ | |
| this.nextElementSibling.style.display = 'inline'; | |
| this.style.display = 'none' | |
| }; | |
| var imgClick = function() { |
| #pragma once | |
| #include <stdlib.h> | |
| #include <stdint.h> | |
| #include <stack> | |
| #include "obj.hpp" | |
| using namespace std; | |
| class GC { | |
| Obj head; |
| // ==UserScript== | |
| // @match https://www.google.com/* | |
| // ==/UserScript== | |
| interval = 400 | |
| clean = function(){ | |
| console.log('cleaning') | |
| var links = document.querySelectorAll('#search h3 a') | |
| var i | |
| for(i=0; i<links.length; i++){ |