Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The thing I would like automated is highlighting a function in my code then ask the AI to move it to a new module-file and import that new module.

I would like this to happen easily like hitting a menu or button without having to write an elaborate "prompt" every time.

Is this possible?



I think most language servers have a feature like this right?


Moving a function or class? Yes. But moving arbitrary lines of code into their own function in a new module is still a PITA, particularly when the lines of code are not consecutive.


So is moving a function or class possible? What actions you need to take to accomplish that? Thanks


This is supported natively by most IDEs today.


At least Pycharm is good at it.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: