π General main files
The main file is the fundamental code of your bot, making your bot go online and perform other actions automatically. Such as: index.js
, bot.js
and index.py
, depending on what name you put in.
π Exceptions (defaults)
Some bot making software, such as Discord Bot Maker and Discord Bot Controls, have a default main file already set up, which is: bot.js
.
π€ How do I know my main file?
JavaScript
The main file is the one you use to start your bot:
when running node MainFile.js
command
which is usually in package.json
in main
Python
The main file is the one you use to start your bot:
when running python MainFile.py
command
by right clicking and then RUN in PyCharm.
Java
The main file is the one you use to start your bot:
when running java -jar MainFile.java
command
by double-clicking the file MainFile.jar
Ruby
The main file is the one you use to start your bot:
when running ruby MainFile.rb
command
Go
The main file is the one you use to start your bot:
when running go run MainFile.go
command
Php
The main file is the one you use to start your bot:
when running php MainFile.php
comma
Rust
Usually the main file is src/main.rs