From 9931e0888b2419326ae10ebbfae532261c5c125f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20Ko=C4=8D=C3=AD?= Date: Thu, 30 Jun 2016 16:11:56 +0200 Subject: Fix submodules --- vim/bundle/vim-snippets | 1 + vim/bundle/vim-snippets/UltiSnips/cpp.snippets | 73 -------------------------- 2 files changed, 1 insertion(+), 73 deletions(-) create mode 160000 vim/bundle/vim-snippets delete mode 100644 vim/bundle/vim-snippets/UltiSnips/cpp.snippets (limited to 'vim/bundle/vim-snippets/UltiSnips/cpp.snippets') diff --git a/vim/bundle/vim-snippets b/vim/bundle/vim-snippets new file mode 160000 index 0000000..15d7e5e --- /dev/null +++ b/vim/bundle/vim-snippets @@ -0,0 +1 @@ +Subproject commit 15d7e5ec26ec93adee4051b6359be90a943aa38d diff --git a/vim/bundle/vim-snippets/UltiSnips/cpp.snippets b/vim/bundle/vim-snippets/UltiSnips/cpp.snippets deleted file mode 100644 index f7c2bd8..0000000 --- a/vim/bundle/vim-snippets/UltiSnips/cpp.snippets +++ /dev/null @@ -1,73 +0,0 @@ -priority -50 - -extends c - -# We want to overwrite everything in parent ft. -priority -49 - -########################################################################### -# TextMate Snippets # -########################################################################### -snippet beginend "$1.begin(), $1.end() (beginend)" -${1:v}${1/^.*?(-)?(>)?$/(?2::(?1:>:.))/}begin(), $1${1/^.*?(-)?(>)?$/(?2::(?1:>:.))/}end() -endsnippet - -snippet cl "class .. (class)" -class ${1:`!p snip.rv = snip.basename or "name"`} -{ -public: - ${1/(\w+).*/$1/} (${2:arguments}); - virtual ~${1/(\w+).*/$1/} (); - -private: - ${0:/* data */} -}; -endsnippet - -snippet ns "namespace .. (namespace)" -namespace${1/.+/ /m}${1:`!p snip.rv = snip.basename or "name"`} -{ - ${VISUAL}${0} -}${1/.+/ \/* /m}$1${1/.+/ *\/ /m} -endsnippet - -snippet readfile "read file (readF)" -std::vector v; -if (FILE *fp = fopen(${1:"filename"}, "r")) -{ - char buf[1024]; - while(size_t len = fread(buf, 1, sizeof(buf), fp)) - v.insert(v.end(), buf, buf + len); - fclose(fp); -} -endsnippet - -snippet map "std::map (map)" -std::map<${1:key}, ${2:value}> map$0; -endsnippet - -snippet vector "std::vector (v)" -std::vector<${1:char}> v$0; -endsnippet - -snippet tp "template (template)" -template -endsnippet - -snippet cla "An entire .h generator" b -#ifndef ${2:`!v substitute(vim_snippets#Filename('$1_H','ClassName'),'.*','\U&\E','')`} -#define $2 - -class ${1:`!v substitute(substitute(vim_snippets#Filename('$1','ClassName'),'^.','\u&',''), '_\(\w\)', '\u\1', 'g')`} -{ -private: - ${3} - -public: - $1(); - virtual ~$1(); -}; - -#endif /* $2 */ -endsnippet -# vim:ft=snippets: -- cgit v1.2.3