GitHub Repository
Last updated
Last updated
Introduction to GitHub:
Create GitHub account, understand repositories, forks, and pull requests.
Explore GitHub interface: issues, branches, and pull requests.
Activity: Follow these steps to create a new repository on GitHub, clone it locally, and push updates:
Create a New Repository on GitHub:
Go to and sign in to your account.
Click the "+" icon in the top right corner and select "New repository."
Enter a repository name (e.g., MyGitHubRepo
) and an optional description.
Choose Public or Private based on your preference.
Do NOT initialize with a README (this will avoid conflicts when pushing from your local repository).
Click "Create repository."
Clone the Repository Locally:
Copy the repository's HTTPS URL by clicking the green "Code" button and selecting "Copy."
Open Terminal (Mac/Linux) or Command Prompt (Windows).
Navigate to the directory where you want to clone the repository: $cd
path/to/your/folder
Clone the repository: $git clone https://github.com/
YourUsername
/MyGitHubRepo.git
Move into the cloned directory: $cd MyGitHubRepo
Push Updates to GitHub:
Create a new file: $echo "GitHub setup complete!" > setup.txt
Stage the file: $git add setup.txt
Commit the file: $git commit -m "Add setup.txt"
Push the changes to GitHub: $git push origin main
Verify on GitHub:
Go back to your GitHub repository in the browser.
Refresh the page to see the new setup.txt
file in your repository.