6 my $etcfile="/etc/ikiwiki/wikilist";
20 print STDERR "warning: $setup does not exist, skipping\n";
23 print "Processing $setup as user ".username()." ...\n";
24 my $ret=system("ikiwiki", "--setup", $setup, @ARGV);
26 print STDERR "warning: processing $setup failed with code $ret\n";
33 return if $user=~/^-/ || $users{$user};
35 my $ret=system("su", $user, "-s", "/bin/sh", "-c", "--", "$0 --nonglobal @ARGV");
37 print STDERR "warning: processing for $user failed with code $ret\n";
44 return unless -e $file;
47 open ($list, "<$file") || die "$file: $!";
52 next if /^#/ || ! length;
53 if (/^([-\w]+)\s+([^\s]+)$/) {
60 if (username() eq $user) {
65 elsif (/^([-\w]+)$/) {
71 my $home=(getpwnam($user))[7];
72 if (defined $home && -d $home) {
73 my $dotfile="$home/.ikiwiki/wikilist";
74 processlist($dotfile);
82 if (@ARGV && $ARGV[0] eq "--nonglobal") {
84 # avoid recursively processing if the wikilist file has a root
91 processlist($etcfile);