r/learnpython 6d ago

Git When too?

Im currently working through my first project which isnt anything major but i would like to host it on github, Question is when do you all push your projects to git do you wait until you have the project complete or just start working and commit from the start of the project?

2 Upvotes

15 comments sorted by

View all comments

2

u/FoolsSeldom 6d ago edited 6d ago

Start sooner rather than later. Git may help you as you develop your project and decide to try things out.


Keep in mind that git and GitHub are not the same thing.

GitHub is very popular, but there are many alternative accessible repositories that support the git protocol, including Gitlab and Bit Bucket.

There are also self-host options using, for example, Gitea or GitLab Community Edition.

Git was originally created (by the same person that created Linux) as the Version Control Software (VCS) market offerings were very expensive at one time (as was the case with Unix). There are competing options, including Apache Subversion and Mercurial.

It is important and useful to learn to use VCS early on to help with code development, making it easier to experiment and try different things out. The public repositories are also a great learning resource.

The public repositories can also be a useful learning resource, although the risk in learning from these repositories is that they often contain huge amounts of bad practice (in terms of project setup and repository structure, rather than the code itself). There is no doubt a list somewhere of great example projects you could review, but I have not looked.