What is the difference between DependsOnTargets
and AfterTargets
?
I can not distinguish these two.
DependsOnTarget
Let's assume that you have two tasks:
You can start your build by executing task 2 and then in the task declaration define its dependencies. So if you define that task 2 depends on task 1, the build process will start and execute task 1 and then 2.
AfterTargets
Much simpler: it means only tasks which are execute after other targets. So taking the example from above - after Task 1 - build project execute task 2.
I hope this helps