NAME
App::PM::Website
VERSION
version 0.131590
SYNOPSIS
# create and initialize configuration file:
pm-website init --build-dir website \
--template-dir template \
--config-file config/pm-website.yaml \
--username your_username \
--groupname monger_long_city_name
# manually update configfile to list new meeting
vim config/pm-website.yaml
# create template directory and templates
mkdir template/
cp examples/template/index.in template/
vim templates/index.in
# copy cacert for pm.org from examples:
cp examples/cacert.pem ./
# render website locally to website/ dir
pm-website build
... view changes locally ...
# upload website/index file to pm.org
pm-website upload
DESCRIPTION
Use pm-website
to render and maintain an up-to-date info page for your Perl Monger group!
PM.org provides free hosting for perl monger groups. Pages must be updated with webDAV and server-side scripts are not allowed. pm-website
will update and install a static, template-driven page via webDAV with minimal effort. Spend less time while creating a more useful front page. Everyone wins!
COMMANDS
pm-website init
-
Initialize a configuration yaml file with the necessary keys
pm-website build
-
Builds the index file (website/index.html) by rendering the template (template/index.in) with TemplateToolkit. The template is passed a models describing the next meeting, past meetings, presenters and locations.
pm-website install
-
Uploads website/index.html via webDAV to groups.pm.org/groups/$groupname, which corresponds to http://$groupname.pm.org/
username and groupname are read from the configuration file and password is read from the
groups.pm.org
entry in $HOME/.netrc if the files exists and is not readable by others.#netrc example machine groups.pm.org login USERNAME password PASSWORD
Model
The template will be provided with models derived from the configuration file. Any information added to the presenter, location and meetings configuration keys will be presented in the model.
m
-
A hash describing the next meeting.
Meetings have additional date keys added from the
event_date
orepoch
field.epoch
event time in epoch unix seconds. Created from
event_date
if missing.dt
a DateTime object created from
epoch
ds1
dt
rendered using strp pattern '%Y-%b-%d'.ds_std
dt
rendered using strp pattern '%A %B %e, %Y'.event_date_pretty
dt
rendered using strp pattern '%A the %e' and then munged by Lingua::EN::Numbers::Ordinate to produce strings like "Friday the 13th" or "Thursday the 23rd"
meetings
-
An array of hashes describing past meetings. The array is reverse sorted by meeting start date. Each hash describes a meeting. The next meeting
m
is not included in the list of meetings. l
-
The location information for the next meeting.
locations
-
hash of location information keyed by location key.
presenter
-
hash of presenter information keyed by presenter id.
SEE ALSO
AUTHOR
Andrew Grangaard <spazm@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2012 by Andrew Grangaard.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.