Skip to content

Commit

Permalink
Merge pull request codecrafters-io#37 from ShonFrazier/bugfix/paths-w…
Browse files Browse the repository at this point in the history
…ith-spaces

for issue codecrafters-io#36 - wrap file argument in quotes
  • Loading branch information
rohitpaulk authored Aug 13, 2024
2 parents 723fb89 + 373e565 commit d7ba180
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/compilers/starter-template-compiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,11 @@ export default class StarterTemplateCompiler {

if (filepath.endsWith(".md")) {
console.log(` - postprocessing ${relativePath}`);
await dockerShellCommandExecutor.exec(`prettier --prose-wrap="always" --write --ignore-path ./.prettierignore ${relativePath}`);
await dockerShellCommandExecutor.exec(`prettier --prose-wrap="always" --write --ignore-path ./.prettierignore "${relativePath}"`);
} else if (filepath.endsWith(".js")) {
console.log(` - postprocessing ${relativePath}`);
await dockerShellCommandExecutor.exec(
`prettier --write --ignore-path ./.prettierignore --no-error-on-unmatched-pattern --check ${relativePath}`
`prettier --write --ignore-path ./.prettierignore --no-error-on-unmatched-pattern --check "${relativePath}"`
);
}
}
Expand Down

0 comments on commit d7ba180

Please sign in to comment.