Master technical and career interviews with structured answers—short definition, real examples, pitfalls, and how to answer in 60–90 seconds.
Answer: ccess them in workflows: env: WS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintaina…
Answer: <<<<<<< HEAD your code ======= incoming code >>>>>>> branch What interviewers expect A clear definition tied to Ve…
My preferred strategy depends on the project type and team size: For large enterprise projects with planned releases → I prefer Git Flow. Branches: main, develop, feature/*, release/*, hotfix/* Benefits: Organized releas…
Answer: Store tokens (like AWS_ACCESS_KEY, DOCKER_TOKEN) in → Settings > Secrets and variables > Actions Access them in workflows: env: AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} What interviewers…
Answer: git config --global user.signingkey <key-id> git config --global commit.gpgsign true What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (perf…
Integration means connecting your Git repository to your CI/CD system so every push, pull request, or tag triggers an automated build, test, and deploy pipeline. ✅ Jenkins Integration Install the Git plugin in Jenkins. C…
git cherry-pick <commit-hash> What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you would and wo…
git switch -c hotfix/save-work What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you would and would not use i…
git checkout -b feature/login abc1234 What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you would and would no…
Answer: dashboard). → This prevents misuse. Remove the secret from code: git rm --cached path/to/file git commit -m "Remove sensitive file" What interviewers expect A clear definition tied to Version Control in Git &…
Answer: Accidentally pushing secrets (API keys, passwords, tokens) is serious — even if you delete them, they may still exist in commit history. Steps to fix it: What interviewers expect A clear definition tied to Versio…
git merge origin/main What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you would and would not use it in prod…
After initializing a Git repo locally (git init), you can connect it to a remote repository (like one on GitHub) using: git remote add origin Then push your code: git push -u origin main Explanation: origin is just a nic…
Answer: Mark the conflicting sections in your file: <<<<<<< HEAD your current branch code ======= incoming branch code >>>>>>&…
Answer: <<<<<<< HEAD current branch code ======= incoming branch code >>>>>>> feature/contact-form What interviewers expec…
git checkout wrong-branch git reset --hard HEAD~2 What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you would…
origin – The main remote repository you cloned or own. upstream – Usually refers to the original repository that your fork came from. Example: If you fork a popular open-source project: Your fork on GitHub = origin The o…
Git is the tool used to track changes in your code locally (on your computer), whereas GitHub is a platform that hosts Git repositories online, enabling collaboration and sharing. GitHub allows teams to work on Git-based…
Answer: including its entire history, allowing for offline work and decentralized collaboration. What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, m…
Answer: GitHub Actions tokens (GITHUB_TOKEN) should have minimal scopes: permissions: contents: read deployments: write packages: read What interviewers expect A clear definition tied to Version Control in Git & GitH…
git commit -S -m "fix: secure login flow" What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you would and woul…
Semantic Versioning (SemVer) follows the format: MAJOR.MINOR.PATCH Example: v2.3.1 It’s based on changes — breaking changes bump MAJOR, new features bump MINOR, and bug fixes bump PATCH. utomation tools: semantic-release…
Clean and optimize the repository: git gc --aggressive What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When you w…
git add . git merge --continue # or git rebase --continue What interviewers expect A clear definition tied to Version Control in Git & GitHub projects Trade-offs (performance, maintainability, security, cost) When yo…
Answer: Example: You checked out an old commit for debugging: git checkout a1b2c3d Then made edits and committed — but forgot to make a new branch. Create one before switching back, or you’ll lose that work. What intervi…
Git & GitHub Developer Essentials · Version Control
Answer: ccess them in workflows: env: WS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: <<<<<<< HEAD your code ======= incoming code >>>>>>> branch
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
My preferred strategy depends on the project type and team size:
fixes.
Development.
frequently (often daily).
Real-world example:
t my last company, we used Trunk-Based Development for a SaaS platform — it reduced
merge conflicts and allowed fast continuous deployment.
Git & GitHub Developer Essentials · Version Control
Answer: Store tokens (like AWS_ACCESS_KEY, DOCKER_TOKEN) in → Settings > Secrets and variables > Actions Access them in workflows: env: AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: git config --global user.signingkey <key-id> git config --global commit.gpgsign true
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Integration means connecting your Git repository to your CI/CD system so every
push, pull request, or tag triggers an automated build, test, and deploy pipeline.
✅ Jenkins Integration
Create a new pipeline job and link it to your Git repository:
pipeline {
gent any
stages {
stage('Checkout') {
steps {
git branch: 'main', url:
}
}
stage('Build') {
steps {
sh 'npm install'
sh 'npm test'
}
}
}
}
✅ GitLab CI/CD
GitLab CI is built-in — simply create .gitlab-ci.yml:
stages:
test:
script:
deploy:
script:
only:
Every push triggers this pipeline automatically.
✅ GitHub Actions
GitHub has its own YAML-based workflows:
name: Node CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
It runs directly in GitHub without needing extra setup.
Real-world example:
Your team pushes code to GitHub → GitHub Actions automatically runs tests →
Jenkins (or GitLab CI) deploys to a staging environment → Approval required for
production deploy.
Git & GitHub Developer Essentials · Version Control
git cherry-pick <commit-hash>
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
git switch -c hotfix/save-work
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
git checkout -b feature/login abc1234
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: dashboard). → This prevents misuse. Remove the secret from code: git rm --cached path/to/file git commit -m "Remove sensitive file"
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: Accidentally pushing secrets (API keys, passwords, tokens) is serious — even if you delete them, they may still exist in commit history. Steps to fix it:
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
git merge origin/main
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
After initializing a Git repo locally (git init), you can connect it to a remote repository
(like one on GitHub) using:
git remote add origin
Then push your code:
git push -u origin main
Explanation:
(git push alone works after that).
Real-world example:
You create a local portfolio website and later decide to host it on GitHub. You connect your
local repo to the remote one using git remote add origin so both stay in sync.
Git & GitHub Developer Essentials · Version Control
Answer: Mark the conflicting sections in your file: <<<<<<< HEAD your current branch code ======= incoming branch code >>>>>>> feature/new-ui
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: <<<<<<< HEAD current branch code ======= incoming branch code >>>>>>> feature/contact-form
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
git checkout wrong-branch git reset --hard HEAD~2
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Example:
If you fork a popular open-source project:
Commands to set both:
git remote add origin
git remote add upstream
Why it matters:
This setup lets you pull new changes from the main project (upstream) while pushing your
changes to your fork (origin).
Git & GitHub Developer Essentials · Version Control
Git is the tool used to track changes in your code locally (on your computer), whereas
GitHub is a platform that hosts Git repositories online, enabling collaboration and sharing.
GitHub allows teams to work on Git-based projects in a central location, review code, and
manage issues and pull requests.
Real-World Example:
You use Git to make changes to your website’s code locally. Once you're happy with your
changes, you push them to GitHub so your team can see and review the updates. GitHub is
essentially a cloud service that works on top of Git.
Git & GitHub Developer Essentials · Version Control
Answer: including its entire history, allowing for offline work and decentralized collaboration.
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: GitHub Actions tokens (GITHUB_TOKEN) should have minimal scopes: permissions: contents: read deployments: write packages: read
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
git commit -S -m "fix: secure login flow"
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Semantic Versioning (SemVer) follows the format:
MAJOR.MINOR.PATCH
Example: v2.3.1
It’s based on changes — breaking changes bump MAJOR, new features bump
MINOR, and bug fixes bump PATCH.
utomation tools:
Example using semantic-release:
npm install semantic-release @semantic-release/git
@semantic-release/github -D
Create a .releaserc.json:
{
"branches": ["main"],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
"@semantic-release/github",
"@semantic-release/git"
}
What it does:
Example output:
chore(release): 1.3.0
Git & GitHub Developer Essentials · Version Control
Clean and optimize the repository: git gc --aggressive
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
git add . git merge --continue # or git rebase --continue
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.
Git & GitHub Developer Essentials · Version Control
Answer: Example: You checked out an old commit for debugging: git checkout a1b2c3d Then made edits and committed — but forgot to make a new branch. Create one before switching back, or you’ll lose that work.
In a production Git & GitHub application, teams apply this when handling user-facing features or integration boundaries. For example, you might use it during a sprint where reliability and observability matter—logging metrics, validating edge cases, and documenting the decision in an ADR so future developers understand why the approach was chosen.
Tip: Practice aloud on Toolliyo mock interview or the Interview Q&A section before your real interview.