🚀 Git & GitHub – Hands-on Learning. Recently, I deep-dived into Git & GitHub by creating a practice repository and performing everything manually. 💡 Big takeaway: Git is like a time machine for code. Every commit saves a checkpoint, so we can safely move forward and roll back when needed. 🔹 What I learned & practiced: Git vs GitHub Git = local version control tool GitHub = cloud platform to host & share repositories Repository & Internals Repo contains code + history .git works like a database storing all metadata Configuration & Basics Configured user identity using git config Used git init, git status, git add, git commit File States & Flow Working Directory → Staging → Commit Understood untracked, modified, staged, committed states Commits & History Used git log, git log --oneline Learned that HEAD points to the latest commit Branching & Merging Created branches using git switch -c Practiced fast-forward & non-fast-forward merges Resolved merge conflicts in VS Code Rebase & Recovery Used rebase for clean, linear history Used git reflog and git reset --hard for time travel Diff, Cherry-pick & Stash Compared changes using git diff Cherry-picked specific commits across branches Used git stash to manage work-in-progress Ignore, Keep & Remote Ops Used .gitignore and .gitkeep Pushed, pulled, and cloned repositories using GitHub 📌 All concepts were practiced locally and pushed to GitHub as a learning project. Big thanks to Ansh Lamba for the clear and practical Git tutorials. Sharing this in case it helps someone starting their Git journey 🚀 Practice > Theory, always. 👇 Feel free to check the GitHub repository link in the comments. #Git #GitHub #VersionControl #LearningByDoing #DeveloperJourney #ContinuousLearning
Git & GitHub Hands-on Learning: Mastering Version Control
More Relevant Posts
-
🚀 Learning Git & GitHub – Understanding Version Control As part of my development journey, I recently started learning Git and GitHub — and this completely changed how I think about managing code. Before this, I used to save projects like: 📎 project_final.js 📎 project_final_final.js 📎 project_last_final_real.js 😅 Now I understand why version control is essential. Here’s what I’ve been learning 👇 🔹 Git Basics I learned how Git tracks changes in a project and allows developers to move back and forth between versions safely. 📍 git init – Initialize a repository 📍 git add – Stage changes 📍 git commit – Save changes with meaningful messages 📍 git status – Check what’s happening 📍 git log – View commit history It feels like having a timeline of my work. 🔹 Branches Understanding branches was a big moment. Creating separate branches to experiment without breaking the main code showed me how real-world teams work efficiently. 🔹 Merging & Conflicts I explored how branches are merged and how conflicts happen — and more importantly, how to resolve them logically. 🔹 GitHub Then I connected local repositories to GitHub: 📎 git remote add origin 📍 git push 📎 git pull 📍 git clone Now my projects live in the cloud, are shareable, and act as my public portfolio. 🔹 Why This Matters Learning Git & GitHub made me realize: Code is not just written — it’s managed Collaboration requires structure Clean commit messages are part of professionalism This phase made me feel closer to real-world development practices. Still learning, still experimenting, and building step by step. 💪 All thanks to sigma 9.0 Apna College and Shradha Khapra #Git #GitHub #VersionControl #WebDevelopment #LearningInPublic #DeveloperJourney
To view or add a comment, sign in
-
-
Day 17 / 30 of Learning 🔥🚀 Quick Git vs. GitHub : 📌 Git: A free, distributed version control system you install locally to track code changes, create branches, and manage history (e.g., git commit, git merge). 📌 GitHub: A cloud platform built on Git for hosting repos, collaborating via pull requests, and showcasing work—think of it as Git's social network. 🔄 The Everyday Commands (You use these 80% of the time): 🔹 git status - What did I just break? 🔹 git add - Stage everything 🔹 git commit -m "message" - Save your progress 🔹 git diff - What exactly changed? 🔹 git log- oneline Clean commit history 📁 Repository Setup 🔹git clone <url> - Clone a remote repository 🔹 git config --global user.name "Name" 🔹 git config --global user.email "email" 📋 Basic Operations 🔹 git init - start a new repo 🔹 git clone - copy an existing repo 🔹 git status - check what's going on 🔹 git log - view commit history ⚙️ Working with Branches 🔸 git branch - create/list branches 🔸 git checkout/ git - switch move between branches 🔸 git merge - merge changes safely 📈 Staging & Committing 🔸 git add - stage changes 🔸 git commit - save progress 🔸 git stash - temporarily park work 🔸 git reset - undo mistakes 🔠 Team Collaboration ▪️ git push - send changes ▪️ git pull - sync updates ▪️ git remote - manage remotes ▪️ git tag - mark important versions 💡 Advanced (but super useful) ▪️git diff - see what changed ▪️git blame - track code ownership ▪️ git bisect - find bugs faster 🔖 Undo Mistakes 🔹git reset HEAD~1 - Undo last commit 🔸 git checkout - <file> - Discard changes ▪️ git stash - Save work for later ▫️ git stash - pop Bring it back 🌐 GitHub is a powerful cloud platform that: ➡️ Stores repositories online ➡️ Helps collaborate with others ➡️ Builds a strong developer portfolio #Day17 #LearningInPublic #Git #GitHub #WebDevelopment #CodingJourney #StudentDeveloper #fresher
To view or add a comment, sign in
-
-
If you’re learning Git and feeling overwhelmed, you don’t need advanced workflows yet. You just need: ✔ A simple mental model ✔ A small set of core commands ✔ Consistent practice That’s exactly why I wrote a beginner-friendly guide explaining Git without heavy theory — just practical understanding. 🔗 Read the full article here: [https://lnkd.in/ev_xGweH] #Git #SoftwareEngineering #VersionControl #LearningInPublic
To view or add a comment, sign in
-
Slide 1 – Cover 📘 Collaborating with Git – Cheat Sheet 💻 Beginner Friendly | Version Control | GitHub 🚀 Essential for IT & Developer Roles Slide 2 – Why Version Control? ✅ Track changes ✅ Restore old versions ✅ Work safely in teams ✅ Avoid code loss 📌 Version control keeps your project organized and secure. Slide 3 – What is Git? 🔹 Free & Open Source 🔹 Distributed Version Control System 🔹 Tracks file changes 🔹 Used by developers worldwide 🧠 Every change = one version Slide 4 – Git Repository 📂 Repository = Project Database 📸 Each version = Snapshot (Commit) Types: ✔ Local Repository ✔ Remote Repository (GitHub) Slide 5 – Git File States 📄 Untracked – Not added to Git ✏ Modified – File changed 📦 Staged – Ready to commit ✅ Committed – Saved version Slide 6 – Collaboration with Git 👥 Multiple developers 🧠 Track who changed what ⏱ Avoid conflicts 🔁 Easy rollback Perfect for team projects! Slide 7 – Basic Git Commands git init git clone git status git add . git commit -m "message" git push git pull 💡 These commands are MUST-KNOW! Slide 8 – GitHub 🌐 Cloud repository hosting 👨💻 Team collaboration 🔐 Secure & versioned Popular platforms: ✔ GitHub ✔ GitLab ✔ Bitbucket Slide 9 – Important Note ⚠️ GitHub no longer supports password login ✅ Use Personal Access Token (PAT) Slide 10 – Final Slide 🚀 Learn Git = Career Growth 💼 Required for IT / Dev Jobs 👉 Save this post 👉 Follow for more IT content #Git #GitHub #VersionControl #ITJobs #Freshers #SoftwareDevelopment #DevOps #Programming #TechSkills #LearningDaily #CareerGrowth #LinkedInLearning Aniketh Reddy Mustoor Rahul Attuluri Sashank Gujjula Anupam Pedarla Soumya Soman
To view or add a comment, sign in
-
-
GitHub Workflows: My Learning Journey! 🚀 We built a pytest automation workflow that could be triggered from multiple repos across our organization. Sounds straightforward, right? My thoughts were the same, “Cool — just plug it into GitHub Actions.” The Requirements: - Workflow lives on a non-default branch (not main). - Triggered remotely by other repos' deployment pipelines - Manual triggers for testers with test-type selection (smoke, regression, etc.) - Pulls test data from S3, uploads results back - Passes triggering repo metadata to the environment So, I started with repository_dispatch for API triggers and workflow_dispatch for manual ones. Then came the first roadblock, workflows must be on the default branch to listen for repository_dispatch events. Since mine wasn't, workflow_dispatch became my only option. For cross-repo triggering, I used CURL with POST requests. But authentication? My first thought was GitHub PAT, but that meant maintenance headaches and user-specific dependencies. Enter github-app-token — generates temporary tokens, already set up in our org. Problem solved. The real fun began after pushing to GitHub. Issue #1: Workflow doesn't appear in the Actions tab. Why? Non-default branches need to run once before GitHub registers them. Issue #2: Other repos couldn't find my workflow either. Issue #3: Still no manual trigger button in the UI. Turns out workflows on non-default branches can't be triggered from GitHub's interface. The Solution: - Added an on-push trigger to first trigger the repository immediately after I have pushed the new changes to github. That way github also registers it immediately after the first run. Of course I removed the on-push trigger afterwards. This solved both Issues 1 and 2. - To solve issue 3, had to write a Python script for manual triggers. - Of course many of these hurdles could have been solved by writing a simple workflow on the main branch that triggers the test runner workflow in our designated branch. But we were to not push any code to main branch. To simplify cross-repo usage, I created a composite action (action.yaml) to trigger the workflow, which can be used by other repositories. Facts about this composite action: - Must live outside the .github/workflows/ - Runs in the caller's context. - Github secrets and variables can't be accessed and must be passed as inputs. The rest — Input validations, S3 integration, conditional steps, JSON parsing with jq -- fell into place using third-party actions and custom scripts. And I learned a little more than the basics of Github Workflows! GitHub workflows have quirks, especially with non-default branches. But every roadblock taught me something new. And yes, LLMs were excellent pair-programming partners throughout! 😁 Have you worked on something similar? I’d love to hear about your experience. Also, let me know your thoughts — would you have approached this differently? I’m always keen to learn alternative solutions.
To view or add a comment, sign in
-
Git feels overwhelming—until you see it laid out like this 🔧📘 Most developers don’t struggle with Git concepts. They struggle with remembering the right command at the right time. This infographic is a practical Git commands cheat sheet you can rely on during real work. It covers the commands you actually use 👇 • Initialize & clone repositories • Stage & commit changes • Branching and merging • Syncing with remote repositories • Inspecting logs and diffs • Undoing mistakes safely If you’re coding without confidence in Git, you’ll hesitate to commit, branch, or collaborate. This visual helps you move faster and break less. 📚 Learn Git & GitHub Properly (Courses) 🔗 Google – Introduction to Git and GitHub https://lnkd.in/dA4gC23m 🔗 IBM – Get Started with Git and GitHub https://lnkd.in/dFHWbpBr 🔗 Packt – Git & GitHub Complete Master Class https://lnkd.in/dbJS_k_P Save this infographic 📌 Keep it nearby while coding Share it with someone new to Git Strong version control = confident development 💡
To view or add a comment, sign in
-
-
(day-14) 📌 Today’s Learning: Most Used (~80%) Git Commands in Real Projects While working with Git & GitHub, I realized that you don’t need to remember every Git command — you just need to master the ones you use daily in real projects. Here are the most commonly used Git commands and when we actually use them 👇 🔹 1. Project Setup & First Time Use git init ➡️ Start a new Git repository 📌 Use when: You create a new project locally git clone <repo-url> ➡️ Copy an existing repo from GitHub 📌 Use when: Joining a project or working on open source 🔹 2. Daily Development (MOST USED 🔥) git status ➡️ Check file changes (modified, staged, untracked) 📌 Use when: Before every commit (trust me 😄) git add <file> / git add . ➡️ Stage changes 📌 Use when: You’re ready to save work git commit -m "message" ➡️ Save changes with message 📌 Use when: Feature or bug fix completed git diff ➡️ See what changed 📌 Use when: Before staging or reviewing changes 🔹 3. Branching & Team Work git branch ➡️ List branches 📌 Use when: Checking current branch git branch <name> ➡️ Create a branch 📌 Use when: Starting a new feature git checkout <branch> ➡️ Switch branches 📌 Use when: Moving between features git checkout -b <branch> ➡️ Create + switch branch 📌 Use when: Most common way to start work (New version) git switch <branch> ➡️ Cleaner branch switching 🔹 4. Sync With GitHub (VERY COMMON) git pull ➡️ Get latest changes 📌 Use when: Before starting work every day git push ➡️ Upload commits to GitHub 📌 Use when: After committing your work git fetch ➡️ Check remote changes without merging 📌 Use when: Safe check before pull 🔹 5. Merging & Collaboration git merge <branch> ➡️ Merge branches 📌 Use when: Feature is completed git rebase <branch> ➡️ Clean commit history 📌 Use when: Advanced teams / before PR 🔹 6. Fixing Mistakes (VERY IMPORTANT 😅) git log ➡️ View commit history 📌 Use when: Debugging or rollback git reset --soft HEAD~1 ➡️ Undo commit, keep changes 📌 Use when: Wrong commit message git reset --hard HEAD ➡️ Remove all local changes 📌 Use when: Careful! discard everything git stash ➡️ Save work temporarily 📌 Use when: Need to switch branches fast git stash pop ➡️ Restore stashed work 🔹 7. Tags & Releases git tag ➡️ List versions 📌 Use when: Marking releases git tag v1.0 ➡️ Create release version
To view or add a comment, sign in
-
🚀 Day 6 – Git & GitHub Series | Reverting & Resetting (Undo Like a Pro) Let’s be honest… Every developer has done this at least once: 👉 committed wrong code 👉 deleted a file by mistake 👉 pushed something broken 👉 or thought “How do I go back now?!” 😅 That’s where Git recovery commands save your life. Because in real projects, it’s not about never making mistakes — it’s about fixing them safely and fast. 🔹 Must-know Undo Commands ✅ Move HEAD but keep changes git reset --soft <commit_id> ✅ Unstage changes git reset --mixed <commit_id> ✅ Reset everything (⚠ dangerous) git reset --hard <commit_id> ✅ Safely undo via new commit (team-friendly) git revert <commit_id> ✅ Restore files git restore <file> ✅ Remove from staging git restore --staged <file> ✅ Clean unwanted files git clean -f git clean -fd 💡 Real-world rule I follow ✔ Working alone → reset ✔ Working in team/shared repo → revert ✔ Avoid --hard unless 100% sure ✔ Always double-check before cleaning Small knowledge → Huge time saved during production issues. 📌 This is Day 6 of my Git Mastery Series Daily practical Git + GitHub tips for Developers, DevOps & SREs. If you’re serious about leveling up your engineering skills: 👉 Follow for the next post #Git #GitHub #DevOps #SRE #VersionControl #SoftwareEngineering #Developers #ProgrammingLife #TechLearning #CloudComputing #Debugging #OpenSource #CareerGrowth #LearnInPublic
To view or add a comment, sign in
-
-
🚀 From Shell Scripts to Git Commits — Building My DevOps Foundation (Day 21 & 22) Two days. Two core skills. One powerful shift in mindset. 🔥 🧠 Day 21 – Shell Scripting Cheat Sheet: Build Your Own Reference Guide Instead of just writing more scripts… I built something I’ll use for years. 👉 A personal Shell Scripting Cheat Sheet What I included: Variables & user input If-else conditions Loops (for / while) Functions Exit codes Real automation snippets Common mistakes & fixes 💡 Biggest lesson: If you can organize and explain it clearly, you truly understand it. Automation isn’t just about writing scripts. It’s about writing scripts with clarity and confidence. 🔥 Day 22 – Introduction to Git: My First Repository Then I stepped into version control with Git — the backbone of modern DevOps. Today I: ✅ Installed & configured Git ✅ Created my first repository ✅ Explored the hidden .git/ folder ✅ Built git-commands.md (my growing Git reference) ✅ Made multiple clean commits ✅ Understood the workflow deeply Working Directory → Staging Area → Repository Now I understand: Why git add exists What the staging area actually does Why clean commit history matters Git doesn’t just track files. It tracks growth. 🎯 What These Two Days Taught Me 🔹 Documentation strengthens memory 🔹 Automation needs discipline 🔹 Version control protects your progress 🔹 Small daily improvements compound fast Shell scripting taught me to automate. Git taught me to manage change. That’s real DevOps thinking. 🚀 Let’s learn together 👇 #DevOps #Git #ShellScripting #Linux #Automation #90DaysOfDevOps #LearningInPublic #DevOpsKaJosh #TrainWithShubham
To view or add a comment, sign in
-
-
Master Git basics → Every developer needs this 🧠🔧 Git feels confusing at first. Until you realize it’s part of every real project. • Team collaboration • Version control • Production workflows This carousel covers the essential Git commands you’ll actually use. You’ll learn how to: • Initialize & clone repositories • Stage and commit changes • Create and manage branches • Sync with remote repositories • Inspect history and diffs • Undo mistakes safely If you understand these commands, you: ✔️ Work confidently in teams ✔️ Avoid breaking codebases ✔️ Look professional as a developer Git isn’t optional anymore. It’s a core software engineering skill. 🎓 Learn Git & GitHub (Beginner → Practical) 🔗 Google – Introduction to Git and GitHub https://lnkd.in/dA4gC23m 🔗 IBM – Get Started with Git and GitHub https://lnkd.in/dFHWbpBr 🔗 Packt – Git and GitHub Complete Master Class https://lnkd.in/dbJS_k_P 👉 Save this cheat sheet 👉 Practice these commands today 👉 Share it with someone learning Git Strong Git skills unlock better collaboration and faster growth 🚀
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
🔗 GitHub Practice Repository: https://github.com/mkhune661/mack_git_learning