diff options
author | Eric Wong <e@80x24.org> | 2022-10-08 08:24:45 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2022-10-09 16:48:37 +0000 |
commit | 2bc26fececd03705c68c1968f95a2d199bafec29 (patch) | |
tree | 900a1080687adc7ec7877e6d9123a570f4b14804 /lib/PublicInbox/Config.pm | |
parent | 8bd0fadfe7fcc7c44a3478ffefede71f24319441 (diff) | |
download | public-inbox-2bc26fececd03705c68c1968f95a2d199bafec29.tar.gz |
This also ensures we won't waste CPU cycles on snapshots which aren't configured if somebody attempts them by guessing URLs.
Diffstat (limited to 'lib/PublicInbox/Config.pm')
-rw-r--r-- | lib/PublicInbox/Config.pm | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/PublicInbox/Config.pm b/lib/PublicInbox/Config.pm index 5cdf182e..a430cd5c 100644 --- a/lib/PublicInbox/Config.pm +++ b/lib/PublicInbox/Config.pm @@ -325,6 +325,8 @@ sub parse_cgitrc { } elsif (m!\A(?:css|favicon|logo|repo\.logo)=(/.+)\z!) { # absolute paths for static files via PublicInbox::Cgit $self->{-cgit_static}->{$1} = 1; + } elsif (s!\Asnapshots=\s*!!) { + $self->{'coderepo.snapshots'} = $_; } } cgit_repo_merge($self, $repo->{dir}, $repo) if $repo; |