Skip to content

Commit 1500f10

Browse files
committed
use v6, uncomment mkdir, and show percentage on progress bars
1 parent ca73df5 commit 1500f10

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/DocSite/Generator.pm

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
use v6;
12
unit class DocSite::Generator;
23

34
use lib 'lib';
@@ -148,6 +149,7 @@ sub viz-hints ($group) {
148149

149150
method !process-language-pod {
150151
my $kind = 'Language';
152+
151153
my @files = self!find-pod-files-in($kind);
152154
if $!sparse {
153155
@files = @files[^(@files / $!sparse).ceiling];
@@ -204,15 +206,15 @@ method !process-one-pod (IO::Path $file, Str $kind) {
204206
method !spurt-html-file (IO::Path $file, Str $kind, Str $html) {
205207
my $dir = IO::Path.new( $*SPEC.catfile( $!root, 'html', $kind.lc ) );
206208
unless $dir ~~ :e {
207-
# $dir.mkdir(0o755);
209+
$dir.mkdir(0o755);
208210
}
209211

210212
IO::Path.new( $*SPEC.catfile( $dir, $file.basename.subst( / '.pod' $ /, '.html' ) ) )
211213
.spurt($html);
212214
}
213215

214216
method !run-with-progress ($items, Routine $sub, Str $msg = q{ done}) {
215-
my $prog = Term::ProgressBar.new( :count( $items.elems ) )
217+
my $prog = Term::ProgressBar.new( :count( $items.elems ), :p )
216218
if $!verbose;
217219

218220
my $supply = $items.Supply;

0 commit comments

Comments
 (0)