Re: [PATCH 1/3] git-help: add -i|--info option to display info page.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Le dimanche 2 décembre 2007, Junio C Hamano a écrit :
> Pascal Obry <pascal@xxxxxxxx> writes:
> >
> > If would be nice if this could be more generic. For example I'd like to
> > use Emacs woman mode instead of info. Can't we have something like
> >
> >    $ git help --ext XXX
> >
> > "ext" standing for external and calling whatever command recorded into
> > .gitconfig for example ?
>
> There is a bit of conflict here.  We could do that and make the
> implementation of "ext" command responsible to transform "commit" in
>
> 	$ git help --ext commit
>
> to the location of manual page (or formatted HTML page, or node in the
> info documentation).  git itself does not need to know much about where
> the help material is in such an implementation.
>
> But Christian's series is about making such "ext" thing easier to write.
> No matter what kind of web browser is used, it needs to be told where
> the preformatted HTML page for git-commit command is (and it does not
> care where git-commit.1 manpage is found or what the node is called in
> git.info document).  It makes it a bit too limiting by defining -w (web)
> and -i (info) upfront without offering -x (ext), but we need to start
> somewhere.

Yeah, I think that the user should be able to choose both the format and the 
tool used for help pages. And that we should start to make more popular 
formats and tools work well first. That means HTML with web browser first.
(And yeah, my first patch is about "info", but it was a very low hanging 
fruit.)

In the end we may want to support many other tools and format. For example:

"git help --format=man --tool=konqueror log" or
"git help -m --tool=konqueror log"

would launch something like: "konqueror 'man:git-log(1)'"

But of course, to be able to do that, we have to know how each tool is 
working, because the syntax has a good chance to be different in each case.

If we provide a -x|--ext upfront and we don't check if we know about the 
tool the user wants to use, then we will not get information about how to 
properly use the tool and we may break without any meaningfull error for 
many of them.

So if someone has information about how "woman" or other web or man or info 
browser can be used, I will be glad to collect it and eventually use it to 
try to make "git help" work for the tool (though I don't promise to test 
them on platform other than Linux), but I will focus on web formats and 
tools first. Patches are welcome too. 

Thanks in advance,
Christian.

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux