add custom functions and some snippets