diff -Nru libhtml-widgets-navmenu-perl-1.0703/Build.PL libhtml-widgets-navmenu-perl-1.0704/Build.PL --- libhtml-widgets-navmenu-perl-1.0703/Build.PL 2015-06-10 06:55:40.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/Build.PL 2019-03-11 20:38:28.000000000 +0000 @@ -1,64 +1,65 @@ + +# This file was automatically generated by Dist::Zilla::Plugin::ModuleBuild v6.012. use strict; use warnings; -use File::Spec; -use lib File::Spec->catdir(File::Spec->curdir(), "inc"); +use Module::Build 0.28; -use Test::Run::Builder; -my $build = Test::Run::Builder->new( - 'module_name' => "HTML::Widgets::NavMenu", - configure_requires => - { - 'Module::Build' => '0.36', - }, - 'requires' => - { - 'Test::More' => 0, - 'Class::XSAccessor' => 0, - 'perl' => "5.6.1", - 'IO::Scalar' => 0, - }, - 'license' => "mit", - meta_merge => - { - resources => - { - repository => "https://bitbucket.org/shlomif/perl-html-widgets-navmenu", - homepage => "http://web-cpan.shlomifish.org/modules/HTML-Widgets-NavMenu/", - }, - keywords => - [ - "arrows", - "bar", - "breadcrumbs", - "css", - "expand", - "hidden", - "html", - "menu", - "menus", - "nav-bar", - "navbar", - "navigation", - "navigation aids", - "nav-menu", - "navmenu", - "next", - "prev", - "previous", - "pure-perl", - "site-map", - "skipped", - "trail", - "tree", - "unexpand", - "up", - "widget", - "widgets", - "xhtml", - ], - }, - create_makefile_pl => 'traditional', +my %module_build_args = ( + "build_requires" => { + "Module::Build" => "0.28" + }, + "configure_requires" => { + "ExtUtils::MakeMaker" => 0, + "Module::Build" => "0.28" + }, + "dist_abstract" => "A Perl Module for Generating HTML Navigation Menus", + "dist_author" => [ + "Shlomi Fish " + ], + "dist_name" => "HTML-Widgets-NavMenu", + "dist_version" => "1.0704", + "license" => "mit", + "module_name" => "HTML::Widgets::NavMenu", + "recursive_test_files" => 1, + "requires" => { + "Class::XSAccessor" => 0, + "Exporter" => 0, + "base" => 0, + "perl" => "5.012", + "strict" => 0, + "vars" => 0, + "warnings" => 0 + }, + "test_requires" => { + "File::Spec" => 0, + "IO::Handle" => 0, + "IO::Scalar" => 0, + "IPC::Open3" => 0, + "Test::More" => "0.88", + "lib" => 0 + } ); + + +my %fallback_build_requires = ( + "File::Spec" => 0, + "IO::Handle" => 0, + "IO::Scalar" => 0, + "IPC::Open3" => 0, + "Module::Build" => "0.28", + "Test::More" => "0.88", + "lib" => 0 +); + + +unless ( eval { Module::Build->VERSION(0.4004) } ) { + delete $module_build_args{test_requires}; + $module_build_args{build_requires} = \%fallback_build_requires; +} + +my $build = Module::Build->new(%module_build_args); + + $build->create_build_script; diff -Nru libhtml-widgets-navmenu-perl-1.0703/Changes libhtml-widgets-navmenu-perl-1.0704/Changes --- libhtml-widgets-navmenu-perl-1.0703/Changes 2015-06-10 06:55:40.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/Changes 2019-03-11 20:38:28.000000000 +0000 @@ -1,5 +1,10 @@ Revision history for Perl extension HTML::Widgets::NavMenu. +1.0704 2019-03-11 + - Convert to dzil. + - Try to fix broken provides (e.g: + https://metacpan.org/search?q=HTML%3A%3AWidgets%3A%3ANavMenu%3A%3AObject ) + 1.0703 2015-06-10 - Fix broken links to the examples' version control repositories. - Thanks to Anne for inspiring it. diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/changelog libhtml-widgets-navmenu-perl-1.0704/debian/changelog --- libhtml-widgets-navmenu-perl-1.0703/debian/changelog 2015-07-04 20:16:17.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/changelog 2019-11-24 16:27:49.000000000 +0000 @@ -1,3 +1,35 @@ +libhtml-widgets-navmenu-perl (1.0704-1) unstable; urgency=medium + + [ gregor herrmann ] + * Rename autopkgtest configuration file(s) as per new pkg-perl- + autopkgtest schema. + + [ Salvatore Bonaccorso ] + * debian/control: Use HTTPS transport protocol for Vcs-Git URI + + [ gregor herrmann ] + * debian/copyright: change Copyright-Format 1.0 URL to HTTPS. + * Remove Jonathan Yu from Uploaders. Thanks for your work! + * Remove Ryan Niebur from Uploaders. Thanks for your work! + + [ Salvatore Bonaccorso ] + * Update Vcs-* headers for switch to salsa.debian.org + + [ Xavier Guimard ] + * Email change: Xavier Guimard -> yadd@debian.org + + [ gregor herrmann ] + * Import upstream version 1.0704. + * Add debian/upstream/metadata. + * Update years of upstream and packaging copyright. + * Drop unneeded build dependencies. + * Annotate test-only build dependencies with . + * Declare compliance with Debian Policy 4.4.1. + * Bump debhelper-compat to 12. + * debian/watch: use uscan version 4. + + -- gregor herrmann Sun, 24 Nov 2019 17:27:49 +0100 + libhtml-widgets-navmenu-perl (1.0703-1) unstable; urgency=medium * New upstream release. diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/compat libhtml-widgets-navmenu-perl-1.0704/debian/compat --- libhtml-widgets-navmenu-perl-1.0703/debian/compat 2015-07-04 20:16:17.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/compat 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -8 diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/control libhtml-widgets-navmenu-perl-1.0704/debian/control --- libhtml-widgets-navmenu-perl-1.0703/debian/control 2015-07-04 20:16:17.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/control 2019-11-24 16:27:49.000000000 +0000 @@ -1,23 +1,19 @@ Source: libhtml-widgets-navmenu-perl Maintainer: Debian Perl Group -Uploaders: Ryan Niebur , - Jonathan Yu , - gregor herrmann , - Xavier Guimard +Uploaders: gregor herrmann , + Xavier Guimard Section: perl Testsuite: autopkgtest-pkg-perl Priority: optional -Build-Depends: debhelper (>= 8), +Build-Depends: debhelper-compat (= 12), libmodule-build-perl -Build-Depends-Indep: libclass-xsaccessor-perl, - libcpan-changes-perl, - libio-stringy-perl, - libtest-pod-coverage-perl, - libtest-pod-perl, +Build-Depends-Indep: libclass-xsaccessor-perl , + libcpan-changes-perl , + libio-stringy-perl , perl -Standards-Version: 3.9.6 -Vcs-Browser: https://anonscm.debian.org/cgit/pkg-perl/packages/libhtml-widgets-navmenu-perl.git -Vcs-Git: git://anonscm.debian.org/pkg-perl/packages/libhtml-widgets-navmenu-perl.git +Standards-Version: 4.4.1 +Vcs-Browser: https://salsa.debian.org/perl-team/modules/packages/libhtml-widgets-navmenu-perl +Vcs-Git: https://salsa.debian.org/perl-team/modules/packages/libhtml-widgets-navmenu-perl.git Homepage: https://metacpan.org/release/HTML-Widgets-NavMenu Package: libhtml-widgets-navmenu-perl diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/copyright libhtml-widgets-navmenu-perl-1.0704/debian/copyright --- libhtml-widgets-navmenu-perl-1.0703/debian/copyright 2015-07-04 20:16:17.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/copyright 2019-11-24 16:27:49.000000000 +0000 @@ -1,17 +1,17 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: HTML-Widgets-NavMenu Source: https://metacpan.org/release/HTML-Widgets-NavMenu Upstream-Contact: Shlomi Fish Files: * -Copyright: 2004-2006, Shlomi Fish +Copyright: 2004-2014, Shlomi Fish License: MIT Files: debian/* Copyright: 2009-2010, Jonathan Yu 2009, Ryan Niebur - 2011-2015, gregor herrmann - 2012, Xavier Guimard + 2011-2019, gregor herrmann + 2012, Xavier Guimard License: MIT License: MIT diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/tests/pkg-perl/skip-smoke libhtml-widgets-navmenu-perl-1.0704/debian/tests/pkg-perl/skip-smoke --- libhtml-widgets-navmenu-perl-1.0703/debian/tests/pkg-perl/skip-smoke 2015-07-04 20:16:17.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/tests/pkg-perl/skip-smoke 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -# wants to test the upstream Changes file -t/cpan-changes.t diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/tests/pkg-perl/smoke-skip libhtml-widgets-navmenu-perl-1.0704/debian/tests/pkg-perl/smoke-skip --- libhtml-widgets-navmenu-perl-1.0703/debian/tests/pkg-perl/smoke-skip 1970-01-01 00:00:00.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/tests/pkg-perl/smoke-skip 2019-11-24 16:27:49.000000000 +0000 @@ -0,0 +1,2 @@ +# wants to test the upstream Changes file +t/cpan-changes.t diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/upstream/metadata libhtml-widgets-navmenu-perl-1.0704/debian/upstream/metadata --- libhtml-widgets-navmenu-perl-1.0703/debian/upstream/metadata 1970-01-01 00:00:00.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/upstream/metadata 2019-11-24 16:27:49.000000000 +0000 @@ -0,0 +1,5 @@ +Archive: CPAN +Bug-Database: https://github.com/shlomif/perl-HTML-Widgets-NavMenu/issues +Repository: https://github.com/shlomif/perl-HTML-Widgets-NavMenu.git +Repository-Browse: https://github.com/shlomif/perl-HTML-Widgets-NavMenu +Bug-Submit: https://github.com/shlomif/perl-HTML-Widgets-NavMenu/issues/new diff -Nru libhtml-widgets-navmenu-perl-1.0703/debian/watch libhtml-widgets-navmenu-perl-1.0704/debian/watch --- libhtml-widgets-navmenu-perl-1.0703/debian/watch 2015-07-04 20:16:17.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/debian/watch 2019-11-24 16:27:49.000000000 +0000 @@ -1,2 +1,2 @@ -version=3 -https://metacpan.org/release/HTML-Widgets-NavMenu .*/HTML-Widgets-NavMenu-v?(\d[\d.-]+)\.(?:tar(?:\.gz|\.bz2)?|tgz|zip)$ +version=4 +https://metacpan.org/release/HTML-Widgets-NavMenu .*/HTML-Widgets-NavMenu-v?@ANY_VERSION@@ARCHIVE_EXT@$ diff -Nru libhtml-widgets-navmenu-perl-1.0703/dist.ini libhtml-widgets-navmenu-perl-1.0704/dist.ini --- libhtml-widgets-navmenu-perl-1.0703/dist.ini 1970-01-01 00:00:00.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/dist.ini 2019-03-11 20:38:28.000000000 +0000 @@ -0,0 +1,42 @@ +name = HTML-Widgets-NavMenu +author = Shlomi Fish +license = MIT +copyright_holder = Shlomi Fish +copyright_year = 2014 +version = 1.0704 + +[@Filter] +-bundle = @SHLOMIF +dist = HTML-Widgets-NavMenu +github_name = perl-HTML-Widgets-NavMenu +homepage = http://web-cpan.shlomifish.org/modules/HTML-Widgets-NavMenu/ +[Keywords] +keyword = arrows +keyword = bar +keyword = breadcrumbs +keyword = css +keyword = expand +keyword = hidden +keyword = html +keyword = menu +keyword = menus +keyword = nav-bar +keyword = navbar +keyword = navigation +keyword = navigation aids +keyword = nav-menu +keyword = navmenu +keyword = next +keyword = prev +keyword = previous +keyword = pure-perl +keyword = site-map +keyword = skipped +keyword = trail +keyword = tree +keyword = unexpand +keyword = up +keyword = widget +keyword = widgets +keyword = xhtml +[Test::TidyAll] diff -Nru libhtml-widgets-navmenu-perl-1.0703/examples/article-examples/cgi-script/H-W-NM-serve.pl libhtml-widgets-navmenu-perl-1.0704/examples/article-examples/cgi-script/H-W-NM-serve.pl --- libhtml-widgets-navmenu-perl-1.0703/examples/article-examples/cgi-script/H-W-NM-serve.pl 2015-06-10 06:55:40.000000000 +0000 +++ libhtml-widgets-navmenu-perl-1.0704/examples/article-examples/cgi-script/H-W-NM-serve.pl 2019-03-11 20:38:28.000000000 +0000 @@ -79,45 +79,41 @@ } EOF -my $nav_menu_tree = -{ - 'host' => "default", - 'text' => "HTML-Widgets-NavMenu Example", +my $nav_menu_tree = { + 'host' => "default", + 'text' => "HTML-Widgets-NavMenu Example", 'title' => "HTML-Widgets-NavMenu", - 'subs' => - [ + 'subs' => [ { 'text' => "Home", - 'url' => "", + 'url' => "", }, { 'text' => "About Myself", - 'url' => "me/", - 'subs' => - [ + 'url' => "me/", + 'subs' => [ { - 'text' => "Bio", - 'url' => "personal.html", + 'text' => "Bio", + 'url' => "personal.html", 'title' => "A Short Biography of Myself", }, { - 'text' => "Contact", - 'url' => "me/contact-me/", - 'title'=> "How to Contact me in Every Conceivable Way", + 'text' => "Contact", + 'url' => "me/contact-me/", + 'title' => "How to Contact me in Every Conceivable Way", }, { 'text' => "My Resumés", - 'url' => "me/resumes/", - 'subs' => - [ + 'url' => "me/resumes/", + 'subs' => [ { 'text' => "English Resumé", - 'url' => "resume.html", + 'url' => "resume.html", 'skip' => 1, }, { 'text' => "Detailed English Resumé", - 'url' => "resume_detailed.html", + 'url' => "resume_detailed.html", 'skip' => 1, }, ], @@ -125,265 +121,299 @@ ], }, { - 'text' => "Humour", - 'url' => "humour/", - 'title' => "My Humorous Creations", + 'text' => "Humour", + 'url' => "humour/", + 'title' => "My Humorous Creations", 'show_always' => 1, - 'subs' => - [ + 'subs' => [ { - 'text' => "The Enemy", - 'url' => "humour/TheEnemy/", + 'text' => "The Enemy", + 'url' => "humour/TheEnemy/", 'title' => "The Enemy and How I Helped to Fight It", }, { - 'text' => "TOWTF", - 'url' => "humour/TOWTF/", + 'text' => "TOWTF", + 'url' => "humour/TOWTF/", 'title' => "The One with the Fountainhead", }, { - 'text' => "The Pope", - 'url' => "humour/Pope/", + 'text' => "The Pope", + 'url' => "humour/Pope/", 'title' => "The Pope Died on Sunday", }, { - 'text' => "Humour Archive", + 'text' => "Humour Archive", 'title' => "Archive of Humorous Bits I came up with", - 'url' => "humour.html", + 'url' => "humour.html", }, { 'text' => "Fortune Cookies Collection", - 'title' => "Collection of Files for Input to the UNIX 'fortune' Program", + 'title' => +"Collection of Files for Input to the UNIX 'fortune' Program", 'url' => "humour/fortunes/", }, ], }, { - 'text' => "Math-Ventures", - 'url' => "MathVentures/", + 'text' => "Math-Ventures", + 'url' => "MathVentures/", 'title' => "Mathematical Riddles and their Solutions", }, { - 'text' => "Computer Art", - 'url' => "art/", + 'text' => "Computer Art", + 'url' => "art/", 'title' => "Computer art I created while explaining how.", - 'subs' => - [ + 'subs' => [ { 'text' => "Back to my Homepage", - 'url' => "art/bk2hp/", - 'title' => "A Back to my Homepage logo not unlike the one from the movie "Back to the Future"", + 'url' => "art/bk2hp/", + 'title' => +"A Back to my Homepage logo not unlike the one from the movie "Back to the Future"", }, { 'text' => "Linux Banner", - 'url' => "art/linux_banner/", - 'title' => "Linux - Because Software Problems should not Cost Money", + 'url' => "art/linux_banner/", + 'title' => +"Linux - Because Software Problems should not Cost Money", }, ], }, { - 'text' => "Software", - 'url' => "open-source/", + 'text' => "Software", + 'url' => "open-source/", 'expand' => { 're' => "^(open-source|perl)/", }, - 'title' => "Pages related to Software (mostly Open-Source)", - 'subs' => - [ + 'title' => "Pages related to Software (mostly Open-Source)", + 'subs' => [ { 'text' => "Freecell Solver", - 'url' => "open-source/projects/freecell-solver/", + 'url' => "open-source/projects/freecell-solver/", }, { 'text' => "MikMod for Java", - 'title' => "A Player for MOD Files (a type of Music Files) for the Java Environment", + 'title' => +"A Player for MOD Files (a type of Music Files) for the Java Environment", 'url' => "jmikmod/", }, { - 'text' => "FCFS RWLock", + 'text' => "FCFS RWLock", 'title' => "A First-Come First-Served Readers/Writers Lock", - 'url' => "rwlock/", + 'url' => "rwlock/", }, { - 'text' => "Quad-Pres", + 'text' => "Quad-Pres", 'title' => "A Tool for Creating HTML Presentations", - 'url' => "open-source/projects/quad-pres/", + 'url' => "open-source/projects/quad-pres/", }, { - 'text' => "Favourite OSS", + 'text' => "Favourite OSS", 'title' => "Favourite Open-Source Software", - 'url' => "open-source/favourite/", + 'url' => "open-source/favourite/", }, { - 'text' => "Interviews", + 'text' => "Interviews", 'title' => "Interviews with Open-Source People", - 'url' => "open-source/interviews/", + 'url' => "open-source/interviews/", }, { 'text' => "Contributions", - 'title' => "Contributions to Other Projects, that I did not Start", + 'title' => + "Contributions to Other Projects, that I did not Start", 'url' => "open-source/contributions/", }, { - 'text' => "Bits and Bobs", + 'text' => "Bits and Bobs", 'title' => "Various Small-Scale Open-Source Works", - 'url' => "open-source/bits.html", + 'url' => "open-source/bits.html", }, { - 'text' => "Portability Libraries", + 'text' => "Portability Libraries", 'title' => "Cross-Platform Abstraction Libraries", - 'url' => "abstraction/", - 'hide' => 1, + 'url' => "abstraction/", + 'hide' => 1, }, { - 'text' => "Software Tools", + 'text' => "Software Tools", 'title' => "Software Construction and Management Tools", - 'url' => "software-tools/", - 'hide' => 1, + 'url' => "software-tools/", + 'hide' => 1, }, ], }, { - 'text' => "Lectures", - 'url' => "lecture/", + 'text' => "Lectures", + 'url' => "lecture/", 'expand' => { 're' => "^lecture/", }, - 'title' => "Presentations I Wrote (Mostly Technical)", - 'subs' => - [ + 'title' => "Presentations I Wrote (Mostly Technical)", + 'subs' => [ { 'text' => "Perl for Newbies", - 'url' => "lecture/Perl/Newbies/", + 'url' => "lecture/Perl/Newbies/", }, { 'text' => "Freecell Solver", - 'url' => "lecture/Freecell-Solver/", + 'url' => "lecture/Freecell-Solver/", }, { 'text' => "Lambda Calculus", - 'title' => "A presentation about a Turing-complete programming environment with only two primitives", + 'title' => +"A presentation about a Turing-complete programming environment with only two primitives", 'url' => "lecture/lc/", }, { 'text' => "The Gimp", - 'title' => "A Presentation about the GNU Image Manipulation Program", + 'title' => +"A Presentation about the GNU Image Manipulation Program", 'url' => "lecture/Gimp/", }, { 'text' => "GNU Autotools", - 'url' => "lecture/Autotools/", + 'url' => "lecture/Autotools/", }, { - 'text' => "Web Meta Lecture", + 'text' => "Web Meta Lecture", 'title' => "A Presentation about the Web Meta Language", - 'url' => "lecture/WebMetaLecture/", + 'url' => "lecture/WebMetaLecture/", }, ], }, { 'text' => "Essays", - 'url' => "essays/", - 'title' => "Various Essays and Articles about Technology and Philosophy in General", - 'subs' => - [ + 'url' => "essays/", + 'title' => +"Various Essays and Articles about Technology and Philosophy in General", + 'subs' => [ { - 'text' => "Index to Essays", - 'url' => "essays/Index/", + 'text' => "Index to Essays", + 'url' => "essays/Index/", 'title' => "Index to Essays and Articles I wrote.", }, { - 'text' => "Open Source", - 'url' => "essays/open-source/", + 'text' => "Open Source", + 'url' => "essays/open-source/", 'title' => "Essays about Open-Source", }, { - 'text' => "Life", - 'url' => "essays/life/", + 'text' => "Life", + 'url' => "essays/life/", 'title' => "Essays about Life, the Universe and Everything", }, ], }, { - 'text' => "Cool Links", - 'url' => "links.html", + 'text' => "Cool Links", + 'url' => "links.html", 'title' => "An incomplete list of links I find cool and/or useful.", }, { - 'text' => "Site Map", - 'url' => "site-map/", + 'text' => "Site Map", + 'url' => "site-map/", 'title' => "A site map for the site with all the pages", }, ], }; -my %hosts = -( - 'hosts' => - { - 'default' => - { - 'base_url' => ("http://web-cpan.berlios.de/modules/" . - "HTML-Widgets-NavMenu/article/examples/simple/dest/"), +my %hosts = ( + 'hosts' => { + 'default' => { + 'base_url' => ( + "http://web-cpan.berlios.de/modules/" + . "HTML-Widgets-NavMenu/article/examples/simple/dest/" + ), }, }, ); -my @page_paths = -("", "me/", "personal.html", "me/contact-me/", "me/resumes/", "resume.html", -"resume_detailed.html", "humour/", "humour/TheEnemy/", "humour/TOWTF/", -"humour/Pope/", "humour.html", "humour/fortunes/", "MathVentures/", -"art/", "art/bk2hp/", "art/linux_banner/", "open-source/", -"open-source/projects/freecell-solver/", "jmikmod/", "rwlock/", -"open-source/projects/quad-pres/", "open-source/favourite/", -"open-source/interviews/", "open-source/contributions/", -"open-source/bits.html", "abstraction/", "software-tools/", "lecture/", -"lecture/Perl/Newbies/", "lecture/Freecell-Solver/", "lecture/lc/", -"lecture/Gimp/", "lecture/Autotools/", "lecture/WebMetaLecture/", -"essays/", "essays/Index/", "essays/open-source/", "essays/life/", -"links.html"); - -my @pages = - (map { - +{ 'path' => $_, 'title' => "Title for $_", - 'content' => "

Content for $_

" } - } @page_paths); +my @page_paths = ( + "", + "me/", + "personal.html", + "me/contact-me/", + "me/resumes/", + "resume.html", + "resume_detailed.html", + "humour/", + "humour/TheEnemy/", + "humour/TOWTF/", + "humour/Pope/", + "humour.html", + "humour/fortunes/", + "MathVentures/", + "art/", + "art/bk2hp/", + "art/linux_banner/", + "open-source/", + "open-source/projects/freecell-solver/", + "jmikmod/", + "rwlock/", + "open-source/projects/quad-pres/", + "open-source/favourite/", + "open-source/interviews/", + "open-source/contributions/", + "open-source/bits.html", + "abstraction/", + "software-tools/", + "lecture/", + "lecture/Perl/Newbies/", + "lecture/Freecell-Solver/", + "lecture/lc/", + "lecture/Gimp/", + "lecture/Autotools/", + "lecture/WebMetaLecture/", + "essays/", + "essays/Index/", + "essays/open-source/", + "essays/life/", + "links.html" +); + +my @pages = ( + map { + +{ + 'path' => $_, + 'title' => "Title for $_", + 'content' => "

Content for $_

" + } + } @page_paths +); # Add the site-map page. { - my $site_map_path = "site-map/"; - my $site_map_generator = - HTML::Widgets::NavMenu->new( - path_info => "/$site_map_path", - current_host => "default", - hosts => \%hosts, - tree_contents => $nav_menu_tree - ); + my $site_map_path = "site-map/"; + my $site_map_generator = HTML::Widgets::NavMenu->new( + path_info => "/$site_map_path", + current_host => "default", + hosts => \%hosts, + tree_contents => $nav_menu_tree + ); push @pages, - { - 'path' => $site_map_path, - 'title' => "Site Map", - 'content' => join("\n", @{$site_map_generator->gen_site_map()}), - }; + { + 'path' => $site_map_path, + 'title' => "Site Map", + 'content' => join( "\n", @{ $site_map_generator->gen_site_map() } ), + }; }; push @pages, -( + ( { - 'path' => "perl/japhs/", - 'title' => "Perl JAPHs", + 'path' => "perl/japhs/", + 'title' => "Perl JAPHs", 'content' => "

JAPHs for fun and profit.

", }, { - 'path' => "open-source/yowza/", - 'title' => "A Wonderful Yowza", + 'path' => "open-source/yowza/", + 'title' => "A Wonderful Yowza", 'content' => "

Yowza is da-bomb man!

", } -); + ); -my $cgi = CGI->new(); +my $cgi = CGI->new(); my $path_info = $cgi->path_info(); -if ($cgi->param("hi")) +if ( $cgi->param("hi") ) { - print $cgi->header(-type => "text/plain"); - print (map { "$_ => $ENV{$_}\n" } keys(%ENV)); + print $cgi->header( -type => "text/plain" ); + print( map { "$_ => $ENV{$_}\n" } keys(%ENV) ); exit; } @@ -391,47 +421,45 @@ PAGE_LOOP: foreach my $page (@pages) { - my $path = $page->{'path'}; - my $title = $page->{'title'}; + my $path = $page->{'path'}; + my $title = $page->{'title'}; my $content = $page->{'content'}; - if ($path_info eq "/$path") + if ( $path_info eq "/$path" ) { $found = 1; - render_page("/".$path, $title, $content); + render_page( "/" . $path, $title, $content ); last; } } sub render_page { - my ($path, $title, $content) = @_; - my $nav_menu = - HTML::Widgets::NavMenu->new( - path_info => "$path", - current_host => "default", - hosts => \%hosts, - tree_contents => $nav_menu_tree, - ); + my ( $path, $title, $content ) = @_; + my $nav_menu = HTML::Widgets::NavMenu->new( + path_info => "$path", + current_host => "default", + hosts => \%hosts, + tree_contents => $nav_menu_tree, + ); my $nav_menu_results = $nav_menu->render(); print $cgi->header(); - my $template = - Template->new( + my $template = Template->new( { 'POST_CHOMP' => 1, } - ); + ); - my $vars = - { - 'title' => $title, - 'css_style' => $css_style, - 'nav_menu_text' => join("\n", @{$nav_menu_results->{'html'}}) . "\n", - 'content' => $content . "\n", + my $vars = { + 'title' => $title, + 'css_style' => $css_style, + 'nav_menu_text' => join( "\n", @{ $nav_menu_results->{'html'} } ) + . "\n", + 'content' => $content . "\n", 'breadcrumbs' => $nav_menu_results->{leading_path}, - 'nav_links' => $nav_menu_results->{'nav_links_obj'}, + 'nav_links' => $nav_menu_results->{'nav_links_obj'}, }; my $nav_links_template = <<'EOF'; @@ -455,7 +483,7 @@