* About as default page
[not found] <mailman.0.1404411897.25081.cgit@lists.zx2c4.com>
@ 2014-07-03 18:41 `
0 siblings, 0 replies; only message in thread
From: @ 2014-07-03 18:41 UTC (permalink / raw)
Hello everybody.
I recently installed cgit and made a little change from default project
page for the about page (if exists).
In master you have the following url :
git.domain.tld/project/ -> redirect to summary
git.domain.tld/project/summary -> redirect to summary
git.domain.tld/project/about -> redirect to about
with my patch the same urls acts as follow :
if an about page exists : git.domain.tld/project/ -> redirect to about
if no about page exists : git.domain.tld/project/ -> redirect to summary
the patch is very simple[1] and relies on a virtual page named ? main ?
due to cgit limitations (when a project is loaded, we don't know yet if
an about exists or not, so we can't decide if the request to / should be
executed as /summary or /about. We only get this information when we
have begun to process the request. So I created a redirection to a new
action (? main ?), wich act as a proxy redirection).
Feel free to include this patch in the master branch, my repo is open ^^
[1]
http://git.chimrod.com/cgit/commit/?h=about&id=36dd30afed43323dde1aeea0490e86f2db7a2c1d
--
S?bastien Dailly
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2014-07-03 18:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <mailman.0.1404411897.25081.cgit@lists.zx2c4.com>
2014-07-03 18:41 ` About as default page
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).