« Return to Thread: factoring out commonality in sequences of tasks

factoring out commonality in sequences of tasks

by jscripter :: Rate this Message:

Reply to Author | View in Thread

Suppose I have an operation which deploys files and I have the option of deploying the files by copying them and deploying using symlinks:

<target name="deploy-using-copy">
  <task1>
  <copy-files-2>
  <task3>
  <copy-files-4>
  <task5>
</target>

<target name="deploy-using-link">
  <task1>
  <link-files-2>
  <task3>
  <link-files-4>
  <task5>
</target>

What's the best way to factor out the commonality of these two targets?

Note that <task1>, <task3>, etc. are going to be sequence of tasks and not just a single task element.
(Is it possible to define a task which is a sequence of tasks?)

Thanks,
ER


 « Return to Thread: factoring out commonality in sequences of tasks