Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
hwangsihu committed Aug 7, 2024
1 parent 60e154c commit 38ad663
Showing 1 changed file with 13 additions and 36 deletions.
49 changes: 13 additions & 36 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@

### 🔍 Default Sources

- ![YouTube](https://img.shields.io/badge/YouTube-FF0000?style=plastic&logo=youtube&logoColor=white) ([Required Plugin][youtube-source])
- ![SoundCloud](https://img.shields.io/badge/SoundCloud-FF3300?style=plastic&logo=soundcloud&logoColor=white)
- ![Twitch](https://img.shields.io/badge/Twitch-9146FF?style=plastic&logo=twitch&logoColor=white)
- ![Bandcamp](https://img.shields.io/badge/Bandcamp-629AA9?style=plastic&logo=bandcamp&logoColor=white)
Expand All @@ -59,6 +58,7 @@

**Note: You need to install the plugins to use these sources**

- ![YouTube](https://img.shields.io/badge/YouTube-FF0000?style=plastic&logo=youtube&logoColor=white) ([Required Plugin][youtube-source])
- ![Spotify](https://img.shields.io/badge/Spotify-1ED760?style=plastic&logo=spotify&logoColor=white) ([Required Plugin][LavaSrc])
- ![Deezer](https://img.shields.io/badge/Deezer-FF0000?style=plastic&logo=deezer&logoColor=white) ([Required Plugin][LavaSrc])
- ![Apple Music](https://img.shields.io/badge/Apple%20Music-000000?style=plastic&logo=apple-music&logoColor=white) ([Required Plugin][LavaSrc])
Expand All @@ -78,9 +78,11 @@
[youtube-source]: https://github.com/lavalink-devs/youtube-source
[jiosaavn]: https://github.com/appujet/jiosaavn-plugin

To Setup a Lavalink server on Windows, Linux, or Replit, [Click Here.](https://github.com/LucasB25/lavalink-server)
To Setup a Lavalink server on Windows, Linux, or Replit, [Click Here!](https://github.com/LucasB25/lavalink-server)

### **Need Help with plugins?** Join our [Discord Server](https://discord.gg/YsJCtDuTXp) and ask for help in the `#support` channel
### **Need help with plugins?**

Join our [Discord Server](https://discord.gg/YsJCtDuTXp) and ask for help in the `#support` channel!

## 🔧 Requirements

Expand Down Expand Up @@ -116,42 +118,16 @@ cd lavamusic
npm i
```

4. Set up your environment variables:
Create a .env file in the root directory of your project with the following variables:
or you can use the [.env.example](https://raw.githubusercontent.com/appujet/lavamusic/main/.env.example) file

```bash
TOKEN= "" # Your bot token.
CLIENT_ID= "" # Your bot's client ID (If this value is left blank, bots cannot be invited using /invite or /about commands.).
DEFAULT_LANGUAGE= "EnglishUS" # Default language for bot
PREFIX= "!" # Your prefix.
OWNER_IDS= ["",""] # Your discord id (You can add multiple ids.).
GUILD_ID= "" # Your server ID (If you want to use the bot for a single server).
PRODUCTION= "true" # true for production.
TOPGG= "" # Your Top.gg API key. Obtain this from https://top.gg
KEEP_ALIVE= "false" # true for keep alive in https://replit.com
LOG_CHANNEL_ID= "" # If you enter this, you will be able to receive the status of Lavalink nodes and guild join/leave logs through the corresponding channel.
LOG_COMMANDS_ID= "" # The channel ID where command usage logs will be sent.
BOT_STATUS= "online" # Your bot status (online, dnd, idle, invisible or offline).
BOT_ACTIVITY_TYPE= 0 # Activity type is a number from 0 to 5. See more here: https://discord.com/developers/docs/topics/gateway-events#activity-object-activity-types
BOT_ACTIVITY= "Lavamusic" # Your bot activity.
DATABASE_URL= "" # Your database url (If you want to use sqlite, then you can leave it blank.).
AUTO_NODE= "false" # true for auto node. It is given from lavainfo-api (https://lavainfo-api.deno.dev).
LAVALINK_URL= "localhost:2333" # Your Lavalink url (If auto node is true, then you can leave it blank).
LAVALINK_AUTH= "youshallnotpass" # Your Lavalink password (If auto node is true, then you can leave it blank.).
LAVALINK_NAME= "Lavamusic" # Your Lavalink name (If auto node is true, then you can leave it blank.).
LAVALINK_SECURE= "false" # true for secure Lavalink (If auto node is true, then you can leave it blank.).
MAX_PLAYLIST_SIZE= "100" # Max playlist size.
MAX_QUEUE_SIZE= "100" # Max queue size.
```
4. Copy the .env.example file to .env and fill in all required values.
Note: Optional values ​​are noted as comments in the settings.

5. Generate the Prisma client:

```bash
npm run db:push
```

6. Run the migrations (Only if you want to migrate your database)
6. Run the migrations (Only if you want to migrate your database):

```bash
npm run db:migrate
Expand All @@ -167,14 +143,13 @@ npm start

8. Invite the bot to your server:

Generate an invite link for your bot and invite it to your server using the <a href="https://discord.com/developers/applications">Discord Developer Portal</a> or using <a href="https://discordapi.com/permissions.html">Permissions Calculator.</a>
Generate an invite link for your bot and invite it to your server using the [Discord Developer Portal](https://discord.com/developers/applications) or [Permissions Calculator](https://discordapi.com/permissions.html).

## 🚀 Installation using Docker Compose

This section assumes you have Docker and Docker Compose installed and running correctly.
Download the [docker-compose.yml file](https://raw.githubusercontent.com/appujet/lavamusic/main/docker-compose.yml) in a separate folder like lavamusic.
Edit docker-compose.yml and make sure to set the following variables:
Your .env file should look like this or you can use the [.env.example](https://raw.githubusercontent.com/appujet/lavamusic/main/.env.example) file.
Your .env file should look like this or you can use the .env.example file.

```yaml
TOKEN="." # Your bot token and remember, don't show everyone your bot token
Expand All @@ -194,6 +169,8 @@ docker-compose up -d
```

The above command will start all your services and your bot should be up and running!
If you want to run it from the console, remove the -d argument.

To update, you only have to type the following:

```bash
Expand Down Expand Up @@ -225,7 +202,7 @@ Do note that the bot will restart itself to update to the latest!

## 📝 Tutorial

A tutorial has been uploaded on YouTube. Watch it by clicking [here](https://youtu.be/x5lQD2rguz0).
A tutorial has been uploaded on YouTube. Watch it by [clicking here](https://youtu.be/x5lQD2rguz0).

## 📜 Contributing

Expand Down

0 comments on commit 38ad663

Please sign in to comment.