Snippets in Sublime text: a video tutorial

Lovely guys, today we are going to talk about my fav editor: Sublime Text. Yes, I know Visual studio code is great, but, so fast as you can make stuff with sublime text there are nothing. And Sublime text and Python are very close. So, here is how to speed up your work in case you didn’ know it. I have talked yet in the past years of snippets, but why not revisit it, in case someone still doesn’t thought about this ‘tool’. In the video below you will find my example using it, because an example is better than 1 million words. See ya for the next post in these times of AI news surrounding us, where Python is the main contributor to it’s glory.

Let’s see how to use snippets in Sublime Text. Snippets are a very useful way to avoid writing always the same code that are requested to start some projects (for example all that code you have to write to create a window with pygame making a game in Python or the title, head tags for an html file or any kind of annoying stuff you have to put into some file everytime). If you want to avoid wasting time rewriting it or you do not want to go find templates you can have saved somewhere, you can use a simple word to recall that text/code and it will appear magically in the page pressing TAB. You also have the chance to change easily some “customizable” part of the text (for example the title of an html file and other text in that file) with a simple press of the TAB key that will make you “travel” throug the different parts of the text that you want to customize in the snippet for the particular purpose of that text or code you want to create. Check the video and you will see what I do mean, if my explanation isn’t clear. Bye and see ya soon.


Subscribe to the newsletter for updates
Tkinter templates
Avatar My youtube channel

Twitter: @pythonprogrammi - python_pygame

Videos

Speech recognition game

Pygame's Platform Game

Other Pygame's posts

Published by pythonprogramming

Started with basic on the spectrum, loved javascript in the 90ies and python in the 2000, now I am back with python, still making some javascript stuff when needed.