Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I can't Install Discord.js #110

Closed
rogafe opened this issue Dec 27, 2015 · 5 comments
Closed

I can't Install Discord.js #110

rogafe opened this issue Dec 27, 2015 · 5 comments

Comments

@rogafe
Copy link

rogafe commented Dec 27, 2015

//Sorry for my English i am French

The server said:
npm WARN ENOENT ENOENT: no such file or directory, open '/root/package.json'
npm WARN EPACKAGEJSON root No description
npm WARN EPACKAGEJSON root No repository field.
npm WARN EPACKAGEJSON root No README data
npm WARN EPACKAGEJSON root No license field.

http://i.imgur.com/G4QxK3a.png

@brussell98
Copy link
Contributor

Just to make sure, you are running this in the root directory of the bot and it contains a package.json file right?
image

@abalabahaha
Copy link
Contributor

Notice the "WARN". It's a warning, but it does not break your installation. Your installation should be fine,

@TehSeph
Copy link

TehSeph commented Dec 28, 2015

@rogafe Do npm init and follow the steps and fill in the information for your bot.
Then do npm i --save discord.js --no-optional after completing all the steps.

The warnings are because NPM is failing to find a package.json file where you are attempting to install the library. The first command will create that file for you using the information you give it. The second command installs the library, like you have already done, but with the --save flag which will add it to the file created in the first step.

As @abalabahaha said above, the library is installing fine but NPM is warning you that it failed to find a package.json file and thus also can't find the 4 fields in the other warnings which are soft-requirements for all public packages. You could technically use the library as it is installed now, but any time you go to install another package NPM will spit out the same warnings until you have fixed it.

@rogafe
Copy link
Author

rogafe commented Dec 29, 2015

Thank you all for your reply, I reinstate the server and everything works
Thanks Rogafe

@rogafe rogafe closed this as completed Dec 29, 2015
@jelliots2
Copy link

I'm having issues installing discord.js too. It gives me the same warnings. I tried to use npm init and the other command from Seph but it gives me an error saying "no capital letter can be used" even though there arent caps in it. help pls.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants