Skip to content

Instantly share code, notes, and snippets.

View cgbahk's full-sized avatar
⛏️
time killing

Cheongyo Bahk cgbahk

⛏️
time killing
View GitHub Profile
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active November 1, 2024 17:40
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@kshenoy
kshenoy / FoldText.vim
Last active April 21, 2019 06:03
Function to set the foldtext
function! FoldText()
" Description: Folding configuration
let nucolwidth = &fdc + &number*&numberwidth
let winwidth = winwidth(0) - nucolwidth - 3
let foldlinecount = foldclosedend(v:foldstart) - foldclosed(v:foldstart) + 1
let dashtext = strpart(string(v:folddashes),1,len(string(v:folddashes))-2)
let foldinfo = "+" . dashtext . " Fold: " . string(v:foldlevel) . ", " . string(foldlinecount) . " lines "
let firstline = strpart(getline(v:foldstart), 0 , winwidth - len(foldinfo))
let fillcharcount = winwidth - len(firstline) - len(foldinfo)
return firstline . repeat(" ",fillcharcount) . foldinfo
@joyrexus
joyrexus / README.md
Last active August 6, 2024 16:07
collapsible markdown

collapsible markdown?

CLICK ME

yes, even hidden code blocks!

print("hello world!")
@MartyLake
MartyLake / .vimrc
Last active March 22, 2019 17:35
bootstrap script to generate compile_commands.json and clang complete on project that uses cmake and vim
" only use linters that uses compile_commands.json
let g:ale_linters.cpp = ['clangcheck', 'clangtidy', 'cppcheck']
" various options for clang_complete
set concealcursor=inv
let g:clang_snippets = 1
set completeopt=menu,longest
let g:clang_complete_optional_args_in_snippets = 1
let g:clang_trailing_placeholder = 1