You can use GitHub or another version control solution (GitLab, Bitbucket) with WordPress, which allows you to use the modern development features of version control with WordPress.