Previously I described a simple version control mechanism and provided a script that makes it super easy for you to adopt that approach. Let me add couple more comments about backups here.
The main idea of a backup is that you copy files over to some other physical media like another hard drive, a “USB stick”, memory card, or what have you.
There are plenty of software packages for making backups out there, sometimes they back up your files in very sophisticated ways. To keep things simple for myself I wrote a Python script that I use to backup my work (mostly code files). You are more than welcome to reuse that script. The PARAMETERS section at the top allows you to configure what files or folders you want to backup, where do you want to put them, and couple more things. See the README file and comments for more details.
The work horse of this script is Python’s function shutil.copy2, which is one of the best functions for copying files. To copy directories, the script uses shutil.copytree, which in turn uses shutil.copy2. Note that there are other ways of copying files, but the functions in shutil module are suitable for most situations.