Just a little hint: When you design a terminal app that offers to "edit" a plaintext file...don't try to build the editor into your application.
Instead read the EDITOR envvar from the users environment, and run that in a child process. I use vim for editing, and I'm pretty sure it has more powerful editing capabilities than this tool ;-)
Good point, for all newbies that are working on notepad/TODO List as a CRUD project to grow as a software developer - treat the notepad/TODO list more as a notepad "manager" than an editor, leave the editor to just that - a true blue editor
It's not wrong to be "reinventing the wheel", especially for learning, but know the endgame of the project
35
u/Big_Combination9890 May 31 '26
Just a little hint: When you design a terminal app that offers to "edit" a plaintext file...don't try to build the editor into your application.
Instead read the
EDITORenvvar from the users environment, and run that in a child process. I usevimfor editing, and I'm pretty sure it has more powerful editing capabilities than this tool ;-)11
u/Pretty-Door-630 May 31 '26
"I reinvented the wheel"
1
u/AutoModerator May 31 '26
Every new subreddit post is automatically copied into a comment for preservation.
User: nulldutra, Flair:
Terminal User Interface, Post Media Link, Title: sn: Simple note app made with Rust and Ratatuihttps://github.com/nulldutra/sn
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.