Welcome to the setup guide for the new-project
repository. This document will walk you through the process of creating a new Git repository, setting up a development branch, and merging changes back to the main branch.
- Git installed on your machine. Download Git
- A GitHub account. Sign up for GitHub
- Sign in to your GitHub account.
- Navigate to the Repositories tab.
- Click the
New
button. - Enter
new-project
as the repository name. - Choose the visibility for your repository (Public or Private).
- Click
Create repository
.
Open a terminal or command prompt and run the following command, replacing YOUR_USERNAME
with your GitHub username:
git clone https://github.com/YOUR_USERNAME/new-project.git
cd new-project
Create a new branch named development
:
git checkout -b development
- Create a
README.md
file in the root of your project directory. - Open the
README.md
file with a text editor and add your project information. - Save your changes.
Commit your changes with a meaningful message:
git add README.md
git commit -m "Add initial README.md"
Push your changes to the development
branch on GitHub:
git push -u origin development
- Switch to the
main
branch:
git checkout main
- Merge the
development
branch into themain
branch:
git merge development
- Push the changes to GitHub:
git push origin main
Congratulations! You have successfully set up a new Git repository for new-project
, created a development branch, and merged changes into the main branch. You're now ready to continue working on your project.