News for hackers. Stuff that matters.
Re:Show HN: Instantly visualize any codebase as an interacti... by lor_louis on Friday December 27, 2024 @11:57AM (#42523786)
I tried it on a personal repo and it never ended up generating a diagram.

Might be a bug, so here's the repo. https://github.com/lorlouis/cedit

Re:Show HN: Instantly visualize any codebase as an interacti... by ahmedkhaleel on Friday December 27, 2024 @12:05PM (#42523869)
i see a diagram there now, might've taken a while to load https://gitdiagram.com/lorlouis/cedit
Re:Show HN: Instantly visualize any codebase as an interacti... by billyp-rva on Friday December 27, 2024 @12:53PM (#42524330)
I guess to get the discussion going: the diagrams look nice, but I think the erroneous and missed connections limit their usefulness. In this example, there is a connection from "Line manager" (line.h/.c) to "Memory Allocator" (xalloc.h/.c), but it doesn't look like such a dependency exists in the codebase. Meanwhile, "Syntax Highlighter" does directly import xalloc.h, but there is no dependency shown in the diagram.
Re:Show HN: Instantly visualize any codebase as an interacti... by lor_louis on Friday December 27, 2024 @02:03PM (#42525011)
As the author of the repo I was surprised how close to my mental model the graph was. (I haven't worked on this repo in a while so my mental model is a bit fuzzy)

And yeah it seems to be missing a few connections but the ones that are there are correct line.h depends on str.h which links str.c which depends on xmalloc.c/h.

But had I been a new contributor to the project I would have found the missing links between modules pretty frustrating.

My guess is that the graph is only good enough to give and overview of what things are dependent on what if I were working on a monorepo and I had to justify to my manager that team B needs to do something for us.

I like the idea though, a lot of direct code to graph tools are too noisy and that tends scares non technical people away.