gitweb: use new Git::Repo API, and add optional caching
Gitweb now uses the Git::Repo API; this change is behavior-preserving,
except for slightly more aggressive error handling; see below.
This patch also adds an optional caching layer for caching repository
data using any Cache::Cache-compatible caching engine (typically
Cache::Memcached). Larger cacheable items, like blobs, snapshots or
diffs, can be cached on disk.
Other minor changes:
- Gitweb would previously accept invalid input and either (a) display
nothing, (b) display an obscure error message, or (c) proceed as
normal since the parameter happens to be unused in the particular
code path used. This has changed in that gitweb will check for
parameter correctness more aggressively, and display meaningful
error messages. This change is only relevant if you manually edit
gitweb's CGI parameters, since gitweb only generates valid links.
- Empty projects:
- Only display summary link for empty projects in project list to
avoid broken links (yielding 404).
- Slim down summary page for empty projects to avoid some broken
links and unnecessary vertical space.
- Sort empty projects at the bottom of the project list when sorting
by last change.
- Add test for empty projects to t9503 (the Mechanize test), now
that there no broken links anymore.
Signed-off-by: Lea Wiemann <LeWiemann@gmail.com>