How to generate from comments copilot-style?

Hello here. I just signed up for the pro-trial of Cursor, coming from Studio Code with Copilot, and I am wondering why I am unable to generate code from comments right after I have typed them. Is that a missing feature in Cursor? I am so used to doing that with Copilot that I am wondering if there is a way to do the same in Cursor without necessarily using the Command + K (or control + K) command to enter the prompt, which would cause not having a reference comment in my code.

Any help is appreciated.

Hi @fablau,

I just checked, and it works. Could you please provide more information? A screenshot or a video would be great.

Thank you for your reply deanrie.

Well, it looks like the problem appears inside very big files. I am working on a JS program that is over 30k lines long, and that feature just doesn’t work. But it works on small files.

And not only the generation of code, but even the suggestion inside the comment itself isn’t working.

Look at the two videos below, the first one is on a new file, the second one is at the bottom of my mentioned over 30k lines file:

Any thoughts on that?

If my memory serves me correctly, then the Cursor has a limit of 10,000 lines.

Well, that would make sense. But if so, that’d be disappointing because having more than 10k lines is not uncommon.

Thanks for your reply again.

1 Like

there are two way:

  • enable Cursor Tab, it is auto run
  • ctrl+k, input a space, enter, have fun.

Yes, that works. But I like to use comments for prompts. Thanks.