dotfiles/vim/plugins/ultisnips/pythonx/UltiSnips/snippet/source/added.py
2018-04-05 13:06:54 +02:00

16 lines
385 B
Python

#!/usr/bin/env python
# encoding: utf-8
"""Handles manually added snippets UltiSnips_Manager.add_snippet()."""
from UltiSnips.snippet.source._base import SnippetSource
class AddedSnippetsSource(SnippetSource):
"""See module docstring."""
def add_snippet(self, ft, snippet):
"""Adds the given 'snippet' for 'ft'."""
self._snippets[ft].add_snippet(snippet)