In parallel with the blend-gen-control tests I wrote (and just committed) a first simple tasks_diff. I followed your idea: We have a json file which contains the dependencies status for a release and we will compare it with the fresh data to find tasks differences to put them into the changelog. So a first function of the tasks_diff script is to get a tasks directory argument and dump a json file with the dependencies.
Example, let's take the case where we dump into a json file the dependencies of debian-med 1.13:
#-t/--tasks arg generally passes the directory where the tasks folder exists(Blend root directoty), default -t value is "." (in case you execute it into a Blend directory) and -s/--statusdump arg is given as flag arg to generated the json file.
./tasks_diff -t med/tags/1.13/ -s
This will generate a tasks.json file in the current directory containing the dependencies. In case you want to override the default tasks.json output you can do (-o/--output):
./tasks_diff -t med/tags/1.13/ -s -o mydeps.json
Once we have a json file containing dependencies for a release(in the above case for med 1.13) we can compare these dependencies with another release for example with med 1.13.1 as following:
Again we have to pass the -t directory arg (it will read from there the tasks to compare), also we have to pass -c/--compare flag to make the comparing. By default tasks_diff it will try to read a "tasks.json" file in the current directory.
./tasks_diff -t med/tags/1.13.1/ -c
or in case you have overrode the tasks.json file you can provide the json file which you want to make the comparing with as:
./tasks_diff -t med/tags/1.13.1/ -c -j mydeps.json
This will dump in stdout(plain print) the package/task difference betweem the releases:
A sum up to do a fast test/run:
./tasks_diff -t med/tags/1.13/ --status-dump
./tasks_diff -t med/tags/1.13.1/ --compare
That way we have a first idea of how the final tasks_diff(any suggestion for different script name?) should be.
Any feedback is always more than welcome :-)
Also, tasks_diff script should look for tasksprefix in the control.stub file?