Plack::App::GitHubPages::Faux - PSGI app to test your GitHub Pages site
version 0.03
use Plack::App::GitHubPages::Faux; my $app = Plack::App::GitHubPages::Faux->new( root => "/path/to/htdocs" )->to_app;
This is a static file server PSGI application with some tweaks to operate similar to a GitHub Pages website so that you can do some testing to see if your site looks right before committing. It could also be useful in unit tests for your static site. It is a pretty simple minded subclass of Plack::App::File with these feature additions:
index.html
If a request is made against a directory with an index.html file, that index will be served as a response.
/
This is important to get the right relative URLs in your indexes.
404.html
You can customize your 404 response on GitHub pages by putting a 404.html in the document root. This module will serve that for 404s so that you can see the 404s the way they will be displayed on GitHub pages.
Graham Ollis <plicease@cpan.org>
This software is copyright (c) 2018-2022 by Graham Ollis.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Plack::App::GitHubPages::Faux, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Plack::App::GitHubPages::Faux
CPAN shell
perl -MCPAN -e shell install Plack::App::GitHubPages::Faux
For more information on module installation, please visit the detailed CPAN module installation guide.