There is a new way to calculate the hashes of the repo in rushstack.
Previously we used...
import { getPackageDeps } from "@rushstack/package-deps-hash";
https://github.com/microsoft/backfill/blob/main/packages/hasher/src/repoInfo.ts#L9
But, the Rush team has added similar functionality in https://github.com/microsoft/rushstack/blob/main/libraries/package-deps-hash/src/getRepoState.ts#L384
The getPackageDeps calls ls-tree which is slow under certain circumstances. (microsoft/rushstack#5499)
The new functionality uses ls-files which alleviates the issue.