Experience a wave of ChatGpt tool-cursor (automatic code generation)

Recently, I experienced a cursor, which automatically generates code tools and integrates the recently popular ChatGpt. Currently, the better code generation tools are github copilot and cursor , but github copilot requires payment or a long waitlist, so it is currently better the cursor

The official website is as follows:

insert image description here

configuration

Configure the languages ​​​​that you often use, such as ts, html, css, etc.

insert image description here

operate

Currently, there are only two functions, as follows:

insert image description here

ctrl+k: generate code

Describe the code function that needs to be generated, and it will automatically generate it for you after pressing Enter, such as generating a Fibonacci sequence functioninsert image description here

If you want to do some editing operations on this code, such as adding comments, just select the code and ctrl+kpress Enter again, as follows:

insert image description here

Accept AllAfter generation, two functions are provided Reject All, similar to the function of [select all/unselect all]

  • Accept All: add all
  • Reject All: delete all

ctrl+l: intelligent dialogue

The function is similar to gpt-4. If you ask him your doubts, he will give you a solution without going to Baidu for the answer, as follows:
insert image description here

When you don't understand this code, you can also select the code and ask him to implement logic or code structure, etc., as follows:

insert image description here

Note: As can be seen from the above dialogue, the cursor is not sensitive to language, so if you want to generate a dialogue in Chinese, it is best to add [Please use Chinese] similar to this kind of words

use

The function of cursor is currently a simple and comprehensive coding tool for programmers. It supports multiple languages, such as js, ts, python, rust, go, java and other common programming languages ​​on the market. He can automatically generate code according to your description, and you can accept other people's code to help you understand and refactor the code, and can test bugs, verify formats, etc.

reference link

https://cn-sec.com/archives/1614273.html

https://cloud.tencent.com/developer/article/2242409

Guess you like

Origin blog.csdn.net/weixin_41886421/article/details/129887135