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

Re: GSoC 2010: "Integrated Web Client for git" proposal

From
Jakub Narebski <jnareb@gmail.com>
Date
Apr 19, 2010, 10:43 UTC
Message-ID
<201004191243.24209.jnareb@gmail.com>
In-Reply-To
<20100418195623.GA3563@machine.or.cz>
On Sun, Apr 18, 2010 at 21:56 +0200, Petr Baudis wrote:
> On Sun, Apr 18, 2010 at 07:50:17PM +0200, Jakub Narebski wrote:
Show 7 quoted lines
>> So it is intended, I guess, more like git-instaweb or webmin, not like
>> administrative parts of Girocco (or repo.or.cz), GitHub, Gitorious or
>> InDefero.  Probably authentication and authorization would not be needed
>> then, if it is to be run as web interface but locally...
> 
> If the project is a success, I wanted to use it for mob branch editing
> on repo.or.cz. It could also be used as open-source Gist alternative.

For that you would need editing file / editing contents action, but this is explicitely excluded in current version of Pavan's proposal :-(

> But it needs to be coded so that it does not require an actual checked
> out copy (which shouldn't be too much hassle).

It would require using 'git hash-object -t blob -w --stdin' (from body submitted via POST from textarea) plus 'git update-index --cacheinfo'. There is however complication that you would need to do open2/open3 because git-hash-object would require bidirectional communication unless you would use temporary file (command_bidi_pipe in Git.pm, untested).

Show 7 quoted lines
>> Currently to install gitweb you have to copy *one* script, and a few
>> static files (2 x image, CSS, JavaScript).  You can configure it using
>> "make gitweb" with appropriate options, you can simply edit gitweb script,
>> or you can leave this to the gitweb config file.
> 
> I don't really think things can get *any* more complicated than "also
> copy over this directory recursively", do they?
Let's check what gitweb/INSTALL says currently
        $ make prefix=/usr gitweb             ;# as yourself
        # cp gitweb/git* /var/www/cgi-bin/    ;# as root
WTF with 'gitweb/git*' glob?  
Ah, later there is "Build example", which is
 - To install gitweb to /var/www/cgi-bin/gitweb/ when git wrapper
   is installed at /usr/local/bin/git and the repositories (projects)
   we want to display are under /home/local/scm, you can do
        make GITWEB_PROJECTROOT="/home/local/scm" \
             GITWEB_JS="/gitweb/gitweb.js" \
             GITWEB_CSS="/gitweb/gitweb.css" \
             GITWEB_LOGO="/gitweb/git-logo.png" \
             GITWEB_FAVICON="/gitweb/git-favicon.png" \
             bindir=/usr/local/bin \
             gitweb
        cp -fv ~/git/gitweb/gitweb.{cgi,js,css} \
               ~/git/gitweb/git-{favicon,logo}.png \
             /var/www/cgi-bin/gitweb/
WTF with '~/git/gitweb'... ehh, that one is mine, I guess...
So additional step would be
        cp -fvR gitweb/lib /var/www/cgi-bin/    ;# as root
I hope that we could make installing gitweb as easy as
        make webscriptdir=/var/www/cgi-bin/ \
             gitweb-install
 
or in more complicated case (gitweb modules not installed in cgi-bin)
        make webscriptdir=/var/www/cgi-bin/gitweb \
             GITWEB_BASE="/gitweb/" \
             GITWEBPERLLIB=/usr/local/lib/perl5 \
             gitweb-install

or something like that (I do not know any standard for the name of build configuration variable which tells where to install web aplication; do you?)

Show 23 quoted lines
>> Also there is a question _how_ to split gitweb into modules, 
>> e.g. whether to follow SVN::Web example on how gitweb (Git::Web?) should
>> be split.  But I guess any splitting would suffice; we need to provide
>> a way to build and install split gitweb.  
>> 
>> Split can be as simple as:
>> 
>>   Makefile, or Makefile.PL, or Build.PL
>>   gitweb.perl
>>   static/git-logo.png
>>   static/git-favicon.png
>>   static/gitweb.css
>>   static/gitweb.js
>>   lib/Gitweb/Utils.pm   (Gitweb::Utils)
>>   lib/Gitweb/Editor.pm  (Gitweb::Editor, for GSoC2010, if it gets accepted)
> 
> Exactly! I think we can do this reasonably incrementally; if something
> is not working out, we can move it again later. Let's not overengineer
> stuff. I think it would make sense to just split out something like
> Gitweb::Git (for Git invocations), Gitweb::CGI (for CGI parsing and
> HTML output toolkit) and perhaps Gitweb::Util for misc. stuff. Then,
> if we feel like it, maybe we can start splitting out things more, like
> Gitweb::CGI::Blame, but I don't think that's even neccessary for now.
Well, I would perhaps start simply with 
  gitweb.perl
  lib/Gitweb.pm

We can modify file organization later; what's important is the build infrastructure (even if it is instruction in gitweb/INSTALL).

-- 
Jakub Narebski
Poland
Previous: Petr BaudisNext: Petr Baudis
Message 22 of 39 in “GSoC 2010: "Integrated Web Client for git" proposal”
  1. Christian CouderApr 15, 2010
  2. Jakub NarebskiApr 18, 2010
  3. Petr BaudisApr 18, 2010
  4. Jakub NarebskiApr 18, 2010
  5. Petr BaudisApr 18, 2010
  6. Pavan Kumar SunkaraApr 18, 2010
  7. Jakub NarebskiApr 18, 2010
  8. Petr BaudisApr 18, 2010
  9. Pavan Kumar SunkaraApr 19, 2010
  10. Matthieu MoyApr 19, 2010
  11. Junio C HamanoApr 19, 2010
  12. Pavan Kumar SunkaraApr 19, 2010
  13. Petr BaudisApr 19, 2010
  14. Matthieu MoyApr 19, 2010
  15. Pavan Kumar SunkaraApr 19, 2010
  16. Matthieu MoyApr 19, 2010
  17. Petr BaudisApr 19, 2010
  18. Pavan Kumar SunkaraApr 19, 2010
  19. Petr BaudisApr 20, 2010
  20. Jakub NarebskiApr 18, 2010
  21. Petr BaudisApr 18, 2010
  22. Jakub NarebskiApr 19, 2010
  23. Petr BaudisApr 19, 2010
  24. Pavan Kumar SunkaraApr 19, 2010
  25. Petr BaudisApr 20, 2010
  26. Jakub NarebskiApr 20, 2010
  27. Pavan Kumar SunkaraApr 21, 2010
  28. Petr BaudisApr 22, 2010
  29. Junio C HamanoApr 22, 2010
  30. Petr BaudisApr 23, 2010
  31. Junio C HamanoApr 23, 2010
  32. Pavan Kumar SunkaraApr 22, 2010
  33. Christian CouderApr 23, 2010
  34. Pavan Kumar SunkaraApr 23, 2010
  35. Pavan Kumar SunkaraApr 19, 2010
  36. Jakub NarebskiApr 19, 2010
  37. Pavan Kumar SunkaraApr 19, 2010
  38. Jakub NarebskiApr 19, 2010
  39. Pavan Kumar SunkaraApr 20, 2010

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.