With each new release of NX v16.1.4, the file
node_modules/.cache/nx/nxdeps.json
is created.
The structure of this file differs from the one generated by nx graph. In previous versions up to 16.1., the file contained an array named nodes.<app/lib>.data.files
, which included all files with hash values.
"data-access-anything": {
"name": "data-access-anything",
"type": "lib",
"data": {
"name": "data-access-anything",
"$schema": "../../../../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "libs/data-access/anything/src",
"projectType": "library",
"files": [ // <-- need this files array
{
"file": "libs/data-access/anything/.babelrc",
"hash": "2685020516260856122"
},
{
"file": "libs/data-access/anything/.eslintrc.json",
"hash&: "15754961097349354736"
},
// ...
]
}
},
I utilized this information to track version changes in individual applications using git commit logs. Each commit modifies files, and the arrays in nxdeps.json provide insight into affected libraries and applications.
In the latest version, this process has been altered. Hence, my query is whether it's feasible to manually generate the file contents?