News for hackers. Stuff that matters.
Re:Code Is Not Literature by gavinhoward on Tuesday August 15, 2023 @11:38AM (#37135287)
I am one of the programmers that like to make dissectable code. In fact, I've included a whole manual, with my most famous project, that is entirely about dissecting the code. [1]

And I will certainly do the same in my current project.

Some of the most delightful moments I've had are when someone emails me with questions that indicate they've read my code, such as mentioning specific comments or asking about something in that dissection manual.

I consider it a badge of honor if people think my code is good enough to study.

[1]: https://git.gavinhoward.com/gavin/bc/src/commit/75cf2e3358b5...

Re:Code Is Not Literature by Pr0ject217 on Tuesday August 15, 2023 @12:12PM (#37135726)
Inspiring
Re:Code Is Not Literature by hinkley on Tuesday August 15, 2023 @12:15PM (#37135764)
I think if we sat over beers we’d find some common ground.

I sometimes like to think of good code as short stories. Badly factored code is like a novelization of a story. Too long with too many side quests and you only find out at the end that the butler didn’t do it. Whether that pleases or infuriates is a gamble.

Excessively terse code that requires broad life experiences to unpack? It’s interpreted by every observer to mean something different. Like a haiku, or even a song, the story being told is unclear. Beautiful, moving, but unclear.

I much prefer short stories. A little flavor text, but no time for more than two clever ideas at once.

Re:Code Is Not Literature by gavinhoward on Tuesday August 15, 2023 @12:31PM (#37135982)
I think we would find common ground, yes. That would be fun! But I'll be the designated driver and stay sober. :)
Re:Code Is Not Literature by HankB99 on Tuesday August 15, 2023 @12:50PM (#37136210)
I've often thought that code should tell a story about what the system is supposed to do and if the story is not clear, that will probably be reflected in a system that does not work well.
Re:Code Is Not Literature by jklinger410 on Tuesday August 15, 2023 @12:52PM (#37136226)
> I think if we sat over beers we’d find some common ground.

I love this response and wish every disagreement could start with this perspective.

Re:Code Is Not Literature by manvillej on Tuesday August 15, 2023 @01:05PM (#37136420)
code is such a weird thing. Its business logic, its infrastructure, its short stories, its documentation. I also think of it like investments and debts

its so many things and so complicated.

Re:Code Is Not Literature by timacles on Tuesday August 15, 2023 @03:15PM (#37138048)
Code is just an analog for life and its duality.

Its all those things and none of those things.

Code is code. Humans are the ones with the obsession of abstracting and categorizing things to make ourselves feel better. In reality, none of those things actually exist

Re:Code Is Not Literature by hinkley on Tuesday August 15, 2023 @03:17PM (#37138070)
It's also really bad contract law.
Re:Code Is Not Literature by ljm on Tuesday August 15, 2023 @07:45PM (#37140879)
when you think you have a good story to tell you will make it work no matter what.

Epic poems like The Iliad or Baghavad Ghita or the bible are not immaculately retold from scratch but depend heavily on repetition and context cues.

Code is the same.

Re:Code Is Not Literature by chromanoid on Tuesday August 15, 2023 @12:38PM (#37136070)
I quite like https://docs.arc42.org/ for a good framework regarding documentation of software projects. Section 8 is especially useful https://docs.arc42.org/section-8/ with nice topic suggestions.
Re:Code Is Not Literature by chrisdave on Tuesday August 15, 2023 @02:32PM (#37137553)
I like that the whole project seems to be motivated out of spite for a particular individual on IRC.
Re:Code Is Not Literature by gavinhoward on Tuesday August 15, 2023 @02:45PM (#37137681)
Heh, yeah.

Although that person was actually mostly right about me; that project is the only real success I've had in my line except getting married and staying married. (And quite frankly, that's just because my wife seems to like me more than I deserve.)

Re:Code Is Not Literature by systems_glitch on Tuesday August 15, 2023 @04:58PM (#37139204)
Family > computers. Besides, what portion of people get any of their programs pulled into even a single other project?! An accepted PR is more than 99% of the world will ever contribute to software development!
Re:Code Is Not Literature by systems_glitch on Tuesday August 15, 2023 @04:56PM (#37139189)
We probably owe the existence of a nontrivial amount of software to a lot of stupid pointless IRC arguments :P
Re:Code Is Not Literature by alexvoda on Tuesday August 15, 2023 @05:09PM (#37139311)
Just had a look. That is a wonderful intro document for your code base.
Re:Code Is Not Literature by gavinhoward on Tuesday August 15, 2023 @05:36PM (#37139580)
Thank you very much!