Syncing project settings between worktrees
I've been working with AI agents a lot lately, and I really like the workflow where every thread is a new worktree. I'm happy JetBrains implemented some support for worktrees, but I feel like it's quite lacking at the moment.
My biggest issue is that project settings don't sync between worktrees. When I open a new worktree, all my debugger settings, database connections, etc., are left behind. I tried copying-pasting the .idea directory into the worktree, but that causes a nasty bug: I can't mark directories as excluded/test/source anymore; directories set as ignored show up in search again; and other related issues.
I also hate that opening a new worktree forces PhpStorm to analyse the entire project from scratch, even though there's already a substantial body of indices it could reuse from the main working repo.
Did you guys run into the same issues? what was your solution to it?
P.S.: didn't use the AI flair, because even though the post mentions AI, the things I'm talking about aren't inherently AI-related