create-discord-bot issues
Im trying to run
npx create-discord-bot . --typescript
and for some reason, rather than creating the files, it just opens an index.mjs file. Any ideas what could be the fix for it?25 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!welp I found a "work around" for it which would be running the .mjs file after running the npx command. But Id like to know how to fix it cause it is annoying to do
okey can be fixed
how?
could I like test it somehow?
it will work
welp aight then
i even added you to pr ;>
yeah I noticed XD
Also I wanna add that in the
src/util/deploy.ts
file at line 11. Its giving the error
This is for the typescript template
havent you overwritten your rest package?
no?
This is the entire file content, and I didnt change anything from the template when I did my "workaround"
though is the API class a new thing? Ive never used it before nor have I heard of the bulkOverwriteGlobalCommands function
oh yeah its on clear install
any ideas on how to fix it?
install core as 1.0.0
or do I just copy from discordjs.guide in the meant time?
alr
then rest version will also match
neat that worked, thanks! could you also open a pr for that to get fixed too?
it would require pr for every version change
ah alright then, I guess Im just gonna keep that in mind when making more bots with the template
thanks for helping me out btw! Ill just mark this post as solved once https://github.com/discordjs/discord.js/pull/9747 is merged already
GitHub
fix(create-discord-bot): add shebang in main file by jaw0r3k · Pull...
Please describe the changes this PR makes and why it should be merged:
Bug intoduced in #9570
Found in djs-questions post by rob0520
Status and versioning classification:
This PR only includes non...
Ooh aight