<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: livecodelife</title>
    <description>The latest articles on Forem by livecodelife (@livecodelife).</description>
    <link>https://forem.com/livecodelife</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F2315846%2F9a5d17ca-d840-4b95-afa2-387d3df31eed.jpeg</url>
      <title>Forem: livecodelife</title>
      <link>https://forem.com/livecodelife</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/livecodelife"/>
    <language>en</language>
    <item>
      <title>How I Supercharged My Workflow with Git Worktrees</title>
      <dc:creator>livecodelife</dc:creator>
      <pubDate>Sat, 21 Jun 2025 21:15:18 +0000</pubDate>
      <link>https://forem.com/livecodelife/how-i-supercharged-my-workflow-with-git-worktrees-2jgj</link>
      <guid>https://forem.com/livecodelife/how-i-supercharged-my-workflow-with-git-worktrees-2jgj</guid>
      <description>&lt;p&gt;While venting to ChatGPT about how painful it was to switch branches every time I got feedback on a PR, I discovered Git worktrees. I’d open a PR for a new feature, wait for reviews, then jump onto another task—only to have to &lt;code&gt;git checkout&lt;/code&gt; back later when reviewers chimed in. It felt like constantly tearing down and rebuilding my mental context. I mentioned this to ChatGPT, and it suggested trying Git worktrees to keep multiple branches checked out at once. After some research, and talking more with ChatGPT about conventions and pitfalls, I started using this feature at work. Within minutes I had two worktrees live: one for my open PR, and another for my new feature. Now I could let Cursor build out a plan in one window while coding in the other. When comments rolled in on my PR, I simply switched windows without ever dropping my existing work.&lt;/p&gt;

&lt;p&gt;After sharing this trick with teammates, I realized most engineers weren’t aware this was even a Git feature. A Reddit post I stumbled upon confirmed that Anthropic’s Claude Code users have been leveraging worktrees to run parallel AI coding sessions. The surprise I was met eith when I mentioned that this was a native git feature it was proof that this  capability is still under-hyped.&lt;/p&gt;




&lt;h2&gt;
  
  
  Where the Pros Are Already Using It
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Anthropic (Claude Code)&lt;/strong&gt;
Anthropic’s internal docs walk through creating separate worktrees for different Claude sessions:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  git worktree add ../feature-auth feature-auth
  &lt;span class="nb"&gt;cd&lt;/span&gt; ../feature-auth &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; claude
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can spin up parallel Claude Code windows—each isolated to its own branch—so AI tasks don’t step on each other’s toes.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Atlassian Sourcetree&lt;/strong&gt;&lt;br&gt;
Sourcetree added Git worktree support back in 2015, highlighting how useful it is for large projects with multiple branches. Today, both GUI and CLI users tap into worktrees without ever thinking about cloning a repo twice.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;VS Code &amp;amp; JetBrains IDEs&lt;/strong&gt;&lt;br&gt;
Extensions like “Git Worktrees” for VS Code or built-in support in IntelliJ let you create, switch, and manage worktrees right from your editor—making them just as accessible as standard branch checkouts.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Open-Source Projects &amp;amp; Mono-Repos&lt;/strong&gt;&lt;br&gt;
Big mono-repo teams often need isolated environments for different features or releases. Worktrees let you keep each in its own directory, so you avoid full clones and minimize duplicate storage.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  My Top Tips &amp;amp; Tricks
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Use Descriptive Folder Names&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   git worktree add ../feature-ui-redesign ui-redesign
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Name each worktree folder after the branch or task so your terminal prompt and editor window both remind you what you’re working on.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Initialize Every Worktree&lt;/strong&gt;&lt;br&gt;
Each new directory is like a fresh clone. Remember to run your setup steps—&lt;code&gt;npm install&lt;/code&gt;, &lt;code&gt;bundle install&lt;/code&gt;, or your language’s build commands—so your tools and dependencies are ready.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;One IDE Window &amp;amp; Terminal per Worktree&lt;/strong&gt;&lt;br&gt;
Keep one editor window and one terminal tab open in &lt;em&gt;each&lt;/em&gt; worktree. This makes it crystal clear which branch you’re on and prevents cross-branch file watcher or cache issues.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Avoid Checking Out the Same Branch Twice&lt;/strong&gt;&lt;br&gt;
Git will refuse to attach the same branch to multiple worktrees. If you need a duplicate, create a temporary branch (&lt;code&gt;git checkout -b feature-copy&lt;/code&gt;) or use a detached HEAD (&lt;code&gt;git worktree add -d &amp;lt;path&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Clean Up When You’re Done&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   git worktree remove ../feature-ui-redesign
   git worktree prune
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Remove worktrees when features ship or batteries die. &lt;code&gt;git worktree list&lt;/code&gt; shows all your active worktrees, and &lt;code&gt;prune&lt;/code&gt; cleans up any that got deleted manually.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Mind Your Background Processes&lt;/strong&gt;&lt;br&gt;
If you have build watchers, dev servers, or AI sessions running, keep them confined to their worktree. Stop them before hopping to another to avoid port collisions or CPU overload.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Repair &amp;amp; Move Worktrees Safely&lt;/strong&gt;&lt;br&gt;
If you accidentally move a worktree folder, run &lt;code&gt;git worktree repair &amp;lt;new-path&amp;gt;&lt;/code&gt; in the main repo. Use &lt;code&gt;git worktree move &amp;lt;old-path&amp;gt; &amp;lt;new-path&amp;gt;&lt;/code&gt; if you want to rename or relocate cleanly without breaking links.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Wrapping Up (and What to Watch Out For)
&lt;/h2&gt;

&lt;p&gt;Git worktrees turned my PR-feedback treadmill into a smooth flow of parallel tasks. With Cursor (or any AI assistant) running in one worktree and my coding in another, I shaved hours off context switches every day. Plus, when bugs surface post-deploy, I’ve still got that worktree handy with all the latest changes, ready for a quick fix.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Caution:&lt;/strong&gt; It’s tempting to spin up a dozen worktrees and juggle every task at once. That can splinter your focus and lead to burnout. Start with a couple—maybe one for active features and one for hotfixes—and scale consciously. A clean, focused workflow beats a cluttered one every time.&lt;/p&gt;

&lt;p&gt;Give it a try on your next multi-branch stint. Clone once, work everywhere. &lt;/p&gt;

</description>
    </item>
    <item>
      <title>Roo Code Workflow: Build a Free, Always-On LLM-Powered Dev Assistant</title>
      <dc:creator>livecodelife</dc:creator>
      <pubDate>Mon, 09 Jun 2025 23:44:33 +0000</pubDate>
      <link>https://forem.com/livecodelife/roo-code-workflow-build-a-free-always-on-llm-powered-dev-assistant-5692</link>
      <guid>https://forem.com/livecodelife/roo-code-workflow-build-a-free-always-on-llm-powered-dev-assistant-5692</guid>
      <description>&lt;p&gt;&lt;strong&gt;TL;DR&lt;/strong&gt;: I’ve been running a local Roo Code setup 24/7—two weeks straight—using only free tiers (Gemini + OpenRouter) and a custom “Think” mode for planning. Here’s how to replicate it, why it’s cost-efficient, and key tweaks I learned from the community (this setup reached #1 on r/RooCode for 3 days).&lt;/p&gt;




&lt;h3&gt;
  
  
  Why This Setup Exists
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Cost Control&lt;/strong&gt;: Free tiers (Gemini via Google AI Studio, OpenRouter’s free models) let you run thousands of daily LLM calls with zero spend.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Specialized Modes&lt;/strong&gt;: Assign each model to the task it does best—planning, architecture, code, debugging—so you don’t waste expensive tokens.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;“Think” Mode&lt;/strong&gt;: A custom reasoning agent that breaks complex tasks into bullet-proof plans, cutting down trial-and-error.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Whether you’re prototyping a SaaS MVP, experimenting with AI-driven features, or just love playing with LLMs, this guide will get you up and running in under 20 minutes.&lt;/p&gt;




&lt;h2&gt;
  
  
  1. Prerequisites
&lt;/h2&gt;

&lt;p&gt;You’ll need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;VS Code + Roo Code extension&lt;/li&gt;
&lt;li&gt;A free Google AI Studio API key for Gemini&lt;/li&gt;
&lt;li&gt;A free OpenRouter API key (Buy $10 of credits for 1,000 free calls/day)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Create a Gemini provider profile through the Roo UI in VS Code and paste your API key in the specified field. &lt;/p&gt;

&lt;p&gt;Do the same for OpenRouter, or just setup OpenRouter when you install the Roo Code extension. Roo makes this easy!&lt;/p&gt;




&lt;h2&gt;
  
  
  2. Modes &amp;amp; Model Allocation
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Mode&lt;/th&gt;
&lt;th&gt;Role&lt;/th&gt;
&lt;th&gt;Model(s)&lt;/th&gt;
&lt;th&gt;Source&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Orchestrator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Breaks tasks into subtasks&lt;/td&gt;
&lt;td&gt;Gemini&lt;/td&gt;
&lt;td&gt;Google AI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Think&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Detailed reasoning &amp;amp; edge-case planning&lt;/td&gt;
&lt;td&gt;Gemini&lt;/td&gt;
&lt;td&gt;Google AI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Architect&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;High-level design &amp;amp; module outlines&lt;/td&gt;
&lt;td&gt;DeepSeek R1 0528&lt;/td&gt;
&lt;td&gt;OpenRouter&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Code&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Snippet &amp;amp; module generation&lt;/td&gt;
&lt;td&gt;DeepSeek V3 0324, Qwen3 235B, Mistral Devstal Small&lt;/td&gt;
&lt;td&gt;OpenRouter&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Debug&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Bug-fix suggestions &amp;amp; refinements&lt;/td&gt;
&lt;td&gt;Same as Code&lt;/td&gt;
&lt;td&gt;OpenRouter&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Pro tip:&lt;/strong&gt; If DeepSeek V3 feels sluggish, switch to Qwen3 for straightforward code. Use Devstral Small when you need more context in your prompts.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  3. Step-by-Step Setup
&lt;/h2&gt;

&lt;h3&gt;
  
  
  A) Create the “Think” Mode
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Open Roo Code → &lt;em&gt;Custom Modes&lt;/em&gt; → Add “Think”&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Role&lt;/strong&gt;:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;   You are a specialized reasoning engine. Analyze tasks, break them into steps, list edge cases, and return a markdown-structured plan. Do NOT write final code.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Instructions&lt;/strong&gt;:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;   - Use markdown headings and lists.
   - Start with a task summary, then steps, then challenges.
   - Output only the reasoning plan.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  B) Tweak Your Orchestrator Prompt
&lt;/h3&gt;

&lt;p&gt;In your Orchestrator’s custom instructions, replace step 1:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;1. When given a complex task, break it into logical subtasks. If a subtask needs deep analysis, call `new_task` to delegate to “Think” mode first. Use its structured output to guide subsequent steps.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And update step 2’s first sentence:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;2. For each subtask (directly or after using “Think”), use `new_task` to assign it to Architect, Code, or Debug.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  C) Configure Your Mode Profiles
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Gemini&lt;/strong&gt; profile → Orchestrator + Think&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;OpenRouter – Code-Debug-Plan&lt;/strong&gt; → Architect, Code, Debug&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  4. Running Your First Task
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Generate a PRD&lt;/strong&gt;: Ask any LLM to outline your project scope.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Feed the PRD&lt;/strong&gt; into Orchestrator—watch it delegate:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Off to Think for edge-case plans&lt;/li&gt;
&lt;li&gt;Off to Architect for module sketches&lt;/li&gt;
&lt;li&gt;Off to Code for implementation

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Review &amp;amp; Iterate&lt;/strong&gt;: Use Debug mode to fix any errors, then loop back.&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  5. Tips, Tricks &amp;amp; Community Q&amp;amp;A
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Q: How do I reduce inference costs?&lt;/strong&gt;&lt;br&gt;
A: Use “Think” mode to pre-plan—fewer back-and-forth code iterations = fewer tokens.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: Are these models the best?&lt;/strong&gt;&lt;br&gt;
A: Yes and no. There are more "premium" paid models available, but these models do well on benchmarks and have been shown to have good outputs. They also give you a lot more bang for your (non-existent) buck&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Q: Does this replace human input?&lt;/strong&gt;&lt;br&gt;
A: No—LLMs still need good prompts. Think of this as an assistant that you guide. The more precise your PRD and tasks, the better the output.&lt;/p&gt;




&lt;h2&gt;
  
  
  6. What’s Next
&lt;/h2&gt;

&lt;p&gt;This is just the start. There are a lot of enhancements you can add like Roo Commander and several Memory Bank strategies to make Roo work even better. Try different things and see what works for you&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Enjoyed this?&lt;/strong&gt; Share your own modes, tips, or questions in the comments, or drop me a note on LinkedIn/Reddit.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>ai</category>
      <category>beginners</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
