Skip to content

Commit

Permalink
Use a fully resolved path for workDir. (#125)
Browse files Browse the repository at this point in the history
Otherwise, when attempting to specify a root output directory like
`--out ./build` build output will end up in `./build/build` for reasons
I don't fully understand. Using fully resolved paths is a good practice
in any case.
  • Loading branch information
ajmacd authored and unbornchikken committed Jul 16, 2018
1 parent 8136a2f commit b6ed989
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/es5/cMake.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/es6/cMake.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ function CMake(options) {
this.log = new CMLog(this.options);
this.dist = new Dist(this.options);
this.projectRoot = path.resolve(this.options.directory || process.cwd());
this.workDir = this.options.out || path.join(this.projectRoot, "build");
this.workDir = path.resolve(this.options.out || path.join(this.projectRoot, "build"));
this.config = this.options.debug ? "Debug" : "Release";
this.buildDir = path.join(this.workDir, this.config);
this._isAvailable = null;
Expand Down

0 comments on commit b6ed989

Please sign in to comment.