Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: dates and holidays

by Krambambuli (Curate)
on Feb 18, 2010 at 15:46 UTC ( #823962=note: print w/replies, xml ) Need Help??


in reply to dates and holidays

Maybe you could give Date::Manip a try.

The following code
#!/usr/bin/perl use strict; use warnings; use Date::Manip; Date_Init("ConfigFile=/tmp/Manip.cnf"); my $name1 = Date_IsHoliday( '2010-02-15'); print "$name1\n";
would print

Washington's Birthday

"out of the box", and the holidays to remember are easily configurable for your own needs.
Just take care to copy Manip.cnf from the test suite within the installation bundle to a convenient place.

Krambambuli
---

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://823962]
help
Chatterbox?
[choroba]: three
[choroba]: I mean I haven't used DBIx::Class nor M:S, only Moo
[1nickt]: Haha, I was learning about Linux filesystem trees trying to understand how Moo fits.
[1nickt]: I just got my feet wet with some DBIC coding this last week. I feel "meh" about it so far. It was pretty easy to add a sub to the DBIC class to filter search results ...
[1nickt]: ... in the calling code ... $rs = $rs->maturity(" stable");. But I don;t enjoy feeling that far away from the SQL and the DB, really.
[1nickt]: The same project (CPAN Testers API) is using experimental signatures (and therefore 5.024) ... which is what replaced Method::Signatures , afaict.

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (8)
As of 2017-11-24 13:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:













    Results (349 votes). Check out past polls.

    Notices?