Diy "todo"

Hi there,

I made myself a little “TODO-Overview”
In order for it to work like I want it to, there needs to be a global Variable (in my Example it is called “TODO”)
and the preprocessor directives must be allowed:

I made a Codesnippet for it:

$var_name$;
#warning "TODO: $selected$$end$"

A “TODO” in ST will look like this:

	TODO; 
	#warning "TODO: This is my Text"

This way, you can see the todo everytime you compile the corresponding task (or make a rebuild of the whole project) in the Results Window.
Because I dont want to rebuild the project everytime I want to check for TODO’s you can also have a look at the “Cross Reference” and filter for your variablename…
image

Does anyone have a more elegant or easier solution?
I’m thankful for any tips/ideas!

You can do a “Find in Files”, and search for any string you want, for example “TODO”.

This does not require a build / rebuild or a cross reference build to update. As an added bonus you get the whole line as a result. Double clicking a line in the results will take you to the line in the code.

image

This way you can search for the #warning messages or just // TODO comments… Or anything else.

1 Like

NIce one… Do you Think there is any suitable settings or ways to reduce the build Time and transfer time of a huge project.
I am working on a project which takes more than 15 minutes to build and transfer. The problem is if have to test a small logic of that program it would take a junk of time to test

Hi Kumar,

you probably talk about a complete rebuild of the project? A big project will always take a “lot” of time to build… depending on the Automation Studio- and Compiler Version an the buildtime gets shorter.

Best way is to only build the task(s) you need. For this your projects set up in a way that allows that (no, or almost no global variables is always a good start…)

But without seeing the project I cant really give you any tips on that… sorry.

Well, that is the most obvious solution… :slight_smile:
What I wanted to do was/is to make a TODO-Overview like you know from other editors.

But thank you for the hint, maybe I should have included it in my original post.