diff options
author | Lars Hjemli | 2007-06-29 20:32:08 +0200 |
---|---|---|
committer | Lars Hjemli | 2007-06-29 20:32:08 +0200 |
commit | 16a3d2779ccd56bf7954d98da547247d8796544b (patch) | |
tree | 86d2ed41adc3de842c7518d614ea49ca0200e4d2 /cgit.c | |
parent | Add version info from git-describe (diff) | |
parent | Add ofs argument to cgit_log_link and use it in ui-log.c (diff) | |
download | cgit-16a3d2779ccd56bf7954d98da547247d8796544b.tar.gz cgit-16a3d2779ccd56bf7954d98da547247d8796544b.zip |
Merge branch 'lh/menu'
* lh/menu: Add ofs argument to cgit_log_link and use it in ui-log.c Add trim_end() and use it to remove trailing slashes from repo paths Do not include current path in the "tree" menu link Add setting to enable/disable extra links on index page Change S/L/T to summary/log/tree Change "files" to "tree" Include querystring as part of cached filename for repo summary page Add more menuitems on repo pages
Diffstat (limited to 'cgit.c')
-rw-r--r-- | cgit.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/cgit.c b/cgit.c index 11dff76..d9a03c2 100644 --- a/cgit.c +++ b/cgit.c | |||
@@ -26,13 +26,15 @@ static int cgit_prepare_cache(struct cacheitem *item) | |||
26 | } | 26 | } |
27 | 27 | ||
28 | if (!cgit_cmd) { | 28 | if (!cgit_cmd) { |
29 | item->name = xstrdup(fmt("%s/%s/index.html", cgit_cache_root, | 29 | item->name = xstrdup(fmt("%s/%s/index.%s.html", cgit_cache_root, |
30 | cache_safe_filename(cgit_repo->url))); | 30 | cache_safe_filename(cgit_repo->url), |
31 | cache_safe_filename(cgit_querystring))); | ||
31 | item->ttl = cgit_cache_repo_ttl; | 32 | item->ttl = cgit_cache_repo_ttl; |
32 | } else { | 33 | } else { |
33 | item->name = xstrdup(fmt("%s/%s/%s/%s.html", cgit_cache_root, | 34 | item->name = xstrdup(fmt("%s/%s/%s/%s.html", cgit_cache_root, |
34 | cache_safe_filename(cgit_repo->url), cgit_query_page, | 35 | cache_safe_filename(cgit_repo->url), |
35 | cache_safe_filename(cgit_querystring))); | 36 | cgit_query_page, |
37 | cache_safe_filename(cgit_querystring))); | ||
36 | if (cgit_query_has_symref) | 38 | if (cgit_query_has_symref) |
37 | item->ttl = cgit_cache_dynamic_ttl; | 39 | item->ttl = cgit_cache_dynamic_ttl; |
38 | else if (cgit_query_has_sha1) | 40 | else if (cgit_query_has_sha1) |