[Github importing] Automatically removes all files

I just imported a repository from Github into a new project to test it out. I ran git remote -v to see what ‘remotes’ are configured. Remotes are like external places that your git repository knows how to connect to. Automatically, my project includes a remote called ‘origin’ that points to my original Github repository.

I made a change in my Test Repository on Github and committed it to the master branch. Then, in Glitch, I ran git pull origin master to bring that change from Github into my Glitch project.

git pull: “Fetch from and integrate with another repository or a local branch”. It can be used like this:

git pull [remote] [branch on the remote I want to pull into my current branch]

So, if you've been making changes on the branch called "my-feature", you'd call `git pull origin my-feature` in the Glitch console.

You might find when you run git remote -v that your Github URL is under a different name than origin. No problem! Just call git pull remote-name branch-on-remote-name with the values of remote-name and branch-on-remote-name set to the values that match your setup.

If this all sounds intimidating, you can do what I did and make a new repository on Github, import it into a new Glitch project, and test out your setup and the commands a few times before doing it in your bot project.