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! Comment() | |
| silent s/^/\=escape(b:comment_leader,'\/') | |
| nohlsearch | |
| 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
| function! Freqs2(list) | |
| let freqs = {} | |
| call map(copy(a:list), 'extend(freqs, { v:val : 0 })') | |
| " for line in getline(1, '$') | |
| " call map(freqs, 'v:val + ( line =~ ''\<'' . v:key . ''\>'' )') | |
| " endfor | |
| call map(getline(1, '$'), 'map(freqs, "v:val + (''" . v:val . "'' =~ ''\\<'' . v:key . ''\\>'' )")') | |
| return freqs | |
| 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
| usage(){ | |
| printf '%s\n\n' \ | |
| "Usage: `basename $0` [env] [logger] [level]" \ | |
| "[env] : ${envList[@]}" \ | |
| "[logger] : ${loggerList[@]}" \ | |
| "[level] : ${levelList[@]}" | |
| return | |
| } |
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
| partial='confirm/sample_request_' | |
| # Put all matches into array | |
| files=("$partial"*.json) | |
| # Strip the leading stuff | |
| tmp=("${files[@]#$partial}") | |
| # Strip the trailing stuff | |
| keys=("${tmp[@]%.json}") |
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! s:set_cursor() abort | |
| let s:oldline = exists('s:newline') ? s:newline : 5 | |
| let s:newline = line('.') | |
| let headoff = s:headoff + 2 + s:secoff | |
| " going BOTH WAYS !!!! | |
| let direction = 2 * (s:newline > s:oldline) - 1 | |
| while index(s:section_header_lines, s:newline) != -1 | |
| let s:newline += direction | |
| endwhile |
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=( /sbin/iptables -A allowed-connection -i wlan0 -m limit -j LOG --log-prefix "Bad packet from wlan0:" ) | |
| "${command[@]}" |
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
| Large Object Motions: | |
| ( ) { } | |
| [[ [] ][ ]] | |
| [m [M ]m ]M | |
| [( ]) [{ ]} | |
| Word Motions: | |
| w W e E | |
| b B ge gE |
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
| use Term::ANSIColor qw(:constants); | |
| use 5.010; | |
| while (<STDIN>) { | |
| my @words = split(' '); | |
| foreach (@words) { | |
| s/^chr/kr/; | |
| s/c/k/g; | |
| s/ti/sj/; |
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
| if neocomplcache#sources#snippets_complete#jumpable() | |
| imap <expr><C-j> "\<Plug>(neocomplcache_snippets_jump)" | |
| imap <expr><C-k> "\<Plug>(neocomplcache_snippets_jump)" | |
| endif |