Skip to content

Commit

Permalink
Fix the build system
Browse files Browse the repository at this point in the history
  • Loading branch information
cedx committed Nov 8, 2024
1 parent 480d2c4 commit b85bc24
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/cakefile.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ option "-m", "--map", "Whether to generate source maps."

task "build", "Builds the project.", (options) ->
sourcemaps = if options.map then ["--map"] else []
run "coffee", "--compile", sourcemaps..., "--no-header", "--output", "lib", "src"
npx "coffee", "--compile", sourcemaps..., "--no-header", "--output", "lib", "src"

task "clean", "Deletes all generated files.", ->
rmSync join("lib", file) for file from readdirSync "lib" when not file.endsWith ".d.ts"
Expand All @@ -29,7 +29,7 @@ task "publish", "Publishes the package.", ->

task "test", "Runs the test suite.", ->
env.NODE_ENV = "test"
run "coffee", "--compile", "--map", "--no-header", "--output", "lib", "src", "test"
npx "coffee", "--compile", "--map", "--no-header", "--output", "lib", "src", "test"
run "node", "--enable-source-maps", "--test", "--test-reporter=spec", "lib/**/*_test.js"

task "version", "Updates the version number in the sources.", ->
Expand All @@ -38,7 +38,7 @@ task "version", "Updates the version number in the sources.", ->

task "watch", "Watches for file changes.", (options) ->
sourcemaps = if options.map then ["--map"] else []
run "coffee", "--compile", sourcemaps..., "--no-header", "--output", "lib", "--watch", "src", "test"
npx "coffee", "--compile", sourcemaps..., "--no-header", "--output", "lib", "--watch", "src", "test"

# Executes a command from a local package.
npx = (command, args...) -> run "npm", "exec", "--", command, args...
Expand Down

0 comments on commit b85bc24

Please sign in to comment.