Day 7/90: A Full Week of DevOps – Merging, Conflicts, and Strategy! 🚀🔥 One week down, consistency maintained! Today’s session with HeyDevops and Praveen Singampalli was a deep dive into the reality of team collaboration: what happens when code and ideas collide. Key Learnings from Day 7: Git Fetch vs. Git Pull: 📥 Learned the critical difference. git fetch is like a "preview mode"—it downloads new data from a remote repo so you can see it without it affecting your current working files. git pull, on the other hand, downloads AND integrates that data immediately. The Dreaded "Merge Conflict": ⚠️ I learned that a conflict happens when two people edit the same lines of the same file in different branches of the same repo. Git stops the merge and asks us to decide which code stays. It's not an error; it's a safety feature! Branching Strategies (The Roadmap): 🌿 We explored how professional teams organize their work: Feature Branching: Keeping every new feature in its own isolated branch until it’s tested and validated. Task Branching: Implementing specific tasks on separate branches to keep the workflow clean. Release Branching: Creating a dedicated space to finalize a new release cycle where only bug fixes are allowed—no new features! Pro Commands: 🛠️ Mastered git merge --abort to safely back out of a messy conflict, and git stash to temporarily "hide" my uncommitted changes so I can switch tasks quickly without losing work. My Takeaway: Managing a codebase isn't just about writing code; it's about managing people and their contributions. These branching strategies are what keep massive projects from turning into chaos. #DevOps #Git #SoftwareEngineering #CareerTransition #LearningInPublic #HeyDevOps #PraveenSingampalli #Consistency
DevOps Day 7: Git Merge Conflicts and Branching Strategies
More Relevant Posts
-
🚀 #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
-
-
🚀 #100DaysOfDevOps – Day 7 Today I explored advanced Git operations for commit history management and recovery, focusing on real-time development and troubleshooting scenarios. 🔹 Git Log (History Analysis) Used to track changes and understand commit history. ✔ Scenario: Debugging issues by identifying recent changes ✔ Scenario: Tracking who made specific changes in the codebase Commands: git log --oneline git log -3 git log --graph --oneline --all 🔹 Git Amend (Modify Last Commit) Used to update the most recent commit. ✔ Scenario: Fixing incorrect commit messages ✔ Scenario: Adding missed changes to the latest commit Commands: git commit --amend -m "message" git commit --amend --no-edit 🔹 Git Reset (Undo Changes) Used to move back to previous commits. ✔ Scenario: Removing unwanted commits before pushing to remote ✔ Scenario: Fixing mistakes in local commits Commands: git reset --soft HEAD~1 git reset --hard HEAD~1 🔹 Git Revert (Safe Undo) Used to undo changes without deleting history. ✔ Scenario: Reverting production issues safely ✔ Scenario: Maintaining audit/history while fixing bugs Command: git revert <commit-id> 🔹 Git Ignore (.gitignore) Used to exclude unnecessary files from tracking. ✔ Scenario: Ignoring log files, build artifacts, secrets ✔ Scenario: Preventing unwanted files from being pushed to repo 💡 Understanding these commands is crucial for code recovery, debugging, and maintaining clean commit history in real DevOps workflows. Not just writing code — managing its history effectively. 💪 #Git #DevOps #VersionControl #CloudEngineering #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
-
-
DevOps Isn’t Just for Developers If you think DevOps means Git, scripts, or pipelines, you’re missing the bigger picture. It’s really about team habits: -Can you trust what’s being deployed? -Can anyone follow what changed and why? -Can you fix problems fast, without guessing? You don’t need to be technical to start. Even small changes like tracking your metadata versions or reviewing what’s going out can make a big difference. That’s why we built Serpent to work for everyone, not just devs. You don’t need to learn Git first. You don’t need to build complex flows. Just start working with more clarity. And if you’re curious, we’ll show you how it works. https://lnkd.in/dKCsCgju
To view or add a comment, sign in
-
-
Most teams think CI/CD is enough… But they’re still fighting deployments, drift, and production surprises. That’s where GitOps changes the game. Instead of scripts, manual steps, and hidden configs 👉 Your entire system is driven by Git Here’s what that actually means: • Git becomes the single source of truth • Every change goes through pull requests and review • Deployments are automated and predictable • Infrastructure always matches what’s defined in Git • Rollbacks are simple and version-controlled No more “it works on my machine” No more guessing what changed in production Just clean, auditable, and reliable deployments. How GitOps works (simple flow): Push code or config changes to Git Create a pull request for review CI/CD builds and validates changes Git triggers deployment automatically System syncs to match the desired state That last step is the key. Instead of pushing changes blindly, your system continuously corrects itself. Why teams are adopting GitOps: • Faster releases • Better collaboration between Dev and Ops • Stronger security and audit trails • Reduced human error • Lower operational cost GitOps is not just another tool. It’s a shift in how you think about deployments. And once you adopt it, going back feels chaotic. Are you using GitOps in your workflow yet? #DevOps #GitOps #CloudComputing #Kubernetes #CICD #InfrastructureAsCode #SRE #Automation
To view or add a comment, sign in
-
-
❓ What Git branching strategies do you use in projects? Here are the 3 most common Git models used in real projects. ✅ Git Branching Strategies (Git Flow / GitHub Flow / Trunk Based) 🚀 Git Flow Model This is one of the most structured branching strategies used in enterprise projects. Long-lived branches: main → Production code develop → Integration branch where all development happens Short-lived branches: feature/ → New feature development release/ → Preparing code for production release bugfix/ → Fix issues found during testing hotfix/ → Emergency production fixes Typical Workflow 1️⃣ Create feature branch from develop develop → feature/login 2️⃣ After development, raise Pull Request to develop. 3️⃣ Code gets deployed to Dev environment. 4️⃣ When features are stable, create a release branch develop → release/v1.0 5️⃣ Deploy release branch to QA / UAT for testing. 6️⃣ If bugs appear: release → bugfix branch 7️⃣ Once everything is fixed: Merge release → main (Production) Tag the release. 8️⃣ Merge changes back to develop. 👉 Production Emergency If a production issue occurs: main → hotfix branch Fix the issue → merge back to main and develop. 🚀 GitHub Flow Model (Feature Branching) This is a simpler model used by many modern teams. Branches: main feature branches Workflow 1️⃣ Create a branch from main main → feature/payment-api 2️⃣ Push code. 3️⃣ Create Pull Request. 4️⃣ Code review + CI checks. 5️⃣ Merge to main. 6️⃣ Deploy to production. ✔ Simple ✔ Fast releases ✔ Ideal for CI/CD environments 🚀 Trunk-Based Development Model Very popular in high-speed DevOps teams like Google. Branches main (trunk) Developers create very short-lived branches or commit directly to main. Features are controlled using Feature Flags. ✔ Faster integration ✔ Avoids long branch conflicts ✔ Works best with strong CI/CD pipelines #DevOps #AWS #DevOpsEngineer #AWSDevOps #CI_CD #Git #CloudComputing #TechInterview #DevOpsInterview #LearningInPublic
To view or add a comment, sign in
-
🚀 DevOps Day 21 — Git Branching & DevOps Workflow (Part 3) After fixing networking issues, I moved into real Git workflows. This is where Git becomes powerful. SSH vs HTTPS Git Connections I explored both methods: SSH Method git@github.com:nixhal33/DevOps-Mastery.git Advantages: ✔ No repeated authentication ✔ Secure ✔ DevOps-friendly HTTPS Method (Token Based) git clone https://@github.com/repo.git Steps: • Create Classic Token • Clone repo • Push changes But SSH felt more DevOps-aligned. Git Commands I Practiced ✔ git status ✔ git diff ✔ git add ✔ git commit ✔ git push ✔ git restore ✔ git revert HEAD These commands helped me: • Track changes • Revert mistakes • Monitor code differences Git Branching (Most Important Learning) Production branch: main Development branch: git checkout -b dev Workflow: Create dev branch Make changes Push to dev Merge to main Merge Conflict Practice I intentionally: • Edited files in two branches • Created merge conflict • Resolved manually • Merged successfully This was real-world Git learning. Final DevOps Insight My instructor shared something interesting: DevOps Engineers don't use Git as heavily as developers… But Git is critical for: ✔ CI/CD pipelines ✔ Automation workflows ✔ Infrastructure versioning And now I'm ready for: 🚀 Next Topic: Docker From IaC → Version Control → Containers The DevOps journey continues. you can checkout my github repo using this link: https://lnkd.in/gjw9Fuxe #DevOps #Git #GitHub #Automation #CI_CD #InfrastructureAsCode #DockerJourney #LearningInPublic
To view or add a comment, sign in
-
-
🚨 Your Git branching strategy might be slowing your team down. I've watched dev teams spend weeks debating Git workflows… Meanwhile their competitors are shipping features twice as fast. The real question isn't: "Which Git strategy is the best?" The real question is: "Which strategy fits how MY team actually works?" ⚠️ What usually kills engineering velocity: → Using GitFlow for a 3-person startup that deploys daily → Forcing Trunk-Based on teams that require QA sign-off → Copying what Google does when you're not Google → Choosing complexity because it looks more professional ✅ Match the strategy to your reality: 1️⃣ GitHub Flow — Fast & Simple Main branch always deployable Branch → test → merge → ship Best for: SaaS teams, startups, continuous delivery 2️⃣ GitFlow — Structured Releases Separate branches for dev, release, hotfix Best for: enterprise teams, scheduled releases, regulated environments 3️⃣ GitLab Flow — Environment Driven Branches mapped to staging / preprod / production Best for: teams with validation gates or compliance checks 4️⃣ Trunk-Based Development — Maximum Speed Small frequent merges to main Feature flags hide incomplete work Best for: mature DevOps teams with strong CI/CD 5️⃣ Feature Branching — The Baseline One branch per feature Merge when done Best for: teams still defining their workflow 🎯 The real rule: Match your branching strategy to your deployment frequency. Deploy 10 times a day? → Trunk-Based or GitHub Flow Deploy once a month? → GitFlow gives control Deploy after compliance approval? → GitLab Flow The best Git strategy is the one your team can follow without holding meetings about the strategy. 💬 What branching strategy does your team use — and why? #SoftwareEngineering #Git #DevOps #CodingTips #TechLeadership #GitFlow #CICD #DeveloperTools #EngineeringCulture #BestPractices
To view or add a comment, sign in
-
-
Git MERGE vs REBASE Do you know the philosophy behind them? After reviewing documentation from Atlassian, DataCamp, and multiple engineering teams, here's a structured breakdown of when and why each strategy matters. The Core Distinction: Both commands solve the same problem: integrating changes from one branch into another. But they do it with fundamentally different philosophies. Git Merge is a non-destructive operation. The existing branches are not changed in any way, it creates a new "merge commit" that ties together the histories of both branches. Git Rebase, on the other hand, fundamentally rewrites your commit history by taking commits from one branch and replaying them on top of another branch, creating new commits with new SHA hashes, effectively creating new commits that contain the same changes but with different parent relationships. What This Means in Practice? Git Merge: - Preserves the complete, unaltered history of your project - Creates an explicit merge commit a clear marker of integration - Ideal for integrating into shared, long-lived branches - Safer for collaboration, but can produce a non-linear graph at scale Git Rebase: - Produces a perfectly linear project history - Eliminates extraneous merge commits from the log - Works exceptionally well for private branches where you're the only developer making changes - Powerful, but requires deliberate care The Hybrid Workflow: Best of Both Worlds Many engineering teams have converged on a pragmatic hybrid approach: A popular and effective workflow is to use rebase locally to clean up your own work, and then merge it into the shared branch. This gives you the best of both worlds: a clean feature history combined with a merge commit that signals the integration of a complete feature. The choice between merge and rebase isn't about one being inherently "better", it's about aligning with your team's workflow, project goals, and desired history representation. Understanding why each strategy exists, not just how to use it, is what separates engineers who write clean, maintainable codebases from those who don't. #Git #SoftwareEngineering #VersionControl #DevOps #TechLeadership #EngineeringBestPractices #DataDriven
To view or add a comment, sign in
-
-
Day 3 — Git and GitHub for DevOps As part of my daily DevOps posts, today I’m sharing one of the most important foundations in modern software delivery: Git and GitHub. Git is the version control system that helps track changes in code, collaborate safely, and manage different versions of a project. GitHub makes it easier to work with teams, review code, and support CI/CD workflows. Some essential Git commands and concepts: • git init — initialize a repository • git clone — copy an existing repo • git status — check current changes • git add — stage files for commit • git commit — save changes • git push — send changes to GitHub • git pull — get latest changes • git fetch — download changes without merging • git branch — create or view branches • git checkout — switch branches • git switch — modern way to switch branches • git merge — combine branches • git rebase — reapply commits on top of another branch (clean history) • git stash — temporarily save changes • git log — view commit history • git diff — see changes between commits/files • git reset — undo changes (careful usage) Key concepts: • Branching strategy • Pull requests (PRs) for code review • Conflict resolution • Clean commit history Git and GitHub are used in almost every DevOps workflow, especially for collaboration, automation, and CI/CD pipelines. I’ll continue posting one DevOps tool or concept every day. #Git #GitHub #DevOps #VersionControl #CICD #Automation #SoftwareEngineering #CloudComputing #DevOpsEngineer #Coding #TeamCollaboration #TechCommunity #LearningEveryDay #DeveloperTools #job #hr #hiring
To view or add a comment, sign in
Explore related topics
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