Closed pke closed 7 years ago
Sorry about the confusion in the documentation and API, but the .branch()
api actually works without the flag being enabled.
You can check the implementation https://github.com/pirelenito/git-revision-webpack-plugin/blob/master/lib/index.js#L71
By default it's false, I could see that. The example code in the readme is still wrong, isn't it? Ah so calling branch()
directly will always perform the git command and return the branch, ok. Got it.
You'd have to specify it in the options then why? So path substitution would work?
The option affects path substitution and creating the BRANCH file.
Right, thanks! Great plugin. Will help to improve our customer services in connection with sentry.io a great step.
https://github.com/pirelenito/git-revision-webpack-plugin#plugin-api
The first usage example shows
BRANCH
being used in the define plugin, but the call tonew GitRevisionPlugin()
doesn't include thebranch: true
option so no branch name is generated.