App-stopw
view release on metacpan or search on metacpan
{
"abstract" : "A console-based virtual stopwatch and timer",
"author" : [
"perlancar <perlancar@cpan.org>"
],
"dynamic_config" : 0,
"generated_by" : "Dist::Zilla version 6.010, CPAN::Meta::Converter version 2.150010",
"license" : [
"perl_5"
],
"meta-spec" : {
"url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec",
---
abstract: 'A console-based virtual stopwatch and timer'
author:
- 'perlancar <perlancar@cpan.org>'
build_requires:
File::Spec: '0'
IO::Handle: '0'
IPC::Open3: '0'
Test::More: '0'
configure_requires:
ExtUtils::MakeMaker: '0'
dynamic_config: 0
Makefile.PL view on Meta::CPAN
# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v6.010.
use strict;
use warnings;
use 5.010001;
use ExtUtils::MakeMaker;
my %WriteMakefileArgs = (
"ABSTRACT" => "A console-based virtual stopwatch and timer",
"AUTHOR" => "perlancar <perlancar\@cpan.org>",
"CONFIGURE_REQUIRES" => {
"ExtUtils::MakeMaker" => 0
},
"DISTNAME" => "App-stopw",
"EXE_FILES" => [
"script/stopw"
],
"LICENSE" => "perl",
"MIN_PERL_VERSION" => "5.010001",
NAME
App::stopw - A console-based virtual stopwatch and timer
VERSION
This document describes version 0.041 of App::stopw (from Perl
distribution App-stopw), released on 2019-07-06.
SYNOPSIS
This distribution provides the stopw command-line utility.
HOMEPAGE
Please visit the project's homepage at
lib/App/stopw.pm view on Meta::CPAN
package App::stopw;
our $DATE = '2019-07-06'; # DATE
our $VERSION = '0.041'; # VERSION
1;
# ABSTRACT: A console-based virtual stopwatch and timer
__END__
=pod
=encoding UTF-8
=head1 NAME
App::stopw - A console-based virtual stopwatch and timer
=head1 VERSION
This document describes version 0.041 of App::stopw (from Perl distribution App-stopw), released on 2019-07-06.
=head1 SYNOPSIS
This distribution provides the L<stopw> command-line utility.
=head1 HOMEPAGE
script/stopw view on Meta::CPAN
'update-delay|d=f' => \$opts{update_delay},
'banner-size|b=i' => \$opts{banner_size},
'start-stopped|S' => \$opts{start_stopped},
'start-at|s=f' => \$opts{start_at},
'help|h|?' => sub {
print <<'_';
Usage:
stopw [options]
Options:
--banner-size=i (-b). Set 1-5 print large ASCII-art letters.
--start-at=f (-s). Start timer at particular time in seconds.
--start-stopped, -S. Start in stopped state.
--update-delay=f (-d). Defaults to 0.02.
For more details, see manpage.
_
exit 0;
},
'version|v' => sub {
no warnings 'once';
say "stopw version ".(${__PACKAGE__."::VERSION"} // "dev");
script/stopw view on Meta::CPAN
$str = sprintf("%02d:%02d:%02d.%03d ",
$hours, $minutes, $seconds, $millis);
print $str;
sleep $opts{update_delay};
print "\x08" x length($str);
}
}
}
ReadMode "normal";
# ABSTRACT: A console-based virtual stopwatch and timer
# PODNAME: stopw
__END__
=pod
=encoding UTF-8
=head1 NAME
stopw - A console-based virtual stopwatch and timer
=head1 VERSION
This document describes version 0.041 of stopw (from Perl distribution App-stopw), released on 2019-07-06.
=head1 SYNOPSIS
% stopw [options]
=head1 DESCRIPTION
B<stopw> is a console-based virtual stopwatch and timer. After you run the
program, you can press:
=over
=item * C<z> to reset the timer back to zero
=item * C<r> (or spacebar) to record time
This will print the current value of timer and move to the next line.
=item * C<s> (or Enter) to start/stop the timer
=item * C<q> (or Ctrl-C) to quit the program
=back
=head1 OPTIONS
=head2 --banner-size (-b)
Integer, 0-5. Default: 0.
If set to a number between 1-5, will print a large banner (ASCII-art) of
C<mm:ss> digits instead of regular text (using L<Text::Banner>). This will also
automatically set --update-delay to 1.
=head2 --start-at (-s)
Float.
Instead of 0 (00:00), start the timer at a particular second.
=head2 --start-stopped (-S)
Start in stopped state. You need to press a single Return to start the
stopwatch.
=head2 --update-delay (-d)
Float, default: 0.02. Number of seconds between updates.
script/stopw view on Meta::CPAN
When submitting a bug or request, please include a test-file or a
patch to an existing test-file that illustrates the bug or desired
feature.
=head1 SEE ALSO
L<App::Stopwatch> which includes the L<stopwatch> console utility. This utility
is geared more towards executing a command after a specified time period.
The B<stopwatch> Debian package, a graphical (Tk-based) virtual stopwatch and
timer.
The L<time> Unix command.
=head1 AUTHOR
perlancar <perlancar@cpan.org>
=head1 COPYRIGHT AND LICENSE
This software is copyright (c) 2019, 2016, 2014 by perlancar@cpan.org.
( run in 1.237 second using v1.01-cache-2.11-cpan-49f99fa48dc )