Cursor issues with monorepo and code-workspace

It’s been really hard for me to tell Cursor how to create files in my monorepo.

I’m using turborepo, pnpm workspaces, and vscode workspaces to have a clean organisation of my monorepo.

My code-workspace looks like this:

{
  "folders": [
    {
      "name": "🏠 root",
      "path": "."
    },
    {
      "name": "🟠 serverless",
      "path": "apps/serverless"
    },
    {
      "name": "🔵 web",
      "path": "apps/web"
    }
  ],
  "settings": {}
} 

When I tell Cursor to create or edit files, it somehows think it should bypass my apps folder. It creates for example a new serverless at the root level and start doing its business here.

I’ve setup .mdc files that yells at Cursor not to create files there, I’ve made a .cursorignore that ignores the folders it creates hoping it would guess that’s not what it should do, but I cannot make it work as I want to.

Is there something else I should do ?

1 Like

Same sometimes have similar problems, and because of emoji the main folder was not indexed, i remove emoji and name - indexing fixed.

It seems to create files in whatever directory it’s in. So if you haven’t already you might try seeing if you can tell it something like “When creating files, first switch to /apps directory with cd /apps, THEN create the file.”

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.