Add a .jq query to obtain the transitive closure of a whole module type.
Minor refactor for code reuse.
Change-Id: Id6c736a2937ac24319a8dd53086965f5505eb364
Test: ./build/bazel/json_module_graph/query.sh fullTransitiveModuleTypeDeps out/soong/module-graph.json android_app
Test: ./build/bazel/json_module_graph/query.sh fullTransitiveDeps out/soong/module-graph.json Music
Test: ./build/bazel/json_module_graph/query.sh modulesOfType out/soong/module-graph.json android_app
Bug: 198224074
4 files changed