From c3ae804a82912e318f6c20281bd9b68c84a6bf63 Mon Sep 17 00:00:00 2001 From: Oliver Andrich Date: Sun, 27 Jan 2013 20:13:33 +0100 Subject: [PATCH 1/2] A more complete property snippet for python. This snippet is inspired by the snippet provided by Sublime Text. The current snippet in the upstream repository is missing at least two lines: return locals() $1 = property(**$1()) --- snippets/python.snippets | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/snippets/python.snippets b/snippets/python.snippets index dd2e812..508a51b 100644 --- a/snippets/python.snippets +++ b/snippets/python.snippets @@ -51,6 +51,10 @@ snippet property ${3:return self._$1} def fset(self, value): ${4:self._$1 = value} + def fdel(self): + ${5:del self._$1} + return locals() + $1 = property(**$1()) # Ifs snippet if if ${1:condition}: From 2773a13c332035b2612616389c195c095e645243 Mon Sep 17 00:00:00 2001 From: Oliver Andrich Date: Sun, 27 Jan 2013 20:55:13 +0100 Subject: [PATCH 2/2] Added elif snippet to htmldjango. --- snippets/htmldjango.snippets | 3 +++ 1 file changed, 3 insertions(+) diff --git a/snippets/htmldjango.snippets b/snippets/htmldjango.snippets index 38f836b..c19e877 100644 --- a/snippets/htmldjango.snippets +++ b/snippets/htmldjango.snippets @@ -50,6 +50,9 @@ snippet if snippet else {% else %} ${1} +snippet elif + {% elif ${1} %} + ${2} snippet ifchanged {% ifchanged %}${1}{% endifchanged %} snippet ifequal