Chris Conlan

Data Scientist

  • About
  • Blog
    • Business Management
    • Programming with Python
    • Programming with R
    • Automated Trading
    • 3D Technology and Virtual Reality
  • Books
    • Fast Python
    • Algorithmic Trading with Python
    • The Blender Python API
    • Automated Trading with R
  • Snippets
  • Opportunities

Introducing Django-Highlite: A Lightweight Highlighting Plugin for Sublime Text 3

June 25, 2018 By Chris Conlan Leave a Comment

I have been programming Django in Sublime Text 3 for a while, and I always thought the oft-recommended Djaneiro package was way too heavy-handed.

Here are my criteria for a Django plugin for Sublime Text 3:

  • I didn’t want bulky version-dependent snippets. Hitting Ctrl+Shift+p with Djaneiro gives you the option to insert around 100 snippets. Most of them are too short, too version-dependent, or just exotic and unneeded.

  • I didn’t want an Sublime Text 3 view dedicated to “Python (Django)”. I’d prefer to treat Python code as pure Python code, even when working in Django.

  • I wanted Django-flavored syntax highlighting in Django HTML templates. This is the “HTML (Django)” Sublime Text 3 view.

  • I wanted the Ctrl+/ comment shortcut to work on Django HTML templates. Djaneiro has a 6-year old bug where the wrong comment tag is inserted.

So, I cloned the Djaneiro plugin and deleted a bunch of the extras I didn’t want. I present to you: django-highlite.

To install, navigate to your Sublime Text 3 package directory (Preferences -> Browse Packages…), and clone the repository into it. Restart Sublime Text 3, or simply re-open your “Django (HTML)” views, and you are all set.

Filed Under: Snippets

Leave a Reply Cancel reply

Fast Python: Master the Basics to Write Faster Code

Fast Python: Master the Basics to Write Faster Code

Available for purchase at Amazon.com.

Featured Posts: Python Programming

Pulling All Sorts of Financial Data in Python [Updated for 2021]

When to Use Heap Sort to Speed Up your Python Code

Fastest Way to Flatten a List in Python

Topics

  • 3D Technology and Virtual Reality (8)
  • Automated Trading (9)
  • Business Management (9)
  • Chris Conlan Blog (5)
  • Computer Vision (2)
  • Programming with Python (16)
  • Programming with R (6)
  • Snippets (8)
  • Email
  • LinkedIn
  • RSS
  • YouTube

Copyright © 2021 · Enterprise Pro Theme On Log in