Live data from Hacker News

Setup Script Should Support Git Worktrees

piechowski.io

1–10 of 12 posts

Re: Setup Script Should Support Git Worktrees

#2
Author here. Parallel worktrees showed me where Git’s isolation ends. Files stayed separate; ports, databases, cache keys, queues, and Compose resources did not. We now share compatible services and isolate names per worktree. Which shared resource has been hardest for your team to isolate, and why?

Re: Setup Script Should Support Git Worktrees

#5
I've been doing similar for many scripts within project workflows... I've started calling the directory in question ./run/ by convention, so I type run/scriptname to run stuff... I've got bash (extnsionless) and powershell (ps1) scripts in place on my work project).

I'll also lean into docker+compose usage for any background services, and even development in order to reduce the running footprint switching projects.

Re: Setup Script Should Support Git Worktrees

#7

Author here. Parallel worktrees showed me where Git’s isolation ends. Files stayed separate; ports, databases, cache keys, queues, and Compose resources did not. We now share compatible services and isolate names per worktree. Which shared resource has been hardest for your team to isolate, and why?

Did you write your post with AI? It is really painful to read in some parts (mostly because of the cliches of AI)

Re: Setup Script Should Support Git Worktrees

#8
post #7

Author here. Parallel worktrees showed me where Git’s isolation ends. Files stayed separate; ports, databases, cache keys, queues, and Compose resources did not. We now share compatible services and isolate names per worktree. Which shared resource has been hardest for your team to isolate, and why?

Did you write your post with AI? It is really painful to read in some parts (mostly because of the cliches of AI)

Actually no, sat down and wrote it out. Did some AI proofreading but applied the suggestions by hand. Would be interested to hear what parts were painful.

Re: Setup Script Should Support Git Worktrees

#9
post #5

I've been doing similar for many scripts within project workflows... I've started calling the directory in question ./run/ by convention, so I type run/scriptname to run stuff... I've got bash (extnsionless) and powershell (ps1) scripts in place on my work project). I'll also lean into docker+compose usage for any background services, and even development in order to reduce the running footprint switching projects.

Love it! Same here. bin/ is a convention I picked up from Rails and thoughtbot over the years. I also have bin/staging and bin/prod for data fixes, deploy helpers, and querying the DB, alongside bin/test and bin/dev.

Re: Setup Script Should Support Git Worktrees

#10

How amazing that git launched this way ahead of it becoming the ubiquitous choice for AI native development workflows

Yeah! Worktrees were already sitting there. Agents just turned them from an occasional convenience into something I use every day.
Post reply on HN