04 july 2021
Worked on the notes utility again finally, figured out how to open files in an existing editor. Probably better ways to do it but os.system is all we could find that reliably worked, so we set it up so that it checks if an EDITOR env variable is set. If it is, it uses that. If not, it defaults to nano for Linux and Mac, and Notepad for Windows. In the future, we'll have it query what editor someone wants to use on first login, then allow it to be changed in the settings. For now, this works, and implementing that later won't be an issue since it's set with a variable to begin with. Would also like to implement a means of checking what editors are installed and presenting those as the options- would be neat. May be stuck checking for common editors but maybe there's some way to query it? Who knows? Would be neat. Probably not, but we can dream.
Also shortened and tidied up the code a bit, cleaned out some redundancy that really didn't need to be there. Figured out how to get variables to work across files, so functions are being moved into their own files where reasonable, and doing so is helping us spot things that could be fixed or significantly improved. Still probably going to look back at it later and cringe, but oh well. At least it's commented. We learned our lesson there a long time ago with JS. COMMENT YOUR CODE. Your future self and/or other maintainers will thank you when they know what that variable does and why you wrote it the way you did. Much better than playing the game of "well, let's delete this and see what breaks" and hoping it only breaks something small and specific so you know what it does.
Still perpetually confused by "foo" being a thing. It's such a strange, unhelpful filler. It doesn't help you know what goes there, just kind of fills the space. That has its uses but we usually don't see it used helpfully.
Gruvbox is making this a joy by the way- it's amazingly readable without eyestrain. Massive improvement over Nord (as pretty as Nord is). Really love the green in particular. It's so pleasing.
Not much else to say at the moment. People are still shooting off fireworks and it's not fun. Way too loud and hard to get to sleep, and it's not even the 4th yet. And it's a fire hazard to boot between the heat wave and everything being dry to begin with. Honestly don't get the appeal.
Oh, and to fellow LGBTQ+ folks- happy Wrath Month. :P It's also disability pride month, so that's neat.