As configured in my dotfiles.
start new:
tmux
start new with session name:
CREATE TABLE `htsg_operations_log` ( | |
`id` bigint(20) unsigned NOT NULL, | |
`namespace` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL, | |
`name` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL, | |
`operation` varchar(16) COLLATE utf8mb4_unicode_ci NOT NULL, | |
`txnid` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL, | |
`status` longtext COLLATE utf8mb4_unicode_ci NOT NULL, | |
`create_date` bigint(20) unsigned NOT NULL, | |
`update_date` bigint(20) unsigned NOT NULL, | |
PRIMARY KEY (`id`), |
As configured in my dotfiles.
start new:
tmux
start new with session name:
// array utils | |
// ================================================================================================= | |
const combine = (...arrays) => [].concat(...arrays); | |
const compact = arr => arr.filter(Boolean); | |
const contains = (() => Array.prototype.includes | |
? (arr, value) => arr.includes(value) | |
: (arr, value) => arr.some(el => el === value) |
geraruro |
var rotate90 = function (orig) { | |
var rotated = []; | |
for (var colIdx = 0; colIdx < orig[0].length; colIdx++) { | |
var reverseCol = [], | |
col; | |
for (var rowIdx = 0; rowIdx < orig.length; rowIdx++) { | |
reverseCol.push(orig[rowIdx][colIdx]); | |
} | |
col = reverseCol.reverse(); | |
rotated.push(col); |
This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.
The script is here:
#!/bin/bash
convert $1 -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 $2
Array.prototype.slice.call(document.querySelectorAll("a")).map(function(a){return a.href.split('=')[1].length}).sort().reverse(); |
# download latest libevent2 and tmux sources, and extract them somewhere | |
# (thx bluejedi for tip on latest tmux URL) | |
# | |
# at the time of writing: | |
# https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz | |
# http://sourceforge.net/projects/tmux/files/latest/download?source=files | |
# | |
# install deps | |
yum install gcc kernel-devel make ncurses-devel |