Basic steps to pushing your codes to GitHub.
let’s see how to communicate with our remote repository by using the “VS-Code” interface.
The first thing to do is to sign up and get a GitHub account or BitBucket, whichever one you fancy 😉.
GitHub: Where the world builds software
GitHub is where over 56 million developers shape the future of software, together. Contribute to the open source…
Install git locally.
Git comes with built-in GUI tools ( git-gui, gitk), but there are several third-party tools for users looking for a…
So let’s assume we have gone through the first requirements, next up create a repository on your git hub account, for practice sake let's call this git_tutorial.
- Click the + sign
- Click create repository
- Earlier we agreed to call it git_tutorial😁.
- Give your repository a beautiful description.
- Let's go public for now, till we have sensitive information we go private.
- check <Add a README file>, the description becomes the README file.
One step at a time. now let us clone this repository, yeaaa just copy the URL.
Open your vs-code, hopefully, you have already started using vs-code
- Click on the View tab there, select “command pallet”.
- Click on Git:clone, paste the “URL” from the GitHub.
- Select a folder where the repository stays.
Next up, we have our read me file showing, we need to create a new branch so that we don’t mess up the master/main branch.
when you click on that icon up there it shows you
- +create a new branch
- Click on create a new branch and create a new branch name.
It automatically checks out to the new branch, but you can still checkout to our branch with that same icon.
It’s time to add our files and commit to our local repository,
- Click on that branch like the icon to add files and write a commit message.
- Commit message should be in this format e.g “fix the login page”.
Now, let us push to our remote repository,
- Click there, the red circled one.
- Go to your git hub account.
Request a pull and write a good description.
let’s stop here for now and continue later on.
A quick recap with a picture;
- clone the remote repository to your local
- create a new branch
- add files and commit to the local repo
- push branch to the remote repo.
The above is very basic and useful, feel free to send any error you encountered to me.
thank you all………