Hi everyone, today we are going to talk about a great tool for the developing process: Git and marginally the Github appendix. So, let’s introduce Git!
We can take as the first definition of Git that one of Wikipedia:

Git (/ɡɪt/[7]) is a version control system for tracking changes in computer files and coordinating work on those files among multiple people. It is primarily used for source code management in software development,[8] but it can be used to keep track of changes in any set of files. As a distributed revision control system it is aimed at speed,[9]data integrity,[10] and support for distributed, non-linear workflows.[11] Git was created by Linus Torvalds in 2005 for development of the Linux kernel, with other kernel developers contributing to its initial development.[12] Its current maintainer since 2005 is Junio Hamano. As with most other distributed version control systems, and unlike most client–server systems, every Git directoryon every computer is a full-fledged repository with complete history and full version tracking abilities, independent of network access or a central server.[13] Git is free and open source software distributed under the terms of the GNU General Public License version 2.

In a nutschell, we can use Git for controlling, updating and distributing our software code and this is precisely what we need if we are developers. Being WordPress developers, however, we could also ignore Git at all cause WordPress and its distributing/controlling system is entirely based on another Version Control System: SVN (Subversion). So, let’s compare a little Git and Svn and the reason for which we can be interested in Git also as WordPress developers.

Technically speaking there a lot of differences between Git and Svn (as like as between Git and every other VCS!). Here we will see just the main difference between these two VCSs and then we will talk about how to concretely use Git.
For more details we recommend you the Git Basics documentation. In short the major difference in the working system is that Git is not a ‘delta-based’ version control where for ‘delta-based’ we mean a system that:

think of the information they store as a set of files and the changes made to each file over time.

So, while Subversion and others check every file and update only the ones has been changed, Git is more like a mini filesystem made of a stream of snapshots:

With Git, every time you commit, or save the state of your project, Git basically takes a picture of what all your files look like at that moment and stores a reference to that snapshot. To be efficient, if files have not changed, Git doesn’t store the file again, just a link to the previous identical file it has already stored.

The first difference we talked about above may seem at first impression not so evident but it is very central for the branching topic. A bit different is another great characteristic of Git: it is Local. This means, in a nutshell, that you can work with Git even if you lost your connection or you don’t have one at the moment!
We mentioned above the branching, in few words we can create ‘branches’ from the production code base; we can work on our branches, modify the code and test it and finally we can ‘merge’ our modified code into the production one. This system is pretty common in all Version Control Systems but the way Git do it makes it really fast and secure
Our introduction to Git is not exaustive, we know, we just scraped the surface! However on Git official website you will find a lot of detailed documentation and even videos like the following to make you move concretely your first steps into Git system.
As we have said there’s a lot more about Git we didn’t cover in this post; however for what is our purpose we are more interested in a Git appendix rather than in Git itself: Github!
Github is the largest host for Git repositories, and is the central point of collaboration for millions of developers and projects. It let you to create repositories, start branches, write comments, open and pull requests and merge branches with the master one.

As like as with Git and its official documentation even for Github there’s no reason to write here a guide/tutorial while already exists – and it’s really easy to read – here. So give it just 10 minutes and you will be aware of everything you will need for creating your first repo and get to work.

NOTE: There is also a nice app called GitHub Desktop that can speed up further your workflow on Github!
We just introduced the Git version control system and Github. A more detailed overview (see the documentation links we referred) is recommended for better understanding the core processes on which Git and Github are grounded. However, for developing and distributing your code you should already be able to get away with it.

WordPress has as native VCS Subversion (SVN) and you will be forced to use it if you want to upload your plugin in the WP directory (even if a switch to Git would be desirable). However we will see that could be useful for you also have your plugin (talking of course about free plugins) on Github.

In the next tuesday post we will see concretely how to add our WordPress plugin in a Github repository and make changes to it.



You have Successfully Subscribed!

CodeCanyon Plugins

You have Successfully Subscribed!

Elegant Themes

You have Successfully Subscribed!

Try Divi!

You have Successfully Subscribed!

Divi Plugins

You have Successfully Subscribed!

Advanced Blurbs Plugin

You have Successfully Subscribed!


You have Successfully Subscribed!

Divi Cake Layouts

You have Successfully Subscribed!

Divi Cake Plugins

You have Successfully Subscribed!