Skip to content

Instantly share code, notes, and snippets.

View chakrit's full-sized avatar

Chakrit Wichian chakrit

View GitHub Profile
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Sider;
namespace DummyConsole
{
class Program
VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Apr 24 2013 16:20:12)
MacOS X (unix) version
Included patches: 1-905
Compiled by [email protected]
Huge version without GUI. Features included (+) or not (-):
+arabic +file_in_path +mouse_sgr +tag_binary
+autocmd +find_in_path -mouse_sysmouse +tag_old_static
-balloon_eval +float +mouse_urxvt -tag_any_white
-browse +folding +mouse_xterm -tcl
++builtin_terms -footer +multi_byte +terminfo
initial before.
․initial after.
second before.
․calling second after.
parse = (line) ->
stuff = line.split ' '
result = []
while stuff.length
item = stuff.shift()
if item[0] is '"' # begin quoted string
while item[item.length - 1] isnt '"' or (item[item.length - 2] is '\\' and item[item.length - 3] isnt '\\')
@chakrit
chakrit / test.js
Created April 6, 2013 09:01
Testing `end` event for response.
var http = require('http');
http.createServer(function(req, resp) {
console.log('incoming request');
resp.once('end', function() {
throw new Error('response is done');
});
setTimeout(function() {
resp.end('hi!');
VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Mar 17 2013 10:52:15)
MacOS X (unix) version
Included patches: 1-865
Compiled by [email protected]
Huge version without GUI. Features included (+) or not (-):
+arabic +file_in_path +mouse_sgr +tag_binary
+autocmd +find_in_path -mouse_sysmouse +tag_old_static
-balloon_eval +float +mouse_urxvt -tag_any_white
-browse +folding +mouse_xterm -tcl
++builtin_terms -footer +multi_byte +terminfo
// Generated by CoffeeScript 1.5.0
(function() {
var Base, outsideMethod,
__bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
outsideMethod = function(func) {
return func.call({
message: 'wrong!'
});
};

ไกลแค่ไหน คือ ใกล้ - Getsunova

Verse I

พยายามจะทำวิธีต่างๆ ให้เธอนั้นรักฉัน พยายามทุกวันมอบให้ทุกอย่างที่เธอต้องการ
เหมือนเดินบนสะพานที่มีปลายทางคือใจของเธอ ยังคงคิดและหวัง จะนำเอารักแท้นี้ไปให้

chorus I

(แต่)(ว่า)ทำไม เดินมาเนิ่นนานไม่ถึงซักที แต่ทำไม มองดูเส้นทางเหมือนยาวออกไป

TMUX - Single window group, multiple session.

So I have been using tmux for a while and have grown to like it and have since added many many customizations to it. Now once you start getting the hang of it, you'll naturally want to do more with the tool.

Now tmux has a concept of window-group and session and if you are like me you'll want multiple session that connects to the same window group instead of a new window group every time. Basically I just need different views into the same set of windows that I have already created, I don't want to create a new set of windows every time I fire up my terminal.

This is the default case if you simply use the tmux command as your login shell, effectively creating a new group of windows every time you start tmux.

This is less than ideal because, if you are like me, you fire up one-off terminals all the time and you don't want all those one-off jobs to stay running in the background. Plus sometimes you need information fro

initial before
․calling after
second before
calling second after
✖ 1 of 2 tests failed:
1) Initial test test will fail will fail: