<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nabinsah on Medium]]></title>
        <description><![CDATA[Stories by Nabinsah on Medium]]></description>
        <link>https://medium.com/@nabinsah703?source=rss-ad753547fe42------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*oG09CQNEsl6kyPrQ</url>
            <title>Stories by Nabinsah on Medium</title>
            <link>https://medium.com/@nabinsah703?source=rss-ad753547fe42------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 23:57:06 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nabinsah703/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[ Understanding SSH Keys for Multiple Git Accounts (Beginner-Friendly Guide)]]></title>
            <link>https://medium.com/@nabinsah703/understanding-ssh-keys-for-multiple-git-accounts-beginner-friendly-guide-cf8ced154acc?source=rss-ad753547fe42------2</link>
            <guid isPermaLink="false">https://medium.com/p/cf8ced154acc</guid>
            <dc:creator><![CDATA[Nabinsah]]></dc:creator>
            <pubDate>Thu, 16 Jul 2026 03:58:25 GMT</pubDate>
            <atom:updated>2026-07-16T03:58:25.290Z</atom:updated>
            <content:encoded><![CDATA[<p>If you’ve ever seen commands like:</p><pre>ssh-keygen -t ed25519 -C &quot;your-email@gmail.com&quot;</pre><p>and wondered <em>“What exactly is happening here?”</em> — this guide will break it down in <strong>simple, non-technical language</strong>.</p><h3>🧠 What is an SSH Key? (Super Simple Explanation)</h3><p>Think of SSH like a <strong>secure lock system</strong>:</p><ul><li>🔑 <strong>Private Key</strong> → Your secret key (you NEVER share this)</li><li>🗝️ <strong>Public Key</strong> → A lock you give to GitHub/GitLab</li></ul><p>👉 When you try to push code:</p><ul><li>GitHub checks: <em>“Does this key match?”</em></li><li>If yes → ✅ Access granted</li><li>If no → ❌ Access denied</li></ul><h3>🔐 What Files Are Created?</h3><p>When you run:</p><pre>ssh-keygen -t ed25519 -C &quot;your-email@gmail.com&quot;</pre><p>You get <strong>2 important files</strong>:</p><pre>id_ed25519          ← Private key (KEEP SECRET)<br>id_ed25519.pub      ← Public key (SAFE TO SHARE)</pre><h3>🧾 Full Example of SSH Keys</h3><h3>🔒 Private Key (Example — NEVER SHARE)</h3><pre>-----BEGIN OPENSSH PRIVATE KEY-----<br>b3BlbnNzaC1rZXktdjEAAAAABG5vbmUAAAA...<br>...very long encrypted text...<br>...do not share this with anyone...<br>-----END OPENSSH PRIVATE KEY-----</pre><p>👉 This stays on your computer only.</p><h3>🌐 Public Key (Example — SAFE TO SHARE)</h3><pre>ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFkExampleKey1234567890abcdef your-email@gmail.com</pre><p>👉 This is what you paste into:</p><ul><li>GitHub → Settings → SSH Keys</li><li>GitLab → SSH Keys</li></ul><h3>⚙️ What Each Part of the Command Means</h3><h3>Command:</h3><pre>ssh-keygen -t ed25519 -C &quot;your-email@gmail.com&quot;</pre><h3>Breakdown:</h3><p>PartMeaningssh-keygenTool to create SSH keys-t ed25519Type of key (modern, secure, fast)-C &quot;email&quot;Label to identify the key</p><h3>📂 Where Keys Are Stored?</h3><p>Default location:</p><pre>C:\Users\YourName\.ssh\   (Windows)<br>~/.ssh/                  (Linux/Mac)</pre><h3>🧩 What is .ssh/config Doing?</h3><p>Example:</p><pre># Personal Account<br>Host github-personal<br>    HostName github.com<br>    User git<br>    IdentityFile ~/.ssh/id_ed25519_personal</pre><pre># Work Account<br>Host github-work<br>    HostName github.com<br>    User git<br>    IdentityFile ~/.ssh/id_ed25519_work</pre><h3>🧠 Simple Explanation</h3><p>This file is like a <strong>contact list with nicknames</strong>:</p><p>Name you typeReal meaninggithub-personalUse personal SSH keygithub-workUse work SSH key</p><h3>🔍 Line-by-Line Explanation</h3><h4>Host github-personal</h4><p>👉 A nickname you create</p><h4>HostName github.com</h4><p>👉 The real server (GitHub)</p><h4>User git</h4><p>👉 Default Git user (always “git”)</p><h4>IdentityFile ~/.ssh/id_ed25519_personal</h4><p>👉 Which private key to use</p><h3>🚀 What Happens When You Clone?</h3><h3>Command:</h3><pre>git clone git@github-personal:username/repo.git</pre><h3>Behind the scenes:</h3><ol><li>Git sees github-personal</li><li>Looks into .ssh/config</li><li>Finds correct SSH key</li><li>Uses that key to authenticate</li><li>Connects to GitHub securely</li></ol><h3>🔄 Real-Life Analogy</h3><p>Imagine:</p><ul><li>You have <strong>2 offices</strong></li><li>Each office has a <strong>different key</strong></li><li>Security guard (GitHub) checks your key</li></ul><p>Instead of carrying both keys manually:<br>👉 .ssh/config tells which key to use automatically</p><h3>⚠️ Important Rules</h3><ul><li>❌ Never share <strong>private key</strong></li><li>✅ Always share <strong>public key only</strong></li><li>🔐 Keep .ssh folder secure</li></ul><h3>🧪 How to Test If It Works</h3><pre>ssh -T git@github-personal</pre><p>If success:</p><pre>Hi username! You&#39;ve successfully authenticated...</pre><h3>🎯 Final Summary</h3><ul><li>SSH keys = secure login without password</li><li>Public key goes to GitHub</li><li>Private key stays on your system</li><li>.ssh/config helps manage multiple accounts easily</li></ul><h3>💬 Closing Thought</h3><p>Once you understand SSH keys, Git becomes:</p><ul><li>🔒 More secure</li><li>⚡ Faster (no password typing)</li><li>🧩 Easier for multi-account usage</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cf8ced154acc" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ Complete Guide: Using Multiple Git Accounts (Personal + Work) with SSH — From Start to Clone (No…]]></title>
            <link>https://medium.com/@nabinsah703/complete-guide-using-multiple-git-accounts-personal-work-with-ssh-from-start-to-clone-no-32659184dbba?source=rss-ad753547fe42------2</link>
            <guid isPermaLink="false">https://medium.com/p/32659184dbba</guid>
            <dc:creator><![CDATA[Nabinsah]]></dc:creator>
            <pubDate>Mon, 23 Mar 2026 11:12:54 GMT</pubDate>
            <atom:updated>2026-03-23T11:12:54.860Z</atom:updated>
            <content:encoded><![CDATA[<h3>🚀 Complete Guide: Using Multiple Git Accounts (Personal + Work) with SSH — From Start to Clone (No Steps Skipped)</h3><p>Managing multiple Git accounts with different Gmail IDs can feel confusing — but this guide will walk you through <strong>every single step</strong>, including the most commonly missed ones.</p><h3>📌 Scenario</h3><p>We will use:</p><ul><li>👤 <strong>Personal Account</strong> → personal@gmail.com(Your email address)</li><li>🏢 <strong>Work Account</strong> → work@gmail.com(Another email address)</li></ul><p>Goal:<br>👉 Use both accounts on the <strong>same computer</strong> without conflict<br>👉 Clone and push code using the correct account</p><h3>🧩 Step 1: Open Terminal</h3><p>Use any:</p><ul><li>Git Bash (recommended)</li><li>CMD / PowerShell</li></ul><h3>🔑 Step 2: Generate SSH Key for Personal Account</h3><pre>ssh-keygen -t ed25519 -C &quot;personal@gmail.com&quot;</pre><h3>⚠️ IMPORTANT PROMPT (DON’T SKIP)</h3><p>You will see:</p><pre>Enter file in which to save the key (C:\Users\YourName\.ssh\id_ed25519):</pre><h3>👉 Type this (VERY IMPORTANT):</h3><pre>C:\Users\YourName\.ssh\id_ed25519_personal</pre><p>Press <strong>Enter</strong></p><h3>🔐 Passphrase Step</h3><pre>Enter passphrase (empty for no passphrase):</pre><p>👉 Press <strong>Enter</strong> (or set password)</p><p>Then again:</p><pre>Enter same passphrase again:</pre><h3>✅ Result</h3><p>You get:</p><pre>id_ed25519_personal<br>id_ed25519_personal.pub</pre><h3>🔑 Step 3: Generate SSH Key for Work Account</h3><pre>ssh-keygen -t ed25519 -C &quot;work@gmail.com&quot;</pre><h3>⚠️ Again IMPORTANT</h3><p>When asked:</p><pre>Enter file in which to save the key:</pre><p>👉 Type:</p><pre>C:\Users\YourName\.ssh\id_ed25519_work</pre><p>Press Enter</p><h3>🔐 Passphrase</h3><p>Press Enter twice again</p><h3>✅ Result</h3><pre>id_ed25519_work<br>id_ed25519_work.pub</pre><h3>📂 Step 4: Verify Keys</h3><p>Go to:</p><pre>C:\Users\YourName\.ssh\</pre><p>You should see:</p><pre>id_ed25519_personal<br>id_ed25519_personal.pub<br>id_ed25519_work<br>id_ed25519_work.pub</pre><h3>🔗 Step 5: Add SSH Keys to GitHub</h3><h3>👉 Copy Personal Key</h3><pre>cat ~/.ssh/id_ed25519_personal.pub</pre><p>Copy output</p><h3>👉 Add to GitHub (Personal Account)</h3><ol><li>Login to your personal GitHub</li><li>Go to:<br>Settings → SSH and GPG Keys</li><li>Click <strong>New SSH Key</strong></li><li>Paste key</li><li>Save</li></ol><h3>👉 Copy Work Key</h3><pre>cat ~/.ssh/id_ed25519_work.pub</pre><h3>👉 Add to Work GitHub</h3><p>Repeat same steps in work account</p><h3>⚙️ Step 6: Configure SSH (.ssh/config)</h3><p>Open or create:</p><pre>C:\Users\YourName\.ssh\config</pre><h3>👉 Add this:</h3><pre># Personal Account<br>Host github-personal<br>    HostName github.com<br>    User git<br>    IdentityFile ~/.ssh/id_ed25519_personal</pre><pre># Work Account<br>Host github-work<br>    HostName github.com<br>    User git<br>    IdentityFile ~/.ssh/id_ed25519_work</pre><h3>🧠 What this does</h3><p>HostMeaninggithub-personalUses personal SSH keygithub-workUses work SSH key</p><h3>🔌 Step 7: Add Keys to SSH Agent</h3><pre>ssh-add ~/.ssh/id_ed25519_personal<br>ssh-add ~/.ssh/id_ed25519_work</pre><h3>🧪 Step 8: Test Both Accounts</h3><pre>ssh -T git@github-personal<br>ssh -T git@github-work</pre><h3>✅ Expected Output</h3><pre>Hi username! You&#39;ve successfully authenticated...</pre><h3>📥 Step 9: Clone Repository (MOST IMPORTANT PART)</h3><h3>❌ Default (WRONG for multiple accounts)</h3><pre>git clone git@github.com:username/repo.git</pre><h3>✅ Correct Way</h3><h3>👉 Clone Personal Repo</h3><pre>git clone git@github-personal:personal-username/repo-name.git</pre><h3>👉 Clone Work Repo</h3><pre>git clone git@github-work:work-username/repo-name.git</pre><h3>🧠 What Happens Internally</h3><ul><li>github-personal → uses personal key</li><li>github-work → uses work key</li></ul><h3>🧑‍💻 Step 10: Set Git Identity Per Project</h3><p>Go inside repo:</p><pre>cd repo-name</pre><h3>👉 For Personal Repo</h3><pre>git config user.name &quot;Your Name&quot;<br>git config user.email &quot;personal@gmail.com&quot;</pre><h3>👉 For Work Repo</h3><pre>git config user.name &quot;Your Work Name&quot;<br>git config user.email &quot;work@gmail.com&quot;</pre><h3>🚀 Step 11: Test Push</h3><pre>git add .<br>git commit -m &quot;test commit&quot;<br>git push</pre><p>👉 It will push using correct account automatically</p><h3>⚠️ Common Mistakes</h3><p>ProblemReasonPermission deniedWrong SSH keyWrong account commitEmail not setClone failsUsed default URL</p><h3>🎯 Final Result</h3><p>Now you can:</p><p>✅ Use multiple GitHub accounts<br>✅ Clone from different accounts<br>✅ Push without login conflict<br>✅ Maintain clean identity</p><h3>💬 Final Words</h3><p>Once set up, this works <strong>perfectly forever</strong> — you don’t need to log in/out again.</p><h3>🔥 Pro Tip (For Medium Post)</h3><p>Add these tags:</p><ul><li>#Git</li><li>#GitHub</li><li>#SSH</li><li>#DeveloperTips</li><li>#Programming</li></ul><h3>🎯 Conclusion</h3><p>Managing multiple Git accounts with different Gmail IDs might seem complicated at first, but with SSH and proper configuration, it becomes a smooth and reliable workflow.</p><p>By following this guide step-by-step, you’ve learned how to:</p><ul><li>🔑 Generate and manage multiple SSH keys</li><li>⚙️ Configure .ssh/config for account separation</li><li>🔗 Connect each key to the correct Git account</li><li>📥 Clone repositories using the right identity</li></ul><p>This is a <strong>one-time setup</strong> that will save you from constant login issues and confusion in the future.</p><h3>🚀 What You Can Do Next</h3><p>Now that your setup is complete, you can:</p><ul><li>Work on personal and professional projects without conflicts</li><li>Maintain clean commit history per account</li><li>Scale this setup for GitLab, Bitbucket, or team environments</li></ul><h3>💬 Final Note</h3><p>The key takeaway is simple:</p><blockquote><em>👉 </em>Use separate SSH keys + proper config = zero account conflicts</blockquote><h3>🙌 If This Helped You</h3><ul><li>👏 Clap for the article</li><li>🔖 Save it for later</li><li>📤 Share it with your team or fellow developers</li></ul><p><strong>Happy Coding! 🚀</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=32659184dbba" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>