I agree with the version control answerversion control answer, but another method I've been experimenting with recently is Dropbox. It's essentially a version control system that automatically syncs between all your machines, so if you edit a file on one computer you'll see the changes reflected on your other computers in a couple seconds, without needing to commit on the former and update on the latter.
Their free basic plan is 2GB, so I use it to version my configuration files and chat logs