I am building a site with code igniter and I am using git for version control. I am not sure why, but duplicates of my files keep popping up. If I have a home.php controller there is also a home.php~ controller. It is not really causing a problem with the functionality of the site, but it is weird and I don’t like it. What exactly is going on?
My editor was set to backup files. I just had to turn it off.

The tilde files are automatic backup files of the last version created by the text editors. You can turn off this automatic creation by editing the preferences of the text editor you use.