Skip to content

Commit

Permalink
fix: Fix generation on Windows
Browse files Browse the repository at this point in the history
Fixes #154
  • Loading branch information
jskeet committed Mar 11, 2021
1 parent b66468c commit 1909082
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tools/proto2jsonschema/postgen.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ console.log(`Fixing paths in dir: ${ROOT}`);

// Create the modified JSON schema output
const json = JSON.parse(fs.readFileSync(filePath).toString());

// Replace backslashes with forward-slashes to allow the script
// to work on Windows.
filePath = filePath.replace(/\\/g, '/');

const packageName = getCloudEventPackage(filePath);

const resultJSON = {
Expand Down

0 comments on commit 1909082

Please sign in to comment.