Skip to content

Instantly share code, notes, and snippets.

View soomtong's full-sized avatar
😇

YoungTaek soomtong

😇
View GitHub Profile
@soomtong
soomtong / tabindex
Created October 29, 2013 06:36
tab index
<body>
<h1>탭 테스트</h1>
<input type="button" name="1" value="1" tabindex="1">
<input type="button" name="2" value="2" tabindex="2">
<input type="button" name="3" value="3" tabindex="3">
<button tabindex="-1">이건 열외</button>
</body>
@soomtong
soomtong / textarea.html
Created December 19, 2013 02:57
가장 단순하고 간결한 textarea 자동 조절 예제
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-latest.js"></script>
<meta charset=utf-8 />
<title>Auto Resize Textarea</title>
<style>
.wrap {
width: 500px;
}
@soomtong
soomtong / compact-me.js
Created January 6, 2014 08:54
Convert this code to more efficiency pattern
var idx = 0;
function ToggleStatus(count) {
idx++;
if (idx < count) {
var toggleTimer = $timeout(function () {
$scope.heroStatType = !$scope.heroStatType;
ToggleStatus(count);
}, 1500 * idx + 1000);
}
}
" Make Vim more useful
set nocompatible
" Use the OS clipboard by default (on versions compiled with `+clipboard`)
" Set color scheme!
colorscheme koehler
set clipboard=unnamed
" Enhance command-line completion
set wildmenu
" Allow cursor keys in insert mode
set esckeys
@soomtong
soomtong / mdb
Created August 28, 2014 07:40
mongo db manage script use /usr/local/bin/mdb with excution flag
#!/bin/bash
if [ -z $1 ] ; then
echo "Usage: $0 [start|stop|restart] "
exit 1
fi
# Source the common setup functions for startup scripts
test -r /etc/rc.common || exit 1
. /etc/rc.common
@soomtong
soomtong / cdb
Created August 28, 2014 07:40
couch db manage script use /usr/local/bin/cdb with excution flag
#!/bin/bash
if [ -z $1 ] ; then
echo "Usage: $0 [start|stop|restart] "
exit 1
fi
# Source the common setup functions for startup scripts
test -r /etc/rc.common || exit 1
. /etc/rc.common
@soomtong
soomtong / init_osx_env.sh
Created November 7, 2014 16:56
OSX defaults setting
# 키보드 오래 누르고 있을 때
defaults write -g ApplePressAndHoldEnabled -bool false
# 아이튠즈 한글 환경 강제
defaults write -app iTunes AppleLanguages "(ko)"
@soomtong
soomtong / rdb
Created November 18, 2014 13:21
redis db manage script
#!/bin/bash
## Please update your redis.conf demonize mode to yes `daemonize yes`
if [ -z $1 ] ; then
echo "Usage: $0 [start|stop|restart] "
exit 1
fi
# Source the common setup functions for startup scripts
@soomtong
soomtong / find-large-files.sh
Created January 8, 2015 21:00
find large files bash script
#!/bin/bash
find / -size +102400k -print|xargs ls -hl
@soomtong
soomtong / set-go-path-and-restart.sh
Last active August 29, 2015 14:17
set GO PATH this directory and restart App by daemon
#!/usr/bin/env bash
export GOPATH=$(pwd)
kill $(pgrep revel)
daemon bin/revel run pebbler prod