Performance improvements for file collection, factoring out file-collector
Factoring out cli-helper