Git - a version control system
- Git is a distributed version control system widely used for tracking changes in source code during software development.
- It's designed to handle projects of all sizes, from small to large-scale, with speed and efficiency.
Common Git Commands:
git init: Initializes a new Git repository in the current directory.
git clone [repository_url]: Clones an existing Git repository from a remote server to your local machine.
git add [file(s)]: Adds file(s) to the staging area for the next commit.
git commit -m "Commit message": Commits staged changes to the local repository with a descriptive message.
git status: Displays the current state of the working directory and the staging area.
git diff: Shows the differences between the working directory and the staging area.
git log: Displays the commit history of the repository.
git branch: Lists all branches in the repository.
git checkout [branch_name]: Switches to the specified branch.
git merge [branch_name]: Merges changes from the specified branch into the current branch.
git pull: Fetches changes from the remote repository and merges them into the current branch.
git push: Pushes local commits to the remote repository.
git remote: Manages connections to remote repositories.