Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> I had to remove some interconnections, because there were some cycles.

Because git doesn't allow cycles? Then as cool as this is (and it's very cool), perhaps this isn't an appropriate tool for this purpose.

Or might the natural, human-built cycles be expressable as subrepositories?



> perhaps this isn't an appropriate tool for this purpose

Would Mercurial be more appropriate, or do you think DVCS are simply not an ideal way of mapping metro lines?


In response to your siblings, I think this use of git is delightful, and I don't want to take away from that. I love that people play with these tools.

As to Mercurial being better, I don't know but I doubt it.

My comment isn't even really directed at the appropriateness of DVCS specifically. It's just a general observation of using an acyclic tool to describe a network with cycles. We do that a lot, sometimes for play, sometimes for practicality, and sometimes because we just flip the fuckit bit. http://thechive.com/2009/11/11/there-i-fixed-it-23-photos/


I'm pretty sure scrollaway's comment is sarcastic :D


quite :)


Better try Source Safe :)


Mercurial is also an interface to a directed acyclic graph. If the graph is cyclic, Mercurial would also not be an appropriate tool to model it.


The object model of git is described as a directed acyclic graph, thus by definition, it has no cycles, which wouldn't make sense for a version control system anyway.

That said, this is most likely just meant as a fun visualization, because the visualization does look like a railway map.


> perhaps this isn't an appropriate tool for this purpose

Isn't the sole reason this is on HN, on the frontpage, exactly the fact that git and it's graphs aren't appropriate at all for drawing metrolines and yet somebody though of it and then did it as well?


I think the git file structure technically supports cycles, you just need to break sha-1 to do it.

I don't think the tooling is made for it either.


.git/info/grafts allows creating cycles without having to break sha-1.


The low level tooling can do that. When creating a commit you can pass arbitrary parents to the command. But as you said you'd need to break sha1.

> git commit-tree <tree> [(-p <parent>)...] < changelog


Well, you can do branches and multiple-parent merges, so as long as you don't care about directionality mapping to commits you can express the structure on connection, at least.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: