In this video we're going to talk about how to contribute to open source and actually take you through
the steps but first for those who don't know what is open source well a lot of technology that has been
created on the Internet that we know today has been built on top of open source projects and open source
projects means that anybody can view the code.
Anybody can see the code of a program can inspected can modify it can enhance it in this way.
The idea is that by sharing this information with everybody we get everybody's input and we use the
collective mind to improve software.
Not only that but it also benefits everybody.
Right.
For example the most famous example of an open source project is Linux an operating system just like
Windows or Mac OS except it's built by everyday programmers and it's code that is completely open sourced.
Anybody can inspect the code add onto it and it's become so successful that most of the cloud that we
know of the servers usually run Linux a W S Google Cloud Microsoft Azure.
All of them use Linux.
Some of you might be running Linux right now as you watch this video so not only do you get to work
with other developers from around the world where you can build great projects but just working in teams
by learning how open source works well you don't have to create something as big as Linux.
You can create a project with a friend.
Something very small and simple it doesn't really matter.
The idea is of collaboration of openness and sharing code to hopefully improve on the collective knowledge.
Finally a lot of employers actually look upon open source contribution as a plus so if you're able to
put in your resumé that you're an open source contributor Well that's a good sign.
Plus it teaches you valuable skills at using get and get hub to work in teams.
If you're looking for job experience but you don't have a job contributing to open source is the perfect
way for you to learn how to work in teams and mimic a work like scenario.
This is a really important video and something I'm really excited about.
So let's show you how to make your first open source contribution improve your resume.
Learn some real life skills and have fun along the way.
Now we've actually created some open source projects for you for this course.
We have the 0 2 mastery repository here where we can see that we have about 64 projects open right now
with about 2000 contributors.
That's a lot of people in this numbers bound to increase.
Now this place was created as a practice ground for you a playground.
Nobody will yell at you if you break things you can contribute at silly things whatever you want.
It's a testing ground.
The idea is to have as much fun as possible and make it as easy as possible to contribute to open source
now within that organization.
We have a great community of administrator or management team that will help you with these open source
projects by the way.
Who are these administrators.
They're right here.
Ignore my name.
I help out as well but they do a lot of the heavy lifting and they are past students just like you that
have had a bit of experience.
Now most of them are working full time but they are now helping out the community by helping with our
open source projects are discord and generally just helping our community grow.
So shout out to them if you get a chance.
Say hi to them on this court.
They definitely do a lot for this community.
They're very active on discord and they really help maintain all of our open source projects.
So let's learn how to make our very first open source contribution.
I do want to note here that this isn't the only way for you to contribute to open source.
This is just a playground that we've created for you.
But once you contribute here you can go off and contribute to all the other open source projects all
over GitHub.
They can find you can contribute to projects like react and angular.
The world is your oyster or you can just stick to these as we actually have a ton of projects here that
are fun.
We have events going on like October fest.
Well we'll get to that shortly.
We definitely have a great community of developers and we can create some awesome projects together.
Now the way you want to get started is to first go to the start here guidelines
now in the start here guidelines and I'll link to this page you actually have a four step guide to get
started.
The first thing you want to do is to actually watch the guide started guideline a fellow student actually
created this guide for you to follow the steps that I'll mention in this video.
So you always have this as a reference.
So after this video definitely check out this document as a reference but otherwise once you've browsed
through the document is will make your first pull request.
So if you've already watched might get and get hub videos you should be all set.
Otherwise hopefully you're familiar with get and get out.
Now the first thing we want to do is to actually add our names to the contributors dot and define in
this project.
So if you go up you'll see that we have 8 contributors dot M.D. which stands for markdown file and if
I click on here you see that all the contributors that we have we have over a thousand contributors
and if you scroll down these are all their github names.
So your first task is to actually add your name to this list.
So how can we do this.
Well we can just clone this repository but a more recommended way of usually contributing to open source
is to fork the project fork essentially means copy over the entire project and put it on your own get
hub profile.
So if I click fork here and we see over here that you can select where you want to forth the project
and you want to select your profile so once we fork this project we make a copy of it.
It's like we own this repository now with our own version of the start here guidelines.
So once we have this we can clone this repository using SSA H or H2 G.P.S. whatever you prefer.
In my case I'll use SSA so that I don't have to use my password every time I can now say get clone and
clone this repository.
Now we can see these into start here guidelines and we can't open this up in our favorite text editor.
Now once here let's clear this.
We have the contributors file which we need to add our name to.
Now I can see here the contributors file is getting quite long because while we've had a lot of students
who are contributing to open source but at the very end.
Make sure you're at the very end here.
You want to add your own name.
Now here's the thing.
Right now we're on the master branch but I'm going to show you what a good practice is.
We have our forked project and we want to create a new branch to work off of instead of master by saying
get check out dash B to create a new branch and we want to name this branch in our case let's just name
it test.
If I hit enter you'll see that now I'm on a new branch called test and in this branch I can add my name
to this contributor list.
In your case you'll want to use your own GitHub profile.
So we're using markdown here which is a way a syntax to write and has some functionality.
For example if we go to the contributors list you'll notice that they are all clickable links.
So we essentially use the same notation we do a dash square brackets with your get hub user name and
then in the parentheses we just have the actual U.R.L. that you want to link to.
In our case the get hub user name that you have.
So you'll get hub user name here.
Get hub user name here.
Once we do that we can save this file.
Now go back to our terminal and say get status and we see here that yeah we just modified our contributors
dot DFA and if I do get def to see any changes that we've made we see that we've added this new line
so let's clear this.
We have our name all set up and we can now add this commit by saying get ad and dot for everything we'll
add everything and then get commit and we'll write a message that says added my name to contributor
list.
There we go.
So now it's time for us to push these changes.
Now if I do get push origin master well right now what that would mean is that we want to push to origin
and the origin is this start here.
Guideline which I fought so the origin is actually my version of the project and if I want to push to
master that is the main branch.
But we don't want to do that because ideally we want to be able to also change and add our name to the
original 0 2 mastery start here guideline because this is the main.
So what we can do is instead of master push to our test branch so we say get push origin test.
There we go.
Now if I go back here and go to my project and I refreshed I now have two branches the master branch
and also the test branch which I just updated.
So one way to do this is to click on new poll request
and you can add comments here like I've added my name to the list and you can tag some of our maintainers.
In my case I'll just tag myself if I do create pull request
I now have my poor request and notice here how my poor request is now at the 0 2 mastery star here guideline
so that if I go back to our star here guideline I see that I'm part of the pull request now right here
and because I've tagged one of the management teams so in this case it was myself.
Or we can tag any of the management team that we have now.
In this case I'm cheating because I also help manage this so I can just myself merge the poor request
most likely in your case you won't be able to merge it yourself.
But if I click merge and confirm.
There we go.
I've merged my project.
I've deleted the branch and the pull request is closed.
If I want I can even delete my own fork.
But for now let's keep it the way it is.
Let's check the start here guidelines and see if my name has been added to the list.
I scroll all the way down.
Hey check that out.
There's my name on the list.
So I've been added to the contributors list.
It was pretty easy right.
And the cool part is that now if I go to my profile I actually have zero to mastery as one of my organizations.
So if you're able to add yourself to the contributors list you can actually join the 0 2 mastery organization
and have this little icon appear on your get hub profile.
And lots of get tough profiles have organization.
So people usually have their workplace icon in here.
So just a nice little thing to have on your profile to show that you're involved in the programming
community
so we've just made a poor request which is step two.
And that was pretty fast right.
Finally the next step is to go join an actual project and start contributing the way we just learned
in our 0 2 mastery organization.
Now there's actually a guy that we provide for you to figure out what project you choose what's going
to be good for you.
We also have an hour discord.
A group projects section where we can look at some of the current projects that are happening or you
can just go to the 0 2 mastery organization and pick any of the repositories to contribute to.
Now in the next video we're going to contribute to one of these projects and show you a real life scenario
I'll see in that one.