.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "OpenGuides::Config 3pm" .TH OpenGuides::Config 3pm "2021-01-30" "perl v5.32.0" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" OpenGuides::Config \- Handle OpenGuides configuration variables. .SH "DESCRIPTION" .IX Header "DESCRIPTION" Does config stuff for OpenGuides. Distributed and installed as part of the OpenGuides project, not intended for independent installation. This documentation is probably only useful to OpenGuides developers. .SH "METHODS" .IX Header "METHODS" .IP "\fBnew\fR" 4 .IX Item "new" .Vb 1 \& my $config = OpenGuides::Config\->new( file => "wiki.conf" ); .Ve .Sp Initialises itself from the config file specified and environment variables of the form \s-1OPENGUIDES_CONFIG_READ_ONLY.\s0 Variables which are not set in that file, and which have sensible defaults, will be initialised as described below in \s-1ACCESSORS\s0; others will be given a value of \f(CW\*(C`undef\*(C'\fR. .Sp .Vb 1 \& my $config = OpenGuides::Config\->new( vars => { dbname => "foo" } ); .Ve .Sp As above but gets variables from a supplied hashref instead. .SH "ACCESSORS" .IX Header "ACCESSORS" Each of the accessors described below is read-write. Additionally, for each of them, there is also a read-write accessor called, for example, \f(CW\*(C`dbname_\|_qu\*(C'\fR. This will contain an English-language question suitable for asking for a value for that variable. You shouldn't write to them, but this is not enforced. .PP The defaults mentioned below are those which are applied when \&\f(CW\*(C`\->new\*(C'\fR is called, to variables which are not supplied in the config file. .IP "\(bu" 4 dbname .IP "\(bu" 4 dbuser .IP "\(bu" 4 dbpass .IP "\(bu" 4 dbhost .IP "\(bu" 4 dbport .IP "\(bu" 4 dbencoding .IP "\(bu" 4 script_name (default: \f(CW\*(C`wiki.cgi\*(C'\fR) .IP "\(bu" 4 install_directory (default: \f(CW\*(C`/usr/lib/cgi\-bin/openguides/\*(C'\fR) .IP "\(bu" 4 script_url (this is constrained to always end in \f(CW\*(C`/\*(C'\fR) .IP "\(bu" 4 custom_lib_path .IP "\(bu" 4 use_plucene (default: true) .IP "\(bu" 4 use_lucy (default: false) .IP "\(bu" 4 search_content_munger_module .IP "\(bu" 4 indexing_directory (default: \f(CW\*(C`/usr/lib/cgi\-bin/openguides/indexes\*(C'\fR) .IP "\(bu" 4 enable_page_deletion (default: false) .IP "\(bu" 4 admin_pass (default: \f(CW\*(C`Change This!\*(C'\fR) .IP "\(bu" 4 stylesheet_url .IP "\(bu" 4 site_name (default: \f(CW\*(C`Unconfigured OpenGuides site\*(C'\fR) .IP "\(bu" 4 navbar_on_home_page (default: true) .IP "\(bu" 4 recent_changes_on_home_page (default: true) .IP "\(bu" 4 random_page_omits_locales (default: false) .IP "\(bu" 4 random_page_omits_categories (default: false) .IP "\(bu" 4 content_above_navbar_in_html (default: false) .IP "\(bu" 4 home_name (default: \f(CW\*(C`Home\*(C'\fR) .IP "\(bu" 4 site_desc (default: \f(CW\*(C`A default configuration of OpenGuides\*(C'\fR) .IP "\(bu" 4 default_city (default: \f(CW\*(C`London\*(C'\fR) .IP "\(bu" 4 default_country (default: \f(CW\*(C`United Kingdom\*(C'\fR) .IP "\(bu" 4 default_language (default: \f(CW\*(C`en\*(C'\fR) .IP "\(bu" 4 http_charset .IP "\(bu" 4 contact_email .IP "\(bu" 4 formatting_rules_node (default: \f(CW\*(C`Text Formatting Examples\*(C'\fR) .IP "\(bu" 4 formatting_rules_link (default: \f(CW\*(C`http://openguides.org/text_formatting\*(C'\fR .IP "\(bu" 4 backlinks_in_title (default: false) .IP "\(bu" 4 geo_handler (default: \f(CW1\fR) .IP "\(bu" 4 ellipsoid (default: \f(CW\*(C`WGS\-84\*(C'\fR) .IP "\(bu" 4 use_leaflet .IP "\(bu" 4 gmaps_api_key .IP "\(bu" 4 centre_long .IP "\(bu" 4 centre_lat .IP "\(bu" 4 default_gmaps_zoom .IP "\(bu" 4 default_gmaps_search_zoom .IP "\(bu" 4 show_gmap_in_node_display .IP "\(bu" 4 force_wgs84 .IP "\(bu" 4 google_analytics_key .IP "\(bu" 4 licence_name .IP "\(bu" 4 licence_url .IP "\(bu" 4 licence_info_url .IP "\(bu" 4 spam_detector_module .IP "\(bu" 4 host_checker_module .IP "\(bu" 4 custom_macro_module .IP "\(bu" 4 static_path .IP "\(bu" 4 static_url (this is constrained to always end in \f(CW\*(C`/\*(C'\fR) .IP "\(bu" 4 send_moderation_notifications .IP "\(bu" 4 moderate_whitelist .IP "\(bu" 4 website_link_max_chars (default: \f(CW25\fR) .IP "\(bu" 4 read_only .IP "\(bu" 4 responsive .SH "AUTHOR" .IX Header "AUTHOR" The OpenGuides Project (openguides\-dev@lists.openguides.org) .SH "COPYRIGHT" .IX Header "COPYRIGHT" .Vb 1 \& Copyright (C) 2004\-2020 The OpenGuides Project. All Rights Reserved. .Ve .PP The OpenGuides distribution is free software; you can redistribute it and/or modify it under the same terms as Perl itself. .SH "SEE ALSO" .IX Header "SEE ALSO" OpenGuides