TypeError: dgeni-packages/git
Added require('dgeni-packages/git') to my Dgeni Package and corresponding gulp task as described in example and on run gulp dgeni from my project directory I get TypeError: Cannot read property '1' of null. Dgeni docs build successfully when I comment out require('dgeni-packages/git').
TypeError: Cannot read property '1' of null
at gitRepoInfo (/myprojectdir/node_modules/dgeni-packages/git/services/gitRepoInfo.js:11:17)
at Array.invoke (/myprojectdir/node_modules/di/lib/injector.js:75:15)
at get (/myprojectdir/node_modules/di/lib/injector.js:48:43)
at /myprojectdir/node_modules/di/lib/injector.js:71:14
at Array.map (native)
at Array.invoke (/myprojectdir/node_modules/di/lib/injector.js:70:31)
at get (/myprojectdir/node_modules/di/lib/injector.js:48:43)
at /myprojectdir/node_modules/di/lib/injector.js:71:14
at Array.map (native)
at Array.invoke (/myprojectdir/node_modules/di/lib/injector.js:70:31)
Same issue here
You'll get this if https://github.com/angular/dgeni-packages/blob/974173de87add514b1f3f584a97e00a1881873a7/git/services/gitRepoInfo.js#L8
fails to parse the repository.url field in your package.json. For example if the field is missing or it is formatted for SSH like [email protected]:angular/angular.js.git.
Updating package.json: as below, solved it for me.
From
"repository": "[email protected]:angular/angular.git",
To:
"repository": {
"type": "git",
"url": "https://github.com/angular/angular.git"
},