Skip to content

Instantly share code, notes, and snippets.

@daejinseok
daejinseok / ReadLine.py
Last active December 19, 2015 19:29
라인단위로 파일 읽기
# Iterate over the lines of the file
# with절에서 나올 때, 파일은 자동으로 close된다.
# 출처 : python cookbook 5.1 Reading and Writing Text Data
with open('somefile.txt', 'rt') as f:
for line in f:
# process line
...
@daejinseok
daejinseok / a.js
Last active October 2, 2015 07:41
"ignored_packages":
[
// "Vintage" 이 줄을 삭제하거나, 주석 처리하면 활성화됩니다.
],
@daejinseok
daejinseok / Preferences.sublime-settings
Created October 2, 2015 07:45
Sublime Text에서 Vintage 활성화
"ignored_packages":
[
// "Vintage" 이 줄을 삭제하거나, 주석 처리하면 활성화됩니다.
],
@daejinseok
daejinseok / Default.sublime-keymap
Last active October 2, 2015 07:54
sublime text에서 command_moe 키 변경
{ "keys" : ["j", "j"],
"command" : "exit_insert_mode",
"context" : [
{ "key" : "setting.command_mode", "operand" : false },
{ "key" : "setting.is_widget", "operand" : false }
]
}
@daejinseok
daejinseok / Default.sublime-keymap
Created October 2, 2015 07:49
sublime text에서 command palette 키 설정
{ "keys": ["z", "z"],
"command": "show_overlay",
"args": {"overlay": "command_palette"}
}
@daejinseok
daejinseok / makeBind.js
Last active October 6, 2015 07:19
dynamic scoping 예제
function makeBindFun(resolver){
return function(k, v){
var stack = globals[k] || [];
globals[k] = resolver(stack, v);
return globals;
}
}
var stackBinder = makeBindFun(function(stack, v){
stack.push(v);
@daejinseok
daejinseok / EgovUserManageController.java
Created November 16, 2015 15:47
EgovUserManageController.java 서버단 이메일 오류시 포워딩 되었을 때 콤보값이 나오도록 수정
@RequestMapping("/uss/umt/EgovUserInsert.do")
public String insertUser(@ModelAttribute("userManageVO") UserManageVO userManageVO, BindingResult bindingResult, Model model) throws Exception {
// 미인증 사용자에 대한 보안처리
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
if (!isAuthenticated) {
return "index";
}
beanValidator.validate(userManageVO, bindingResult);
:e $userprofile\_gvimrc
@daejinseok
daejinseok / _vimrc
Last active December 14, 2018 11:05
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
" 추가하고 싶은 플러그인을 아래에 나열하면 됩니다.