My First GitHub Project: From a Local Folder to GitHub Using Git and SSH

2026年8月22日1 次浏览来源:Dev.to阅读原文

Introduction This article is a walk through of my first project where I pushed a local folder containing health data to Github using Git and SSH.

Tools used Github - This is an online service where you can store Git repositories and it makes it possible to share and collaborate on projects.

Git - This is a version control system that runs on your computer and keeps track of changes made to your project.

SSH (secure shell) - We use SSH when your computer needs a secure way to prove to Github that it is authorized to access your Github account and its repositories.

On windows Open Gitbash and check your current location Run Which stands for print working directory running asks which folder am I currently inside?

List files and folders around you Run Which shows the files and folders inside your current directory Move to the Desktop I created my project on the Desktop by running Where means Change Directory Create the project folder I named my project kenya-health-records and run Where means Make Directory or create new folder To confirm that the folder exists run and you should see Enter the project folder Run Then verify the project by running Create a proper project structure Here I created three project folders by running Then I created the README by running Which explains the entire project Adding the existing hospital dataset Since the hospital dataset was already on my computer under Downloads I copied the dataset directly from downloads to the data folder I had created inside the project.

To verify the dataset was copied I run And the outcome was kenya_health_records.csv Adding content to the README.md Since the README.md explains the project to anyone who opens the Github repository.

I started with where means print text # is a Markdown syntax for a large heading > Redirects the text into a file in this case to README.md Then I added the project overview, tools used, and project challenges.

To check my README I run Which displayed the contents in the README including the tittle, project overview, tools used and project challenges.

Initializing the project with Git Run Where means initialize this directory as a Git repository.

To check the project status Run Where this command is asking Git what is happening to the project.

Because this was a new repository Git showed the files as untracked Then run Which stages the project from the current directory Then check again Create the first commit Run where - creates a saved Git checkpoint. -m - means message. "Add kenya hospital project" is the commit message that explains what was saved.

Short commit history To get a shorter project history Run Check the current branch Run which returns *master rename it by running then run and it changed to *main Create Github repository Open Github on browser and create a new repository and name it as kenya health project and add a brief description of the repository and choose it s a public repository and create the repository.

After creating the repository Github displays connection options select SSH and git hub will givean adress which is [email protected]:karianjahi8/kenya-health-records.git Conecting the local project to Github Return to the gitbash terminal then run Where remote is another Git repository your local repository can communicate with. add is a new remote connection. origin is the conventional nickname for the main remote repository.

Push the prioject on Github Run Where git push sends committed changes from my computer to the remote repository. -u sets an upstream relationship origin The nickname of the Github repository main The branch being uploaded Verify project on github Return to your github browser and refresh the page and you will see your project listed.

Conclusion Getting a project onto GitHub for the first time involves two separate concerns Git, which tracks your project's history locally, and SSH, which securely proves your identity to GitHub so it'll accept your pushes.

分享
Baike.dev

baike.dev helps you discover great languages, frameworks, databases, DevOps and cloud-native tools.

Quick links

About

Contribute

Found a great developer tool? Share it with the community.

Submit a tool
© 2026 baike.dev Developer EncyclopediaUpdated daily · Discover great developer tools