From: Steve Hancock Date: Mon, 19 Feb 2024 02:50:23 +0000 (-0800) Subject: -fso, --file-size-order, is now the default X-Git-Tag: 20240202.03~20 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=b3e5a3e5893575c98735731aa39ae27ea40801ef;p=perltidy.git -fso, --file-size-order, is now the default --- diff --git a/CHANGES.md b/CHANGES.md index a04f9c12..945f92db 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -2,6 +2,15 @@ ## 2024 02 02.02 + - The option --file-size-order, or -fso is now the default. When + perltidy is given a list of multiple filenames to process, they + are sorted by size and processed in order of increasing size. + This can significantly reduce memory usage by Perl. This + option has always been used in testing, where typically several + jobs each operating on thousands of filenames are running at the + same time and competing for system resources. If this option + is not wanted for some reason, it can be deactivated with -nfso. + - The option --valign-signed-numbers, or -vsn is now the default. It was introduced in the previous release has been found to significantly improve the overall appearance of columns of signed and unsigned diff --git a/bin/perltidy b/bin/perltidy index c78b65b9..2dc4468b 100755 --- a/bin/perltidy +++ b/bin/perltidy @@ -5618,9 +5618,10 @@ html files, and another is when the B<-cscw> option is selected. The default is to allow timestamps (B<--timestamp> or B<-ts>). B<--file-size-order> or B<-fso> will cause files to be processed in order of -increasing size, when multiple files are being processed. This is useful -during program development, when large numbers of files with varying sizes are -processed, because it can reduce virtual memory usage. +increasing size, when multiple files are being processed. This is particularly +useful during program development, when large numbers of files with varying +sizes are processed, because it can reduce virtual memory usage. This is +the default and can be deactivated with B<-nfso>. B<--maximum-file-size-mb=n> or B<-maxfs=n> specifies the maximum file size in megabytes that perltidy will attempt to format. This parameter is provided to diff --git a/lib/Perl/Tidy.pm b/lib/Perl/Tidy.pm index 622b22d1..dbb23205 100644 --- a/lib/Perl/Tidy.pm +++ b/lib/Perl/Tidy.pm @@ -3839,6 +3839,7 @@ sub generate_options { dump-block-types=sub extended-syntax encode-output-strings + file-size-order function-paren-vertical-alignment fuzzy-line-length hanging-side-comments diff --git a/perltidyrc b/perltidyrc index 6af5e92e..25e2da44 100644 --- a/perltidyrc +++ b/perltidyrc @@ -26,9 +26,6 @@ --want-trailing-commas='b' --delete-trailing-commas -# this should eventually become the default ---delete-repeated-commas - # For now, require arrows at asymmetric bracket combinations --add-interbracket-arrows --interbracket-arrow-style=']->{ }->['