diff options
author | Eric Wong <e@80x24.org> | 2018-12-25 03:44:57 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2018-12-27 23:56:15 +0000 |
commit | 4f95d67d882eec0f058dd62ee83e8b9c973f4a26 (patch) | |
tree | e634516000ea7321c2a7157c019196c38fc094c8 /script | |
parent | a34ad831a831600406725e65ededdf2ec96727fc (diff) | |
download | public-inbox-4f95d67d882eec0f058dd62ee83e8b9c973f4a26.tar.gz |
It is redundant to set default values in the public-inbox config file. Lets not clutter up users' screens when they view or edit the config file.
Diffstat (limited to 'script')
-rwxr-xr-x | script/public-inbox-init | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/script/public-inbox-init b/script/public-inbox-init index 5e961c80..1aec799c 100755 --- a/script/public-inbox-init +++ b/script/public-inbox-init @@ -76,7 +76,6 @@ if (-e $pi_config) { } } close $fh or die "failed to close $pi_config_tmp: $!\n"; -$indexlevel ||= 'full'; my $pfx = "publicinbox.$name"; my @x = (qw/git config/, "--file=$pi_config_tmp"); @@ -125,7 +124,10 @@ foreach my $addr (@address) { } x(@x, "$pfx.url", $http_url); x(@x, "$pfx.mainrepo", $mainrepo); -x(@x, "$pfx.indexlevel", $indexlevel); + +if (defined($indexlevel)) { + x(@x, "$pfx.indexlevel", $indexlevel); +} rename $pi_config_tmp, $pi_config or die "failed to rename `$pi_config_tmp' to `$pi_config': $!\n"; |