Unnecessary getSubmodulePaths
cblp opened this issue · 1 comments
cblp commented
I'm trying to solve one particular problem — to get a branch name for a repository inside a given path.
I'm doing
var GitUtils = require('git-utils')
console.log(GitUtils.open(path).getShortHead())
But open
performs too slow on sshfs. It takes about 5 or 6 seconds to getSubmodulePaths
. The other code takes about 10 ms.
I suggest to delay openSubmodules
for the time when it will be needed, and to not call it in open
.