ArchivePage 2 of 18

New GitPHP features

I have some new GitPHP features developed.  They are in the current git repository and just need some more testing time before a new release can come out (hint, hint – testing this and reporting bugs would help me a great deal).  Off of the top of my head, changes are:

  • Mime type support.  When viewing a blob, if it recognizes the mime type as an image, it will embed and display the image using a data uri rather than dumping the binary content.  This is only done for images, though – there isn’t a good way to embed other binary file formats.  It supports pecl-fileinfo (which was merged into PHP in 5.3), the “file” command on *nix machines, and just checking the file extension.  Based on work by Trevino
  • Searching of commit logs, authors, committers, filenames, and file contents
  • Blob diffs show the filenames instead of the hashes to be more readable
  • Fixed blank entries that appeared at the end of the log/shortlog
  • Added a link to the tree from the main project list
  • Some performance fixes for projects with many commits
  • Snapshots can be sent as tar.gz now
  • templates_c directory created for you now, you just need to change the permissions

Also, I’m going to be writing up a README, because it looks like the installation and the handling of templates_c has really confused people.

I’ve seen suggestions of symlinking templates to templates_c, which is not right at all, they are not the same thing.  (I saw this posted on a Chinese website, and I don’t know Chinese, so I can’t tell the person the right way)

Your templates directory holds the templates that I’ve written – essentially the layout of the page, without any of the data in it.  Your templates_c directory contains compiled templates – that is, smarty has taken the templates (*.tpl) from the templates directory, inserted all the php code it takes to make them work, and stored the php file that resulted from that template in templates_c, for use when serving up pages.  Compiled templates are temporary.  Actual templates, tpl files, are not temporary, they were written by me and come with the distribution.  If you symlink the two directories together, you have one directory with a mess of compiled and uncompiled templates.

I admit that a readme would have explained this a little better, which is why I’m doing it for the next version.  Here is how your directory structure is supposed to look:

gitphp/index.php

gitphp/config/gitphp.conf.php

gitphp/include/*.php

gitphp/templates/*.tpl <- These are the templates written by me that come with gitphp

gitphp/templates_c/*.tpl.php <- These are the compiled templates that get written, so this directory must be writable by the web server


If you don’t have a global copy of smarty installed, you can install it locally:

gitphp/smarty/Smarty.class.php

gitphp/smarty/internals/*

gitphp/smarty/plugins/*


If you want to use geshi:

gitphp/geshi/geshi.php

gitphp/geshi/geshi/*.php


I’m planning on releasing the new version maybe this weekend or next.  Whatever testing you can do with the snapshot before then will help everyone, because that means less bugs in the actual release.  You can report them using Mantis.

Gears of War 2 Fail

Gears of War 2’s really shitty lag, plus trying to check the Tac/Com, yielded this fail:
gears2_fail

And this wasn’t just a flash of discoloration.  It hung around long enough for me to take a picture – in fact, it hung around until the next round.  And that black box on the left isn’t something hanging over my tv, it’s a graphical glitch.

They really need to fix the lagginess in gears.  The lag, as well as other issues (such as the game terminating for everyone when the host leaves), would be circumvented if they let the game switch to a new host the way Halo 3 does.

Xbox 360 Hardware Sucks

This is the second console that’s died on me.  It always freezes on me in games.  But of course, this RRoD is not reproducible every time you turn it on, which means that Microsoft won’t extend the warranty to 3 years to cover me, even though I’ve got a useless console.

RRoD xbox 360 elite

And I hear that RRoD’s are uncommon for Elites, too.  The towel trick helped for a little bit, but as with my first console, it’s kind of stopped being effective.