https://github.com/chlab/pycharm-django-live-templates
Django Live Templates (snippets) for PyCharm
https://github.com/chlab/pycharm-django-live-templates
django-templates ide pycharm pycharm-plugin python snippets
Last synced: 8 months ago
JSON representation
Django Live Templates (snippets) for PyCharm
- Host: GitHub
- URL: https://github.com/chlab/pycharm-django-live-templates
- Owner: chlab
- License: mit
- Created: 2016-05-31T09:12:42.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2020-12-17T05:02:35.000Z (over 5 years ago)
- Last Synced: 2025-10-29T01:46:29.013Z (8 months ago)
- Topics: django-templates, ide, pycharm, pycharm-plugin, python, snippets
- Language: Makefile
- Size: 247 KB
- Stars: 10
- Watchers: 0
- Forks: 10
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Django template snippets for PyCharm
PyCharm supports auto-expanding certain keywords in Django templates to the corresponding Django template tag. PyCharm calls these live templates, other programs call them snippets. By default, only a handful of template tags are supported. This repo reflects my efforts of creating the remaining ones as I need them.
## How to use
Download `Django.xml` from this repo and put it in the templates directory of your [preferences directory](https://www.jetbrains.com/help/pycharm/2016.1/directories-used-by-pycharm-to-store-settings-caches-plugins-and-logs.html), e.g. on OS X `~/Library/Preferences//templates/Django.xml`.
Use them in django templates like so:

## Contribute
Missing [tags](https://docs.djangoproject.com/en/1.9/ref/templates/builtins/)?
Define them in PyCharm *Settings > Editor > Live Templates > Django*. Look at the other tags to see how to define them.
Please send a pull request and I'll be happy to merge it!