-
Notifications
You must be signed in to change notification settings - Fork 101
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added Source Code of Git & GitHub Video Docs
- Loading branch information
Showing
2 changed files
with
5,637 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,6 +39,162 @@ Want to improve this page?. Raise a issue on [@github](https://github.com/Manish | |
👨💻📝 Now that you have completed the JavaScript tutorial video and reviewed the JavaScript cheat sheet, it's time to put your knowledge into practice by completing the JavaScript assignments. 🚀 | ||
</Callout> | ||
|
||
|
||
## Notes | ||
|
||
### Configure Git settings. | ||
|
||
```bash | ||
git config | ||
``` | ||
|
||
### Set name. | ||
|
||
```bash | ||
# Set your name for Git. | ||
git config --global user.name "Your Name" | ||
``` | ||
|
||
### Set email. | ||
|
||
```bash | ||
# Set your email for Git. | ||
git config --global user.email "[email protected]" | ||
``` | ||
|
||
### Enable color. | ||
|
||
```bash | ||
# Enable color output. | ||
git config --global color.ui true | ||
``` | ||
|
||
### Initialize a repository. | ||
|
||
```bash | ||
# Initialize a new Git repository. | ||
git init | ||
``` | ||
|
||
### Clone a repository. | ||
|
||
```bash | ||
# Clone an existing repository to your local machine.[either using https or SSH(when you have linked github with your computer using SSH keys) link] | ||
git clone <repository url> | ||
``` | ||
|
||
### Show status. | ||
|
||
```bash | ||
# Show the status of your working directory and staging area. | ||
git status | ||
``` | ||
|
||
### Add file. | ||
|
||
```bash | ||
# Add a file to the staging area. | ||
git add <file> | ||
``` | ||
|
||
### Commit changes. | ||
|
||
```bash | ||
# Commit changes in the staging area with a message. | ||
git commit -m "Commit message" | ||
``` | ||
|
||
### Show branches. | ||
|
||
```bash | ||
# Show a list of all branches in the repository.[your current working branch will be green coloured with * mark before it]. | ||
git branch | ||
``` | ||
|
||
### Create new branch. | ||
|
||
```bash | ||
# Create a new branch with the given name. | ||
git branch <branch name> | ||
``` | ||
|
||
### Switch branch. | ||
|
||
```bash | ||
# Switch to the branch with the given name. | ||
git checkout <branch name> | ||
``` | ||
|
||
### Merge changes. | ||
|
||
```bash | ||
# Merge changes from the specified branch into the current branch. | ||
git merge <branch name> | ||
``` | ||
|
||
### Show remote repositories. | ||
|
||
```bash | ||
# Show a list of all remote repositories. | ||
git remote -v | ||
``` | ||
|
||
### Add remote repository. | ||
|
||
```bash | ||
# Add a new remote repository. | ||
git remote add <remote name> <remote url> | ||
``` | ||
|
||
### Push changes. | ||
|
||
```bash | ||
# Push changes to the remote repository. | ||
git push <remote name> <branch name> | ||
``` | ||
|
||
### Pull changes. | ||
|
||
```bash | ||
# Pull changes from the remote repository. | ||
git pull <remote name> <branch name> | ||
``` | ||
|
||
### Show log. | ||
|
||
```bash | ||
# Show a log of all commits in the repository. | ||
git log | ||
``` | ||
|
||
### Show diff. | ||
|
||
```bash | ||
# Show a diff of all changes made since the last commit. | ||
git diff | ||
``` | ||
|
||
### Stash. | ||
|
||
```bash | ||
# Temporarily save changes without committing them. | ||
git stash | ||
``` | ||
|
||
### Reset. | ||
|
||
```bash | ||
# Unstage changes in the staging area. | ||
git reset | ||
``` | ||
|
||
### Undo changes. | ||
|
||
```bash | ||
# Undo changes made in a specific commit. | ||
git revert <commit hash> | ||
``` | ||
|
||
</TabsContent> | ||
|
||
<TabsContent value="assignment"> | ||
|
Oops, something went wrong.