13 Commits

18 changed files with 96 additions and 2 deletions

76
ASSIGNMENT-04-09-2025.md Normal file
View File

@@ -0,0 +1,76 @@
## Viewing File History
## 1. git log -- assignment.txt
![alt text](<git log-p--filename.png>)
## 2. git log -p -- assignment.txt
![alt text](<git log--filename.png>)
![alt text](<git log-p--filename1.png>)
## 3. git log --oneline -- assignment.txt
![alt text](<git log--oneline--filename.png>)
## How many commits modified this file?
3 commits
## What differences do you see when adding the -p option?
Shows detailed changes for each commit in the file.
## Viewing File History with Blame
## 1. git blame assignment.txt
![alt text](<git blame assignment.png>)
## 2. git blame -L 1,5 assignment.txt
![alt text](<git blame -L 1,5 assignment.png>)
## 3. git blame assignment.txt
![alt text](<git blame -e assignment.png>)
## Who changed each line of the file?
Renejit
## How does -L help when the file is large?
To view the history of specific lines in a file.
## What extra information does -e provide?
To get the email id of the user who made the chages in the file.
## Merging Branches
![alt text](<fast-forward merge-1.png>)
![alt text](<fast-forward merge-2.png>)
## Merge Conflict
![alt text](<add number in main and training branch.png>)
![alt text](<merge conflict.png>)
![alt text](<merge conflict1.png>)
## Did Git perform a fast-forward merge or a 3-way merge?
Perform fast-forward merge and merge conflict
## What does git log --graph --oneline --all show after the merge?
![alt text](<git log--graph--oneline--all.png>)
## git log --graph --oneline --all after Merge conflict
![alt text](<git log graph oneline after merge conflict.png>)

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

9
assignment.txt Normal file
View File

@@ -0,0 +1,9 @@
git log -- <filename> :
shows the commmit message for a specific file.
git log -p --<filename> :
shows line by line changes for each commmit in a specific file
git log --oneline --<filename> :
shows commit history in short form for the specific file

BIN
fast-forward merge-1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

BIN
fast-forward merge-2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

View File

@@ -1,2 +1,10 @@
hello 1
Hi 2
3
4
5
6
7
8
9
10

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

BIN
git blame -e assignment.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

BIN
git blame assignment.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 127 KiB

BIN
git log--filename.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
git log-p--filename.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

BIN
git log-p--filename1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

1
git-practice-Renejit Submodule

Submodule git-practice-Renejit added at 8ee5230729

BIN
merge conflict.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

BIN
merge conflict1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB