Day 11 of My #30DaysOfTech Journey at TS Academy Today I learned about Git Branching and Merging — one of the most powerful features of Git. Branching allows developers to work on new features without affecting the main project. Instead of modifying the main code directly, you create a separate branch, work on it, and merge it back when it’s ready. Commands I practiced: 1. git branch → View branches 2. git branch feature1 → Create new branch 3. git checkout feature1 → Switch to branch 4. git switch feature1 → Modern way to switch 5. git merge feature1 → Merge branch into main Why branching is important in DevOps: Multiple team members can work simultaneously Reduces risk of breaking production code Supports CI/CD workflows Enables testing before deployment This is heavily used on platforms like GitHub, where teams collaborate through pull requests and code reviews. Today I understood something important: DevOps is about controlled change, not chaotic change. Branch → Test → Merge → Deploy. Slowly thinking like a real DevOps engineer #30daysOfTech #DevOps #Git #LearningWithTS #TechJourney
Mastering Git Branching and Merging at TS Academy
More Relevant Posts
-
🚀 DevOps Learning Journey - 🌿 Day 11 – Git Branching & Merging Today I learned one of the most important concepts in Git — Branching and Merging. Branching allows developers to work on new features or fixes without affecting the main codebase. 🔹 What is a Branch? A branch is a separate line of development. By default, Git has a main/master branch, and we can create new branches for features. 🔹 Why Branching is Important? ✔ Work on features independently ✔ Avoid breaking main code ✔ Enable parallel development ✔ Easy collaboration in teams 🔹 Git Commands I Practiced • git branch – List all branches • git branch feature – Create a new branch • git checkout feature – Switch to a branch • git checkout -b feature – Create & switch to branch • git merge feature – Merge branch into current branch 🔹 Example Workflow git branch feature git checkout feature # make changes git add . git commit -m "Added new feature" git checkout main git merge feature 🔹 Merge Concept Merging combines changes from one branch into another. Sometimes conflicts may occur, which need to be resolved manually. 📌 Hands-on: Created a feature branch, made changes, and merged it back to the main branch. Understanding branching is essential for working in real-world DevOps and development teams. #DevOps #Git #VersionControl #Branching #LearningJourney #ContinuousLearning
To view or add a comment, sign in
-
-
🚀 DevOps Learning Series Git Cherry-Pick — because sometimes you only want one slice of the pizza 🍕 Working with Git branches often feels like juggling timelines. But what if you need just one specific commit from another branch? That’s where git cherry-pick enters like a surgical tool. 🧠 What is Cherry-Pick? git cherry-pick lets you take a single commit from one branch and apply it to another branch without merging the entire branch. Instead of bringing the whole branch… you pick just the commit you want. 👉 Basic syntax : git cherry-pick Git simply says: : “Nice commit. I’ll copy that here.” 💡 Why we need Cherry-Pick • 🔧 Hotfixes A bug fix in develop needs to go to main immediately. • 🚑 Production emergencies One fix needs to reach production without merging unfinished features. • 🎯 Selective commits You only want one useful change, not the entire branch. • 🔁 Recover lost work Grab a commit from another branch or history. ⚠️ Reality Check Cherry-pick creates a new commit with the same changes, not the original commit itself. So history stays clean, but the commit gets a new ID. 🧠 Quick Example Fix exists in feature-branch: git log Copy that commit into main: git checkout main git cherry-pick a1b2c3d Boom 💥 The fix is now in main without merging the whole branch. 💡 TL;DR Merge → bring the whole branch Rebase → rewrite history Cherry-pick → steal one commit politely Small command. Huge lifesaver in production. #DevOps #Git #VersionControl #SoftwareEngineering #LearningInPublic #DeveloperTools #TechTips
To view or add a comment, sign in
-
-
🚀 #100DaysOfDevOps – Day 8 Today I practiced Git branching, merging, and revert operations, focusing on real-time development and production scenarios. 🔹 Git Revert (Safe Rollback) Used to undo a specific commit without removing history. ✔ Scenario: Reverting a faulty production deployment safely ✔ Scenario: Fixing bugs without affecting commit history Command: git revert <commit-id> 🔹 Git Branching (Parallel Development) Branches allow independent development without affecting main code. ✔ Scenario: Creating feature branches for new changes ✔ Scenario: Isolating bug fixes from production code Commands: git branch git branch feature-branch git checkout feature-branch git checkout -b feature-branch 🔹 Branch Management ✔ Scenario: Cleaning up unused branches after release ✔ Scenario: Renaming branches based on project needs Commands: git branch -m old-name new-name git branch -d branch-name git branch -D branch-name 🔹 Git Merge (Combining Changes) Used to merge code from one branch to another. ✔ Scenario: Merging feature branch into main branch after testing ✔ Scenario: Deploying finalized changes to production Command: git merge branch-name 💡 Branching and merging are core to team collaboration, CI/CD pipelines, and release management in DevOps. Learning how to manage code flow effectively across environments. 💪 #Git #DevOps #VersionControl #Branching #CloudEngineering #100DaysChallenge #ContinuousLearning
To view or add a comment, sign in
-
-
🚀 5 Essential Git Branching Strategies 1. Feature Branching: The classic approach. Create a dedicated branch for every new feature and delete it once merged. Perfect for keeping the main history clean. 2. GitFlow: Best for projects with scheduled release cycles. It uses dedicated branches for main, dev, features, releases, and hotfixes. Complex, but highly structured. 3. GitLab Flow: A middle ground that links branching to environments (e.g., staging, preprod). Great for when your code needs to pass through multiple validation gates. 4. GitHub Flow: Simple and agile. The main branch is always deployable. You branch off for a fix or feature, then merge back immediately after testing. Ideal for Continuous Delivery. 5. Trunk-Based Development: The speed demon's choice. Developers merge small, frequent updates into a single "trunk" (main). Large features are hidden behind feature flags to keep the build stable. Which one should you choose? • Small team/SaaS? GitHub Flow is your best friend. • Enterprise/Regulated industry? GitLab Flow or GitFlow offers the control you need. • High-velocity DevOps? Trunk-Based is the way to go. How does your team handle branching? Are you a GitFlow traditionalist or a Trunk-Based speedster? Let's discuss in the comments! 👇 #SoftwareEngineering #WebDevelopment #Git #DevOps #CodingTips #TechCommunity #Programming #VersionControl
To view or add a comment, sign in
-
-
🚀 Day 10 – DevOps 100 Days Challenge 🚀 Today, I deepened my understanding of advanced Git concepts, which are essential for managing code history, fixing mistakes, and working efficiently in real‑world projects. 📌 What I learned today in Git: Git Config – setting username, email, and global configurations Git Commit --amend – updating the last commit Git Reset – undoing changes and reset commit states .gitignore – ignoring unnecessary files and directories Git Reflog – tracking and recovering lost commits Git Cherry-pick – applying specific commits from one branch to another These concepts help handle mistakes confidently, maintain clean commit history, and improve collaboration in DevOps and CI/CD workflows. 🔧📦 Feeling more confident with Git internals and moving ahead to Day 11! 💪🚀 #DevOps #100DaysOfDevOps #Git #VersionControl #GitReflog #GitReset #GitCherryPick #LearningJourney #ContinuousLearning
To view or add a comment, sign in
-
Day 25 of #90DaysOfDevOps was all about leveling up my "Git Rescue" skills! 🛠️ We’ve all been in that spot where a commit goes sideways, and knowing how to handle it safely is a true superpower for any DevOps engineer. ⚡ The TL;DR on Undoing Mistakes: 🔹 git reset ⏩ The "Time Machine." It rewrites project history by moving the branch pointer backward. Critical Rule: Use this only for private, local work that hasn't been pushed yet. 🚫 Do not rewrite shared history! 🔹 git revert ⏪ The "Safety Net." It creates a new commit that performs the inverse of an existing one. Because it adds to the history rather than deleting it, this is the gold standard for undoing changes on shared, pushed branches. ✅ Branching Strategies: Managing Code at Scale 🏗️ I also dove into how top-tier engineering teams manage their codebase: ♦️ Trunk-Based Development: 🛤️ High-velocity merging to main. Perfect for teams practicing CI/CD who need to ship fast. ♦️GitHub Flow: 🎈 Simple, branch-based, and PR-driven. My go-to for SaaS products and quick iterations. ♦️GitFlow: 🏢 Highly structured, multi-branch workflow. Ideal for large, complex projects with rigid release schedules. 📚 Check out my full technical notes here: https://lnkd.in/g44eYvdQ #90DaysOfDevOps #DevOpsKaJosh #TrainWithShubham #Git #DevOps #VersionControl #SoftwareEngineering #CI_CD #CodingTips #LearningInPublic #TechCommunity
To view or add a comment, sign in
-
🚀 𝐃𝐚𝐲 35: 𝐕𝐞𝐫𝐬𝐢𝐨𝐧 𝐂𝐨𝐧𝐭𝐫𝐨𝐥 𝐈𝐧𝐭𝐫𝐨𝐝𝐮𝐜𝐭𝐢𝐨𝐧 Before starting today's learning update, a quick community note. Over the past month, I intentionally took a LinkedIn detox break — both from scrolling and content sharing. The goal was simple: • Focus deeply on learning • Reduce noise • Build stronger fundamentals Now I'm back to sharing my journey publicly again and continuing my Learn in Public goal. Starting today, I’m diving into DevOps fundamentals, beginning with one of the most important pillars of modern software development: ⚙ Version Control Systems (VCS) Imagine building software without version control. Developers would face problems like: ❌ Overwriting each other's code ❌ No history of changes ❌ No rollback if a bug appears ❌ Difficult collaboration This is where Version Control Systems help. A VCS allows developers to: ✔ Track code changes over time ✔ Maintain complete project history ✔ Collaborate safely with teams ✔ Experiment with new features using branches ✔ Rollback to previous stable versions Today, most engineering teams use Git, which works using a snapshot-based versioning system. Think of Git as a time machine for your codebase. Tomorrow I’ll break down how Git actually tracks changes internally. #DevOps #Git #VersionControl #LearnInPublic #SoftwareEngineering #100DaysOfLearning #100DaysOfLearning
To view or add a comment, sign in
-
-
🚀 #100DaysOfDevOps – Day 6 Today I practiced Git basics focusing on tracking, committing, and analyzing changes, simulating real development workflows. 🔹 Tracking & Committing Files ✔ Scenario: Tracking code/config changes before deployment ✔ Scenario: Maintaining version history for rollback Commands: git add file git commit -m "message" 🔹 Working with Multiple Files ✔ Scenario: Committing multiple configuration changes in one release Commands: git add . git commit -m "message" 🔹 Git Logs (History Tracking) ✔ Scenario: Debugging issues by checking recent changes ✔ Scenario: Understanding who changed what in the project Commands: git log git log --oneline git log -2 🔹 Git Show (Deep Analysis) ✔ Scenario: Inspecting exact code changes that caused an issue ✔ Scenario: Reviewing commit details during debugging Commands: git show <commit-id> git show <commit-id> --name-only 🔹 Git Config ✔ Setting up identity for commits Commands: git config user.name "username" git config user.email "email" 💡 Git plays a key role in code versioning, collaboration, and production debugging in DevOps workflows. Every commit tells a story — learning to read and manage it effectively. 💪 #Git #DevOps #CloudEngineering #VersionControl #100DaysChallenge #ContinuousLearning
To view or add a comment, sign in
-
-
My first post! Let's talk about the one tool that sits at the heart of every DevOps workflow: Git. 🧵 When I first started in DevOps, I thought Git was just "code backup." I used to zip folders with names like deploy_final_v2_FINAL.zip 😅 (please tell me I wasn't alone). If you're just starting your DevOps journey, don't let Git intimidate you. In our world, Git isn't just version control — it's the source of truth for everything: infrastructure, configuration, deployment pipelines, and application code. Here are 3 fundamentals that clicked for me: 1️⃣ Commit early, commit often — but make it meaningful. In DevOps, every commit can trigger a pipeline. Small, atomic commits mean faster feedback loops. Your CI/CD pipeline will thank you when it's not sitting through a 20-minute build just to find a typo at the end. 2️⃣ Treat infrastructure the same as application code. Your Terraform, Ansible, Kubernetes manifests — they all belong in Git. If it's not in Git, it doesn't exist. Period. This is the foundation of GitOps — your Git repo should be the single source of truth for both apps AND infrastructure. 3️⃣ Master the merge, but understand the strategy. git merge vs git rebase isn't just a preference — it's about maintaining a clean, auditable history. In DevOps, that history helps you trace exactly when and why infrastructure changed during an incident. Trust me, being able to pinpoint "which commit broke production" saves hours of debugging at 2 AM. 💡 For my fellow DevOps engineers: We all know the basics. But what's one Git command or practice you've baked into your CI/CD pipelines that saved your team during an outage? For me, it was git bisect — automating it in our pipeline to find exactly which commit introduced a performance regression. Absolute game-changer for root cause analysis. Drop your GitOps wisdom in the comments! Let's help the next generation of DevOps engineers level up. 👇 #git #devops #gitops #cicd #terraform #kubernetes #infrastructureascode #softwareengineering
To view or add a comment, sign in
-
-
Day 17 of My DevOps Learning Journey Today I explored some important Git collaboration concepts that are widely used in real-world DevOps workflows. 🔹 Git Merge Used to combine changes from one branch into another. Example:git merge feature-branch 🔹 Git Push Uploads local commits to a remote repository so other team members can access them. Example:git push origin main 🔹 Git Pull Fetches the latest changes from the remote repository and automatically merges them into the current branch. Example:git pull origin main 🔹 Git Fetch Downloads changes from the remote repository without merging them, allowing developers to review updates first. Example:git fetch origin 🔹 Merge Conflicts Occurs when two branches modify the same part of a file. Developers must manually resolve the conflict and complete the merge. 💡 Key Learning: Understanding Git workflows is essential for team collaboration, code integration, and maintaining a clean project history. Step by step, I’m building strong foundations in Git and DevOps practices. #DevOps #Git #VersionControl #LearningInPublic #DevOpsJourney #ContinuousLearning #Automation #CloudComputing #TechCommunity #frontlinesedutech #flm #frontlinesmedia
To view or add a comment, sign in
Explore related topics
- DevOps Principles and Practices
- How to Use Git for IT Professionals
- Importance of DEVOPS for Modern Enterprises
- DevOps Engineer Core Skills Guide
- Advantages of DEVOPS Integration
- Key Skills for a DEVOPS Career
- Change Management in DevOps
- How to Optimize DEVOPS Processes
- Best Practices for Merging Code in Teams
- Integrating DevOps Into Software Development
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development