-
Notifications
You must be signed in to change notification settings - Fork 164
Migrating to a git install
A lot of you installed Ballsdex by downloading the source code in a zip file, which doesn't support updating. This tutorial will explain how to migrate to a git-based install while keeping your data.
Obviously, you now need to install git on your computer.
During the installation, be sure to choose the option that says "Git from the command line and also for 3rd-party software". Leave the other options to their default values.
-
Right-click in the place where you want to install the bot, for instance your desktop, and select "Git bash here".
-
Paste the following command:
git clone https://github.com/laggron42/BallsDex-DiscordBot.git
A folder named BallsDex-DiscordBot
should have appeared. If not, right-click and hit "Refresh".
-
Open the terminal app and navigate to the folder where you want to install the bot using the
cd
command. For instance, if you want to install the bot in your desktop, typecd Desktop
. -
Paste the following command:
git clone https://github.com/laggron42/BallsDex-DiscordBot.git
A folder named BallsDex-DiscordBot
should have appeared.
We will need to move all files present in the folder that was just downloaded. The operating system is hiding some files by default, so we will have to turn an option on to ensure we can see everything.
- Open the file explorer
- Click on the View tab
- Windows 11: In the dropdown, select "Show" then click "Hidden items". You can also turn on "File name extensions", may be useful later.
- Windows 10: Tick the "Hidden items" checkbox. You can also tick "File name extensions", may be useful later.
In theory, Cmd+Shift+. (dot)
works, but it doesn't for me, maybe because of the keyboard layout. If it doesn't work for you, here's an alternative way to show hidden files:
- Open the terminal
- Type the following command
defaults write com.apple.Finder AppleShowAllFiles true
- Open the Force Quit dialog (Apple Menu > Force Quit or Alt+Cmd+Esc) and force restart the Finder
It depends on the file explorer application you're using. Dig the option, or use the terminal with ls -a
. Or just use the mv
command during the next step, which takes everything.
- Open the new folder downloaded from git. It should be named
BallsDex-DiscordBot
. - Open in a different window or tab the old bot folder, the one you're currently using. It may be named
BallsDex-DiscordBot-master
or something like that. - Select everything in the new folder (Ctrl+A) and move the files to the old folder.
- You will see warnings about conflicting files. Tick the option to replace all files.
- The new folder should now be empty. Check that the old folder now has a
.git
hidden folder!
Congratulations, your configuration is now migrated. Run git status
to ensure the status of git, see if any problem is listed.
You can now continue by updating and restarting the bot.
Support my work on Patreon and get exclusive rewards!
For $10/month, I will be hosting your custom bot on my server, with immediate updates, secure and shared admin panel, and stats on https://grafana.laggron.red !