2
$fs->traverse('/foo')->filter(sub ($name, $dir) { $name !~ /^\./; });
$fs->traverse('/foo')->filter(sub { $_[0] !~ /^\./; });

Is there any option to keep the first line as is? Because with -pbp perltidy breaks it into 5 lines because of a signatures feature.

alexbyk
  • 171
  • 2
  • 6
  • 3
    [Crossposted](http://www.perlmonks.org/?node_id=1165909). – choroba Jun 16 '16 at 21:24
  • What version? Upgrade to the latest and see if it fixes your problem. There were signature related changes and fixes in the last couple of versions. – runrig Jun 17 '16 at 16:10

1 Answers1

2

perltidy -fnl ("If you do not want any changes to the line breaks within lines of code in your script") seems to work, though I'm not sure how you want the rest of your code to look.

https://metacpan.org/pod/distribution/Perl-Tidy/bin/perltidy#Line-Break-Control

edibleEnergy
  • 1,739
  • 1
  • 13
  • 15