This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class InvalidateCurrencyUnitError < RuntimeError; end; | |
module CurrencyUnit | |
USD = 1 | |
EURO = 2 | |
YEN = 3 | |
def validate_currency_unit(currency_unit) | |
if currency_unit == USD; return true; end; | |
if currency_unit == EURO; return true; end; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
command! -range=% | |
\ OverCommandLine | |
\ call over#command_line( | |
\ g:over_command_line_prompt, | |
\ ( <line1> == 1 && <line2> == line('$') | |
\ ? '%' | |
\ : <line1> != <line2> | |
\ ? printf("%d,%d", <line1>, <line2>) | |
\ : '.' | |
\ ) . 's/\v' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let s:is_loaded_flg = 's:' . substitute(expand('<sfile>:p'), '\W', '_', 'g') | |
if exists(s:is_loaded_flg) | |
finish | |
else | |
execute 'let ' . s:is_loaded_flg . ' = 1' | |
endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
command! FullToHalf call s:full_to_half.substitute() | |
let s:full_to_half = {} | |
let s:full_to_half.table = { | |
\ ' ' : ' ' | |
\ , '(' : '(' | |
\ , ')' : ')' | |
\ , ':' : ':' | |
\ , '0' : '0' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function! Init_lightline() | |
call lightline#init() | |
call lightline#colorscheme() | |
call lightline#update() | |
endfunction | |
augroup Init_lightLine.vim | |
autocmd! | |
autocmd BufWritePost * call Init_lightline() | |
augroup end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
scriptencoding=utf-8 | |
function! objects#font#New() | |
let font = {} | |
let font.name = '' | |
let font.encoding = 'DEFAULT' | |
let font.iconv_to = 'utf-8' | |
let font.size = 12 | |
let font.options = '' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
command! -nargs=1 -bar -complete=customlist,Favorite_Color FavoriteColor call Set_Favorite_Color(<q-args>) | |
" colorschemeとそれに関連するGui情報を格納したobject | |
function! s:color_dict_object(colorscheme, transparency, ...) | |
let l:color_dict = {} | |
let l:color_dict.colorscheme = a:colorscheme | |
let l:color_dict.background = get(a:, '1', '') | |
let l:color_dict.transparency = a:transparency | |
return l:color_dict | |
endfunction |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun calc_bmi (height weight) | |
(float | |
(flet ( | |
(twice (number) | |
(* number number)) | |
(divid-100(number) | |
(/ number 100)) | |
) | |
(/ | |
weight |
NewerOlder