git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Add new git-remote-hd helper

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Oct 18, 2012, 08:47 UTC
Message-ID
<alpine.DEB.1.00.1210181031320.3049@bonsai2>
In-Reply-To
<CAMP44s2-BCuA5v7jE8S3d-Gg+DxKf6Yte9MvTDBDr4jEkLKZ9g@mail.gmail.com>
Hi Felipe,
On Wed, 17 Oct 2012, Felipe Contreras wrote:
Show 12 quoted lines
> On Wed, Oct 17, 2012 at 8:18 PM, Sverre Rabbelier <srabbelier@gmail.com> wrote:
> > On Wed, Oct 17, 2012 at 11:12 AM, Felipe Contreras
> > <felipe.contreras@gmail.com> wrote:
> >> But fine, lets remove the tests out of the equation (150 lines), the
> >> number of lines of code still exceeds 3000.
> >
> > I don't think it's fair to just look at LOC, git-remote-hg when it was
> > just parsing was fairly simple. Most of the current code is our copy
> > of the python fast-import library which is only used to support
> > pushing to mercurial.
> 
> Well, as a rule of thumb more code means more places for bugs to hide.

Everybody on this list knows that. But it is equally true that more functionality requires more code.

Besides, we are talking about concrete code, so there is no need at all for handwaving arguments. GitHub makes it easy to point at exact line numbers in exact file names in exact revisions, as you know, and we should use that to discuss code.

> It is also quite frankly rather difficult to navigate; very
> spaghetti-like. I have the feeling [...]

Yours truly always welcomes constructive criticism. Other types of criticism, not so much.

As to the functionality you seek: git-remote-hg found in git://github.com/msysgit/git works. It has the following advantages over every other solution, including the one proposed in this thread:

- it works
- no really, it works
- it supports pushes, too
- it matured over a long time
- there are tests
- whenever we fixed bugs, we also added tests for the bug fixes
- it is rock solid
- it is in constant use

Without push support, remote-hg is useless to me. Without regression tests proving that it is rock solid, I will not use remote-hg. And I will not indulge in efforts to duplicate work.

If there are concerns about code style or unnecessary code (insofar it is really unnecessary, testgit for example is not, unless you want to avoid robust regression tests), I will discuss issues and collaborate. If the idea was not to collaborate, but to show off how much shorter code can be when it lacks functionality and proof of robustness I require for my everyday use of the program, dismissing existing code and concepts, less so.

Hth, Johannes

Previous: Felipe ContrerasNext: Felipe Contreras
Message 8 of 27 in “Add new git-remote-hd helper”
  1. Add new git-remote-hd helperFelipe Contreras, Oct 17, 2012
  2. Johannes SchindelinOct 17, 2012
  3. Felipe ContrerasOct 17, 2012
  4. Johannes SchindelinOct 17, 2012
  5. Felipe ContrerasOct 17, 2012
  6. Sverre RabbelierOct 17, 2012
  7. Felipe ContrerasOct 17, 2012
  8. Johannes SchindelinOct 18, 2012
  9. Felipe ContrerasOct 18, 2012
  10. Johannes SchindelinOct 18, 2012
  11. Junio C HamanoOct 18, 2012
  12. Felipe ContrerasOct 18, 2012
  13. Matthieu MoyOct 18, 2012
  14. Felipe ContrerasOct 21, 2012
  15. Johannes SchindelinOct 21, 2012
  16. Felipe ContrerasOct 21, 2012
  17. Jeff KingOct 17, 2012
  18. Felipe ContrerasOct 18, 2012
  19. Felipe ContrerasOct 18, 2012
  20. Sverre RabbelierOct 18, 2012
  21. Felipe ContrerasOct 18, 2012
  22. Johannes SchindelinOct 18, 2012
  23. Felipe ContrerasOct 18, 2012
  24. Felipe ContrerasOct 26, 2012
  25. Felipe ContrerasOct 18, 2012
  26. Michael J GruberOct 18, 2012
  27. Felipe ContrerasOct 18, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.