odf / webGavrog

Generation, analysis and visualization of reticular ornaments using Gavrog, now coming to a browser near you. Demo at http://gavrog.org/webGavrog/.
Apache License 2.0
9 stars 0 forks source link

Cannot build because of fatal: ambiguous argument '${GIT_REV}' #9

Closed Lolcroc closed 3 years ago

Lolcroc commented 3 years ago

To reproduce npm run build-dev

Issue

webGavrog@0.0.0 build-dev C:\redacted\webGavrog webpack --mode development --debug --devtool cheap-module-source-map --output-pathinfo fatal: ambiguous argument '${GIT_REV}': unknown revision or path not in the working tree.

GIT_REV is not listed as an environment variable according to https://git-scm.com/book/en/v2/Git-Internals-Environment-Variables.

Replacing ${GIT_REV} with HEAD gives me another error instead

webGavrog@0.0.0 build-dev C:\redacted\webGavrog webpack --mode development --debug --devtool cheap-module-source-map --output-pathinfo

C:\redacted\webGavrog\node_modules\node-elm-compiler\dist\index.js:85 .on('error', function (err) { throw (err); }); ^

Error: spawn elm ENOENT at notFoundError (C:\redacted\webGavrog\node_modules\cross-spawn\lib\enoent.js:6:26) at verifyENOENT (C:\redacted\webGavrog\node_modules\cross-spawn\lib\enoent.js:40:16) at ChildProcess.cp.emit (C:\redacted\webGavrog\node_modules\cross-spawn\lib\enoent.js:27:25)

Solution (for other people) I had no idea what elm was. There's an installer on https://guide.elm-lang.org/install/elm.html, just make sure it's in your PATH.

odf commented 3 years ago

Thanks! It should be fixed now.

It seems that particular line in webpack.config.js had been broken for some time, but my various Unix systems all silently treated ${GIT_REV} as an empty string.