Tech Thursday Assignment - 16-08-2025 #1
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Git Assignment - 16-08-2025
Create Repository in Organization
Assignment:
git-practice-<your_name>).GIT_ASSIGNMENT.mdwith a screenshot showing the repo inside the organization.1. What is Git and Version Control
Assignment:
2. Installing Git & Configuring User Info
Assignment:
Install Git (if not already installed).
Run:
Verify with:
3. Initializing a Repository
Assignment:
Create a new folder
git-practice-<<your_name>>.Inside, run:
Verify that a
.gitfolder is created.Run
git statusand note the message (it should say “No commits yet”).4. Working Directory, Staging, and Commits
Assignment:
In
git-practice-<<your_name>>, create a filenotes.txt.Run:
Observe which area (untracked → staged → committed) the file is in as you do:
Write down how the status changed after each command.
5. Adding & Committing Files
Assignment:
todo.txt.todo.txt, then commit the change again.git log --onelineto see both commits.6. Viewing Commit Logs & Diffs
Assignment:
Run:
Edit
notes.txtand check the changes withgit diffbefore staging.Stage and commit, then run
git diff commit1 commit2to see what changed between commits.7. Creating & Switching Branches
Assignment:
Create a branch
feature/feature-1:Add a line to
notes.txtand commit it.Switch back to
main:Observe how the file content changes.
8. Cloning a Remote Repository
Assignment:
Go to Git Comorin and verify your repo in Git-Training-Hub exists.
Run:
Verify by listing files inside
cloned-repo.9. Adding & Managing Remotes
Assignment:
In your original
git-practice-<<your_name>>repo, add a remote:Verify the remote shows correctly.
10. Pushing & Pulling Changes
Assignment:
Push local commits to Git Comorin:
Edit a file directly on Git Comorin and commit it there.
In your local repo, run:
Verify that the local file updates.
11. Ignoring Files with .gitignore
Assignment:
In your repo, create a file
secret.txt.Create
.gitignoreand add:Run
git status→ confirmsecret.txtis ignored.Commit the
.gitignorefile.Final Assignment Summary
.gitignorefile to exclude something.GIT_ASSIGNMENT.mdwith screenshots of key commands and the repository inside the organization.