How to edit files on device #56
-
First time playing with this plugin today, so please forgive me if I just missed something! I have files on my MicroPython device that I want to edit. I can open and read the files just fine, but the files are seemingly read-only. Is there a way to make edits locally, then upon saving, have the new file uploaded to the device? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Hello, no worries, happy to help. There is no feature for directly editing on-device files. You'd need to download it to your project and, make the changes, and then upload the file. I know that, for example, Thonny allows this - but I decided against that. Unlike JetBrains IDEs Thonny doesn't have anything like the concept of a "Project" - so it makes sense that you might rely on your sources being on your device only. But with this plugin my intention is to nudge people towards having all source code safely on their computer in their IDE in a project. Making changes to the code on the computer and then uploading it to the device. The upload algorithm is highly optimized - skipping already optimized files, utilizing the REPL interface to transfer files as fast as the serial/WebREPL communication allows and there are features like the synchronization option in run configurations that allow you to work in your IDE and then ensure all changes and file deletions get propagated onto the board with one click. I've gone into more detail in a different discussion #22, some of the information about uploads is outdated, as the upload feature has been finalized and fully documented, but it could be of interest. You can also check the documentation to see all of the features that this plugin currently offers. |
Beta Was this translation helpful? Give feedback.
Hello,
no worries, happy to help.
There is no feature for directly editing on-device files. You'd need to download it to your project and, make the changes, and then upload the file.
I know that, for example, Thonny allows this - but I decided against that. Unlike JetBrains IDEs Thonny doesn't have anything like the concept of a "Project" - so it makes sense that you might rely on your sources being on your device only.
But with this plugin my intention is to nudge people towards having all source code safely on their computer in their IDE in a project. Making changes to the code on the computer and then uploading it to the device.
The upload algorithm is highly optimized - skipping alrea…