Re: [PATCH] gitweb: Show project README if available

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

 



Dear diary, on Tue, Oct 10, 2006 at 11:00:41AM CEST, I got a letter
where Jakub Narebski <jnareb@xxxxxxxxx> said that...
> Petr Baudis wrote:
> 
> > +                       print $_ while (<$fd>);
> 
> Wouldn't it be better to do it in slurp mode, i.e.
> 
>         {
>                 local $/
>                 print <$fd>;
>         }
> 
> instead?

I personally prefer my version as it prevents allocation of big chunks
of memory, but I don't really care in this particular case.

> Do you assume that README is HTML fragment? If not, you should esc_html it.
> Besides, we have similar (if assumed to have one line only) file, namely
> description.

I _do_ assume that README is HTML fragment (so that you can use links,
non-proportional fonts, etc.), this is a difference to the description
file.

> Besides, README for a project can be huge. Git README has 589 lines!

This is not /README from the tree but README in the .git directory, so
it may not be the same. In the repo.or.cz admin interface, I limit
README to 8kb.

-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
#!/bin/perl -sp0777i<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<j]dsj
$/=unpack('H*',$_);$_=`echo 16dio\U$k"SK$/SM$n\EsN0p[lN*1
lK[d2%Sa2/d0$^Ixp"|dc`;s/\W//g;$_=pack('H*',/((..)*)$/)
-
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]