summaryrefslogtreecommitdiff
path: root/simple.setup
blob: 7c2e635c88e83e815c9f6dca202d45452edc03a6 (plain)
  1. #!/usr/bin/perl
  2. # Simple ikiwiki setup.
  3. #
  4. # This setup file causes ikiwiki to create a wiki, check it into revision
  5. # control, generate a setup file for the new wiki, and set everything up.
  6. #
  7. # Just run: ikiwiki -setup /etc/ikiwiki/simple.setup
  8. #
  9. # By default, it asks two questions, and confines itself to the user's home
  10. # directory. You can edit it to change what it asks questions about, or to
  11. # modify the values to use site-specific settings.
  12. require IkiWiki::Setup::Automator;
  13. our $wikiname=IkiWiki::Setup::Automator::ask(
  14. "What will the wiki be named?", "wiki");
  15. our $rcs=IkiWiki::Setup::Automator::ask(
  16. "What revision control system to use?", "git");
  17. our $hostname=`hostname -f`; chomp $hostname;
  18. IkiWiki::Setup::Automator::import(
  19. wikiname => $wikiname,
  20. rcs => $rcs,
  21. srcdir => "$ENV{HOME}/$wikiname",
  22. destdir => "$ENV{HOME}/public_html/$wikiname",
  23. repository => "$ENV{HOME}/$wikiname.$rcs",
  24. setupfile => "$ENV{HOME}/$wikiname.setup",
  25. url => "http://$hostname/~$ENV{USER}/$wikiname",
  26. cgiurl => "http://$hostname/~$ENV{USER}/$wikiname/ikiwiki.cgi",
  27. cgi_wrapper => "$ENV{HOME}/public_html/$wikiname/ikiwiki.cgi",
  28. adminemail => "$ENV{USER}\@$hostname",
  29. add_plugins => [qw{ goodstuff }],
  30. disable_plugins => [qw{ }],
  31. libdir => "$ENV{HOME}/.ikiwiki",
  32. rss => 1,
  33. atom => 1,
  34. syslog => 1,
  35. prefix_directives => 1,
  36. hardlink => 1,
  37. );