Hello,
I’ve recently done some refactoring on my FinalBuilder project to make it easier to turn on/off certain tasks I need when debugging/testing.
I am curious if it is possible to have some sort of validation that a variable is not being used before it has been set. So, I’ve reordered some tasks and a dependency of “variable1” has been more prior to the variable being set. Is there a way to set up validation warning or error?
Thanks,
Matt
Hi Matt,
Sorry, but no - there’s no way to do what you want as the validation is just for the actions in your project. And… as far as FinalBuilder is concerned, variables are always valid as they get reset to their default values before the project runs.
cheers,
.t8
It’d be nice if the validation could at least check that variables are defined. Currently, if you rename a variable, none of its references are updated - and if you forget to update one manually, your project will fail at runtime, rather than at validation time.
Steve
ah, yes, that is possible. That is a good idea - we could automatically scan all actions before the build starts looking for variables that aren’t yet defined and fail validation based on that.
Would it also be possible to have a way of checking for unused variables? I'm just cleaning out a project and it's fairly tedious to individually search for each variable and find out if it's used anywhere. Maybe a column in the variables window that says how many references it has?
Steve
don’t see why not…
Was there ever any movement on a feature to assist with variable cleanup? We have a very large project we've been maintaining for 2+ years now, and there's a number of unused variables that I would like to clean up, but like the previous poster said, you have to search the entire project for each variable to know if it's unused.
Thanks,
Keith
Hi Keith,
Sorry, we haven’t investigated this issue yet.