App-IndonesianHolidayUtils

 view release on metacpan or  search on metacpan

script/list-idn-workdays  view on Meta::CPAN

use 5.010001;
use strict;
use warnings;

use Perinci::CmdLine::Any;

my $cmdline = Perinci::CmdLine::Any->new(
    url => "/Calendar/Indonesia/Holiday/list_idn_workdays",
    program_name => "list-idn-workdays",
    read_config => 0,
    read_env => 0,
);

$cmdline->run;

# ABSTRACT: List working days (non-holiday business days) for a certain period
# PODNAME: list-idn-workdays

__END__

=pod

=encoding UTF-8

=head1 NAME

list-idn-workdays - List working days (non-holiday business days) for a certain period

=head1 VERSION

This document describes version 0.064 of list-idn-workdays (from Perl distribution App-IndonesianHolidayUtils), released on 2021-07-24.

=head1 SYNOPSIS

Usage:

% B<list-idn-workdays> [B<--format>=I<name>|B<--json>] [B<--(no)naked-res>] [B<--observe-joint-leaves>|B<-j>|B<--no-observe-joint-leaves>|B<--noobserve-joint-leaves>] [B<--page-result>[=I<program>]|B<--view-result>[=I<program>]] [B<--work-saturdays>|...

=head1 DESCRIPTION

Working day is defined as day that is not Saturday*/Sunday/holiday/joint leave
days*. If work_saturdays is set to true, Saturdays are also counted as working
days. If observe_joint_leaves is set to false, joint leave days are also counted
as working days.

Contains data from years 1990 to 2021

=head1 OPTIONS

C<*> marks required options.

=head2 Main options

=over

=item B<--end-date>=I<s>

End date.

Defaults to end of current month. Either a string in the form of "YYYY-MM-DD",
or a DateTime object, is accepted.


Can also be specified as the 2nd command-line argument.

=item B<--no-observe-joint-leaves>, B<-j>

=item B<--start-date>=I<s>

Starting date.

Defaults to start of current month. Either a string in the form of "YYYY-MM-DD",
or a DateTime object, is accepted.


Can also be specified as the 1st command-line argument.

=item B<--work-saturdays>

If set to 1, Saturday is a working day.

=back

=head2 Output options

=over

=item B<--format>=I<s>

Choose output format, e.g. json, text.

Default value:

 undef

=item B<--json>

Set output format to json.

=item B<--naked-res>

When outputing as JSON, strip result envelope.

Default value:

 0

By default, when outputing as JSON, the full enveloped result is returned, e.g.:

    [200,"OK",[1,2,3],{"func.extra"=>4}]

The reason is so you can get the status (1st element), status message (2nd
element) as well as result metadata/extra result (4th element) instead of just
the result (3rd element). However, sometimes you want just the result, e.g. when
you want to pipe the result for more post-processing. In this case you can use
`--naked-res` so you just get:

    [1,2,3]


=item B<--page-result>

Filter output through a pager.

=item B<--view-result>

View output using a viewer.

=back

=head2 Other options

=over



( run in 0.579 second using v1.01-cache-2.11-cpan-0bb4e1dffa6 )