A simple templater for your project: manage the tree with a simple script!
- Total 2K
- Win 1K
- Mac 459
- Linux 485
|Oct 26||Oct 25||Oct 24||Oct 23||Oct 22||Oct 21||Oct 20||Oct 19||Oct 18||Oct 17||Oct 16||Oct 15||Oct 14||Oct 13||Oct 12||Oct 11||Oct 10||Oct 9||Oct 8||Oct 7||Oct 6||Oct 5||Oct 4||Oct 3||Oct 2||Oct 1||Sep 30||Sep 29||Sep 28||Sep 27||Sep 26||Sep 25||Sep 24||Sep 23||Sep 22||Sep 21||Sep 20||Sep 19||Sep 18||Sep 17||Sep 16||Sep 15||Sep 14||Sep 13||Sep 12||Sep 11|
Project Tree Templater - Bring templates to your project!
This is a simple plugin for
Of course, this could be the probably not-common case of work, but in fact, sometimes happenes, from creating templates to starting little projects.
Today, with this plugin you can automate all your work, with only a few line of meta declarations, and everytime your project file will be saved, it will be reflected to your project folder. Simple as it should be.
How it works
The only thing you have to do is creating a
my_project_name_here.stprj file wherever you want, remember that EVERYTHING will be created in the same place where, that file, will be saved.
After that, what you have to do is declaring your project structure as likely you're used to do manually.
For example, the project mentioned in the
Introduction before, could be written as the following:
css/ js/ index.html
Yes, that's it. Pretty simple and clean! Does it sound familiar? Yeah, Unix path declaration. Nothing more, you have all the basis you would need to use this plugin. Nothing new.
To simply place a comment in your source script use the
#character as the first character of your line. An example of use would be:
# Example of comment
To simply remove any file from your project everytime you save place the
-character as the first character of your line. An example of use would be:
but let we suppose we're going to remove all files inside the folder (and the folder itself), then we have to write:
or you can also write
since it will autodetect if it's a folder. Notice that this is just the same syntax as
To place a default template for every file which will be created with that extension we will use the
?character as the first character of your line. An example of use would be:
?css:path/to/tpl.css ... css/style.css
remember that global templates MUST be declared before ANY path declaration.
To place a single template for a single file, overriding also the global template (if it exists), we have to write the
:character AFTER the path declaration. An example of use would be:
You can now use URLs (http or https) to download resources (even in templates or in single files). Just put your URL after the
:charater. An example of use would be:
NEW! You can use Groups! It's nothing special, it's just a parent directory that will contain any path inside of it. An example of use woud be:
foo ( css/ js/ index.html )
foo/bar ( css/ js/ index.html )
If you place a
/ character at the beginning of any path (template or not), the path will be always considered RELATIVE to the project file.
How to install
Soon it will be available to Sublime Package Control.
So what you have to do is: press code>Ctrl+Shift+P, type
Enter then type
ProjectTreeTemplater and finally press again the
In the meanwhile, to install it you just have to download a copy of this folder, and copy it to the one of your already existing packages. To find it, simply open Sublime Text and then do
Preferences -> Browse Packages...
and place it inside that folder.
Last but not least
This plugin is far from perfect, so if you find any bug you're free to contribute :)