From: Junio C Hamano <gitster@pobox.com>
To: "Steven Walter" <stevenrwalter@gmail.com>
Cc: "Petr Baudis" <pasky@suse.cz>,
"Jakub Narebski" <jnareb@gmail.com>,
"Elijah Newren" <newren@gmail.com>,
"Govind Salinas" <govind@sophiasuchtig.com>,
git@vger.kernel.org
Subject: Re: Revert behavior
Date: Tue, 09 Sep 2008 15:10:16 -0700 [thread overview]
Message-ID: <7v63p53r93.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <e06498070809091439q1c543807pd6e74b7ada32434@mail.gmail.com> (Steven Walter's message of "Tue, 9 Sep 2008 17:39:46 -0400")
"Steven Walter" <stevenrwalter@gmail.com> writes:
> I agree with this. That's part of the problem I have with schemes to
> make commands work similarly to other SCMs. If you give, for example,
> eg a mode to act like "svn revert;" that all well and good until the
> user runs "git diff" and you're made a liar. In svn, there would be
> no diff, because the files all match their respective upstream
> versions. In git, you would see changes because the file no longer
> matches the last commit.
If you implement "eg svn-like-revert" to checkout the given paths out of
the last commit, instead of the index, shouldn't that be sufficient?
> It it a delicate balance to have the user interface match both the
> mental model of the user and the storage model of the tool.
I do not think it is that simple.
You could match the user experience to the mental model of the other tool,
by hiding the differences and insisting that people use only your tool.
The real issue is that you may need to castrate the underlying tool in
certain places if its world model is richer than the model the tool you
are trying to emulate. Ignoring the index by making "svn-like-revert"
work on both index and the working tree file at the same time is a good
example of that.
If the castrated feature is truly too exotic and rarely useful for mere
mortals, that strategy works very well. A simpler world model that lets
you do the same job equally well is a much better UI than the needlessly
complex one. But if that is not the case, your users would eventually
graduate out of the training wheel and would want to use that feature you
hid away from them, and at that point they need to unlearn parts of the
simpler world model and shift their world view somewhat. If you try to
support both classes of users, that become hard.
I have to admit that I used to have my own Porcelain when git was very
young, not because I did not like existing UI git had, but there was no UI
back then. "My own" Porcelain is relatively easy -- I have to only cater
to my own needs and need to expose only the limited subset of the features
the underlying tool (in this case, the storage model and history view of
git) I understand, and nobody complains that he cannot access the parts I
do not expose to him. Growing it to satisfy wider audience is the hard
part.
next prev parent reply other threads:[~2008-09-09 22:11 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-09 13:26 Revert behavior [Was: Re: [ANNOUNCE] yap: Yet Another (Git) Porcelain] Elijah Newren
2008-09-09 13:38 ` Jakub Narebski
2008-09-09 16:37 ` Govind Salinas
2008-09-09 17:29 ` Steven Walter
2008-09-09 20:19 ` Elijah Newren
2008-09-09 21:50 ` Steven Walter
2008-09-09 23:02 ` Elijah Newren
2008-09-09 20:20 ` Elijah Newren
2008-09-09 21:28 ` Petr Baudis
2008-09-09 21:39 ` Steven Walter
2008-09-09 22:10 ` Junio C Hamano [this message]
2008-09-09 22:30 ` Revert behavior Steven Walter
2008-09-09 22:51 ` Elijah Newren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7v63p53r93.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=govind@sophiasuchtig.com \
--cc=jnareb@gmail.com \
--cc=newren@gmail.com \
--cc=pasky@suse.cz \
--cc=stevenrwalter@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).