diff --git a/.config/nvim/templates/c.template b/.config/nvim/templates/c.template new file mode 100644 index 0000000..20afee4 --- /dev/null +++ b/.config/nvim/templates/c.template @@ -0,0 +1,10 @@ +/** + * @author : {{NAME}} ({{EMAIL}}) + * @file : {{FILE}} + * @license : {{LICENSE}} + * @created : {{TIMESTAMP}} + */ + +#include "{{FILE}}.h" + +{{CURSORS}} diff --git a/.config/nvim/templates/cpp.template b/.config/nvim/templates/cpp.template new file mode 100644 index 0000000..c690da2 --- /dev/null +++ b/.config/nvim/templates/cpp.template @@ -0,0 +1,17 @@ +/** + * @author : {{NAME}} ({{EMAIL}}) + * @file : {{FILE}} + * @license : {{LICENSE}} + * @created : {{TIMESTAMP}} + */ + +#include "{{FILE}}.hpp" + +{{CAMEL_CLASS}}::{{CAMEL_CLASS}}() +{ + {{CURSOR}} +} + +{{CAMEL_CLASS}}::~{{CAMEL_CLASS}}() +{ +} diff --git a/.config/nvim/templates/h.template b/.config/nvim/templates/h.template new file mode 100644 index 0000000..65b5ef3 --- /dev/null +++ b/.config/nvim/templates/h.template @@ -0,0 +1,15 @@ +/** + * @author : {{NAME}} ({{EMAIL}}) + * @file : {{FILE}} + * @license : {{LICENSE}} + * @created : {{TIMESTAMP}} + */ + +#ifndef {{MACRO_GUARD}} + +#define {{MACRO_GUARD}} + +{{CURSOR}} + + +#endif /* end of include guard {{MACRO_GUARD}} */ diff --git a/.config/nvim/templates/hpp.template b/.config/nvim/templates/hpp.template new file mode 100644 index 0000000..8c33cc4 --- /dev/null +++ b/.config/nvim/templates/hpp.template @@ -0,0 +1,22 @@ +/** + * @author : {{NAME}} ({{EMAIL}}) + * @file : {{FILE}} + * @license : {{LICENSE}} + * @created : {{TIMESTAMP}} + */ + +#ifndef {{MACRO_GUARD}} + +#define {{MACRO_GUARD}} + + +class {{CAMEL_CLASS}} +{ + public: + {{CAMEL_CLASS}}({{CURSOR}}); + virtual ~{{CAMEL_CLASS}}(); + private: + /* private data */ +}; + +#endif /* end of include guard {{MACRO_GUARD}} */ diff --git a/.config/nvim/templates/main.c.template b/.config/nvim/templates/main.c.template new file mode 100644 index 0000000..b1f8bc2 --- /dev/null +++ b/.config/nvim/templates/main.c.template @@ -0,0 +1,14 @@ +/** + * @author : {{NAME}} ({{EMAIL}}) + * @file : {{FILE}} + * @license : {{LICENSE}} + * @created : {{TIMESTAMP}} + */ + +#include + +int main() +{ + {{CURSOR}} + return 0; +} diff --git a/.config/nvim/templates/main.cpp.template b/.config/nvim/templates/main.cpp.template new file mode 100644 index 0000000..c0e5b19 --- /dev/null +++ b/.config/nvim/templates/main.cpp.template @@ -0,0 +1,14 @@ +/** + * @author : {{NAME}} ({{EMAIL}}) + * @file : {{FILE}} + * @license : {{LICENSE}} + * @created : {{TIMESTAMP}} + */ + +#include + +int main() +{ + {{CURSOR}} + return 0; +} diff --git a/.config/nvim/templates/makefile.template b/.config/nvim/templates/makefile.template new file mode 100644 index 0000000..ec2526d --- /dev/null +++ b/.config/nvim/templates/makefile.template @@ -0,0 +1,28 @@ +###################################################################### +# @author : {{NAME}} ({{EMAIL}}) +# @file : {{FILE}} +# @license : {{LICENSE}} +# @created : {{TIMESTAMP}} +###################################################################### + +IDIR =./include +CC=gcc +CFLAGS=-I$(IDIR) + +ODIR=obj + +LIBS= + +_OBJ = main.o {{CURSOR}} +OBJ = $(patsubst %,$(ODIR)/%,$(_OBJ)) + +$(ODIR)/%.o: %.c + $(CC) -c -o $@ $< $(CFLAGS) + +main: $(OBJ) + $(CC) -o $@ $^ $(CFLAGS) $(LIBS) + +.PHONY: clean + +clean: + rm -f $(ODIR)/*.o diff --git a/.config/nvim/templates/py.template b/.config/nvim/templates/py.template new file mode 100644 index 0000000..7b3169d --- /dev/null +++ b/.config/nvim/templates/py.template @@ -0,0 +1,11 @@ +#! /usr/bin/env python +# +# @author : {{NAME}} ({{EMAIL}}) +# @file : {{FILE}} +# @license : {{LICENSE}} +# @created : {{TIMESTAMP}} +# + +""" +{{CURSOR}} +""" diff --git a/.config/nvim/templates/sh.template b/.config/nvim/templates/sh.template new file mode 100644 index 0000000..da95779 --- /dev/null +++ b/.config/nvim/templates/sh.template @@ -0,0 +1,12 @@ +#!/usr/bin/env sh + +###################################################################### +# @author : {{NAME}} ({{EMAIL}}) +# @file : {{FILE}} +# @license : {{LICENSE}} +# @created : {{TIMESTAMP}} +# +# @description : {{CURSOR}} +###################################################################### + + diff --git a/.config/nvim/templates/vim.template b/.config/nvim/templates/vim.template new file mode 100644 index 0000000..a375158 --- /dev/null +++ b/.config/nvim/templates/vim.template @@ -0,0 +1,4 @@ +" Author : {{NAME}} +" Created : {{TODAY}} +" License : {{LICENSE}} +" Description : {{CURSOR}}