Shadman
Shadman

Reputation: 773

apidocjs not returning anything in response

I have installed 'apidoc' after installing 'npm' and 'node' for my API documentation by the help of following command:

npm install apidoc -g

After installing apidoc globally, I simply ran below command on my project directory (assuming apidoc will consider its default template file):

apidoc

In result no errors and no documentation generated.

Similarly, I have tried:

apidoc -i ~/PROJECTS/jruby/project/webservice/ -o ~/PROJECTS/apidocs/apidoc/ -t ~/PROJECTS/apidocs/mytemplate/

But nothing happens, in that case I had nothing on 'mytemplate' directory.

Can you guys please tell me what I've missed to install/consider? and why nothing is appearing on command execution?

Note: I'm using this for my ruby application, but unable to install its gem as we're running our application on ruby 1.9 and it requires ruby 2.0. I need an independent solution that should works for other projects as well.

Thank you.

Upvotes: 0

Views: 1854

Answers (1)

Shadman
Shadman

Reputation: 773

I got the solution; copied 'package.json' file from https://github.com/apidoc/apidoc and ran below command for npm

npm install 

after getting success install nodejs properly by following steps:

curl -sL https://deb.nodesource.com/setup | sudo bash -

sudo apt-get install nodejs

then went to the project directory and ran the following command:

apidoc

after success of above command got html document in doc/ directory inside project. Cheers !

Upvotes: 1

Related Questions