Git Commands:
git init: Initialize a new Git repository in the current directory.
git clone [repository_url]: Clone a remote repository to your local machine.
git add [file]: Add a file to the staging area.
git commit -m "Commit message": Commit the changes in the staging area with a descriptive message.
git status: Check the status of your repository and see which files have changed.
git diff: Show the differences between your working directory and the staging area.
git branch: List all branches in your repository.
git branch [branch_name]: Create a new branch.
git checkout [branch_name]: Switch to a different branch.
git merge [branch_name]: Merge changes from a different branch into the current branch.
git pull: Fetch and merge changes from a remote repository to your local repository.
git push: Push your local changes to a remote repository.
git log: View the commit history.
GitHub Commands:
git remote add origin [repository_url]: Connect your local repository to a remote repository on GitHub.
git push -u origin [branch_name]: Push a branch to the remote repository for the first time.
git pull origin [branch_name]: Fetch and merge changes from the remote repository to your local repository.
git clone [repository_url]: Clone a remote repository to your local machine.
git fork: Create a copy of a repository on your GitHub account.
git pull-request: Create a pull request to suggest changes to a repository.
git merge [branch_name]: Merge changes from a different branch into the current branch.
git branch -d [branch_name]: Delete a branch.
These commands should help you get started with Git and GitHub. Remember to refer to the official documentation for more detailed information on each command and its options.