[OT] Re: CTFE Status
Nick Sabalausky via Digitalmars-d
digitalmars-d at puremagic.com
Wed Nov 9 20:07:21 PST 2016
On 11/08/2016 02:11 PM, Antonio Corbi wrote:
>
> Maybe this one is useful for you:
>
> http://eagain.net/articles/git-for-computer-scientists/
On 11/08/2016 03:01 PM, H. S. Teoh via Digitalmars-d wrote:
> Nothing immediately comes to mind, but thanks to Dr. Google, I found
> this page that's sorta helpful:
>
> http://ericsink.com/vcbe/html/directed_acyclic_graphs.html
>
> And perhaps these:
>
> http://eagain.net/articles/git-for-computer-scientists/
> http://marklodato.github.io/visual-git-guide/index-en.html
>
Ok, so it looks like each node in the DAG is a commit. I'll definitely
have to read further. Thanks, both.
Although I have my doubts it would explain all the issues I've hit upon
with git's CLI. For example: I don't see why annotated tags aren't the
default. Or why non-annotated ones even exist at all. When I made
<https://github.com/Abscissa/gen-package-version>, I noticed that it'll
*only* work if the version tags are "annotated" tags. Because otherwise
"git describe" doesn't retrieve the tag. Doesn't even matter one bit
*what* the tag's message is, just that it exists. Why? Who knows! It's git!
So it means that unlike hg users, who can just make their tags with "hg
tag v1.2.0" and everything's fine, git users can't just say "git tag
v1.2.0". In git, making a tag like that will work for SOME use-cases but
not all. Instead, git users have to use the less-obvious "git tag -a
v1.2.0 -m '...whatever...'" incantation or else "git describe" won't
freaking work right, therefore gen-package-version won't be able to
determine the working copy's current tag name.
So then why do the non-annotated tags even exist? Why not just have
"annotated" tags with *optional* messages? Why even have the "-a" flag
for "git tag" at all? Why not have "git tag tagname" make a tag with no
message, and "git tag tagname -m '...'" to make a tag with a message,
and ditch the whole "-a" nonsense? Because it wouldn't be stupid enough
that way? I don't get it.
Its things like that. I'd be surprised if that has much to do with git's
nature as a "dumb" DAG tool. It's just the general good-design principle
of "The thing you *want to* or *should* do or *expect* 99% of the time
should be the DEFAULT, not the obscure incantation".
> Or maybe I should write my own article about git being based on a DAG.
> :-P
>
You should! :)
I've given a lot of thought over the years to the concepts of learning
and teaching. As I see it, the big key to both is taking seemingly
complex things, finding a model that makes them simple, and then finding
a way to communicate that model in a way that preserves its inherent
simplicity.
The big key there is actually having a simple, well-understood mental
model, and it sounds like you have that on this, so I'd love to read
anything you'd have to write about it.
More information about the Digitalmars-d
mailing list