Skip to content

Commit

Permalink
fix(cli): add missing shebang line in garden binary
Browse files Browse the repository at this point in the history
  • Loading branch information
edvald committed Jun 5, 2018
1 parent d90cb0b commit 632925d
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 16 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ gulpfile.js
src/**/*.js
src/**/*.map
src/**/*.d.ts
static/bin/garden.js
test/**/*.js
test/**/*.map
*.tgz
2 changes: 1 addition & 1 deletion bin/garden
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash

garden_root=$(cd `dirname $0` && cd $(git rev-parse --show-toplevel) && pwd)
node ${garden_root}/build/src/bin/garden.js "$@"
node ${garden_root}/build/static/bin/garden.js "$@"
2 changes: 1 addition & 1 deletion bin/garden-debug
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash

garden_root=$(cd `dirname $0` && cd $(git rev-parse --show-toplevel) && pwd)
node --inspect ${garden_root}/build/src/bin/garden.js "$@"
node --inspect ${garden_root}/build/static/bin/garden.js "$@"
2 changes: 1 addition & 1 deletion gulpfile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ process.on("SIGINT", die)
process.on("SIGTERM", die)

gulp.task("add-version-files", (cb) => {
const gardenBinPath = join(destDir, "src", "bin", "garden.js")
const gardenBinPath = join(destDir, "static", "bin", "garden")
const proc = _spawn("node", [gardenBinPath, "scan", "--output=json"])

proc.on("error", err => cb(err))
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
},
"preferGlobal": true,
"bin": {
"garden": "./dist/src/bin/garden.js"
"garden": "./dist/static/bin/garden"
},
"files": [
"dist"
Expand Down
11 changes: 0 additions & 11 deletions src/bin/garden.ts

This file was deleted.

5 changes: 5 additions & 0 deletions static/bin/garden
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env node

const cli = require("../../src/cli/cli")

cli.run()
2 changes: 1 addition & 1 deletion test/integ/run
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

here=$(cd `dirname $0` && pwd)
garden_root=$(cd ${here} && cd $(git rev-parse --show-toplevel) && pwd)
garden_bin="node ${garden_root}/build/src/bin/garden.js"
garden_bin="node ${garden_root}/build/static/bin/garden"

cd ${garden_root}/examples/hello-world

Expand Down

0 comments on commit 632925d

Please sign in to comment.