JKHeadley / rest-hapi

🚀 A RESTful API generator for Node.js
https://resthapi.com
MIT License
1.19k stars 153 forks source link

I dont see any file at ./node_modules/.bin/rest-hapi-cli #158

Open rajeshwar-fissionhq opened 5 years ago

rajeshwar-fissionhq commented 5 years ago

Describe the bug I don't see any file at $ ./node_modules/.bin/rest-hapi-cli to run the command $ ./node_modules/.bin/rest-hapi-cli seed

To Reproduce Steps to reproduce the behavior:

  1. Cloned the repo using git clone https://github.com/JKHeadley/rest-hapi-demo.git
  2. cd rest-hapi-demo
  3. npm install
  4. ./node_modules/.bin/rest-hapi-cli seed

Expected behavior After following the above steps it's saying zsh: no such file or directory: ./node_modules/.bin/rest-hapi-cli

Desktop (please complete the following information):

JKHeadley commented 5 years ago

Hi @rajeshwar-fissionhq, not sure what would cause this. What version of node/npm are you using?

rajeshwarpatlolla commented 5 years ago

node -v v8.12.0 npm -v 6.4.1

JKHeadley commented 5 years ago

hmm, that's probably not the issue. Could you paste the output of the following commands? npm bin and ls -1 ./node_modules/.bin/

launay12u commented 5 years ago

I Have the same issue, here is my npm bin :

/Users/MyUser/Projects/rest-hapi/node_modules/.bin

and ls -1 ./node_modules/.bin/ :

acorn atob babylon blue-tape bsondump cssmin escodegen esgenerate eslint eslint-config-prettier-check esparse esvalidate handlebars is-ci js-yaml jsesc jsmin lint-staged loose-envify mkdirp mongo mongo-supervise mongod mongodb-download mongodump mongoexport mongofiles mongoimport mongooplog mongoperf mongorestore mongos mongosniff mongostat mongotop npm-path npm-which nyc prettier raven rimraf seek-bunzip seek-table semver sgf sshpk-conv sshpk-sign sshpk-verify tape uglifyjs uuid which z-schema

There is no rest-hapi-cli

JKHeadley commented 5 years ago

hi @launay12u,

npm bin and ./node_modules/.bin/rest-hapi-cli seed should be performed within the directory for the project using rest-hapi (such as rest-hapi-demo), not rest-hapi itself.

mabihan commented 5 years ago

I just ran into the same problem, using Webstorm to checkout the projet. I reinstalled Node, npm but it didn't help.

Eventually, I ran the commands (git clone, npm install, ...) via command line, and it worked.

JKHeadley commented 5 years ago

@JeanReneRobin glad you worked it out! Hopefully this will help others as I'm still unsure what is causing the issue.