./devel/cloc, Count lines of code

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]

Branch: CURRENT, Version: 1.88, Package name: cloc-1.88, Maintainer: fcambus

cloc counts blank lines, comment lines, and physical lines of source
code in many programming languages, with the following features:

* Reads user-supplied language comment definition files
* Allows results from multiple runs to be summed together by
language and by project.
* Produces results in a variety of formats: plain text, XML, YAML,
* Counts code within compressed archives (tarballs, Zip files, Java
.ear files).
* Has numerous troubleshooting options.
* Handles file and directory names with spaces and other unusual

Required to run:
[textproc/p5-Regexp-Common] [lang/perl5] [devel/p5-Algorithm-Diff] [devel/p5-Parallel-ForkManager]

Required to build:

Master sites:

SHA1: e98cb56f411052f9dc9d28e371bbdda9c1f9163f
RMD160: 228c4ec8e16cc7ae60ffe8558654b5ad96186207
Filesize: 535.549 KB

Version history: (Expand)

CVS history: (Expand)

   2021-01-25 08:59:54 by Frederic Cambus | Files touched by this commit (2) | Package updated
Log message:
cloc: update to 1.88 and take MAINTAINER.

Release Notes for cloc version 1.88:

New Languages and File Types:
    o LLVM IR
    o Logos
    o Meson
    o Mojo
    o Odin
    o Jinja Templates
    o WXML
    o WXSS

    o Support MATLAB block comments.
    o More flexible matching of git hashes.
    o Case insensitive diff file alignment on Windows.
    o Add .BAS as a Visual Basic extension
    o Rename Objective C to Objective-C

Bug Fixes:
    o Add missing Raku_or_Prolog() subroutine.
    o Handle UTF encoded list files (file given to --list-file).
    o Improved support for options parsing from config file.
    o Catch unidentified files via --diff-list-file.
    o Don't insert extra newlines when stripping with --unicode.
   2020-08-31 20:13:29 by Thomas Klausner | Files touched by this commit (3631) | Package updated
Log message:
*: bump PKGREVISION for perl-5.32.
   2020-05-26 22:53:13 by Frederic Cambus | Files touched by this commit (2) | Package updated
Log message:
cloc: update to 1.86.

Release Notes:

New Languages and File Types:
    o ASP.NET Core Blazor WASM (*.razor)
    o Bazel
    o dhall
    o Raku (renamed from Perl6)
    o Squirrel
    o SugarSS
    o Svelte
    o TNSDL
    o Remove .tsv as a RobotFramework extension
    o Add .inl as a C++ extension.
    o Add #_ as a Closure comment marker.

    o Provide alternate algorithms for --git --diff:
      --git-diff-rel computes differences of only files that have changed
                     between the two git commits (this is now the default
                     action with "--git --diff")
      --git-diff-all computes differences between all files in the repo
                     between the two git commits (this was the default
                     action with "--git --diff" behavior in 1.84)
    o New cloc releases will be accompanied by Docker instances on
    o Support reading file names from a STDIN pipe.
    o Check unrecognized files to see if they contain XML.
    o Switch --vcs supports an 'auto' option to automatically determine
      if one is counting in a subversion or git repository.
    o Expand git archives in user-provided scratch directory with --sdir.
    o Mask comment markers in Kotlin raw strings.
    o Make output more deterministic with secondary sort of results.
    o Avoid computation of log(0).
    o Improve --strip-str-comments logic.
    o Improve handling of triple quotes (Python, Groovy, Gradle).
    o New switch --diff-list-file, to perform diff's using a provided
      list file containing file pairs to compare.
    o New switch --ignore-case-ext to ignore upper/lowercase of
      file extension.

Bug Fixes:
    o Fix --exclude-list-file with --diff.
    o Fix creation of empty tar file if this happens during --git --diff.
    o Restore --exclude-lang functionality with --diff.
   2019-11-23 08:17:59 by Makoto Fujiwara | Files touched by this commit (2) | Package updated
Log message:
(devel/cloc) Updated  1.76 to 1.84

(from Unix/NEWS)
                Release Notes for cloc version 1.84
                         September 22, 2019

New Languages and File Types:
    o APL
    o Apache Thrift
    o Imba
    o IPL
    o SaltStack

    o Improved handling of --git --diff
    o Add .podspec as a Ruby file extension.
    o New switch, --stat, to force a stat check of
      directories. This enables traversal of directory
      types whose nlink count does not match the count
      of subdirectories (examples: CD-ROM, FAT, AFS).
    o Force stat on top level directories.  This is
      companion logic to the new --stat switch.
    o Add file extensions defined by the Linguist project.
    o New switch, --exclude-content, to exclude files if
      any of their lines match a regex.
    o New switch, --timeout, to give control over timeouts
      on direct counts (as opposed to diff timeouts).
    o On Windows, lower batch size on git archive
      commands to 100 files (the value is 1,000 on *nix).
    o Better identification of Smarty .tpl template files.

Bug Fixes:
    o On Windows, use double quotes for git archive entries.
    o On Windows, double slash path separators with --by-file
      and JSON output.
    o On Windows, replace / with \\ in results only when
      running with --by-file.
    o Fix header line metrics for files/sec and lines/sec
      when doing --diff.
    o Python:  handle cases of /* or */ embedded in strings
      (this conflicted with internal logic which replaced
      docstring triple quotes with C comments).
    o Fix mishandling of --exclude-dir with --follow-link.
    o Fix doubly-counted #! line
    o Support --hide-rate with csv output.

                Release Notes for cloc version 1.82
                           May  3, 2019

New Languages and File Types:
    o Apex Class
    o DIET
    o Fennel
    o FXML
    o Jupyter notebook files (.ipynb)
    o Python wheel files (.whl)
    o SVG
    o reStructuredText

    o Handle backslashed quotes in strings to improve --strip-str-comments
    o Improve Perl v. Prolog identification.
    o New switch --docstring-as-code to count Python docstrings as code.
    o Partial support fot Lua nested comments.
    o Renamed Skylark to Starlark.
    o Modified Java filter to try to handle embedded comments better.
    o Recognize groovy as one of the #! languages.
    o Add .pyw as a file extension for Python.
    o Update comment definitions for Velocity Template Language.
    o Override file alignment logic with --diff when only two files are
    o Identify TeX v. Visual Basic for .cls file extension.
    o Include result summation line with --csv output.
    o Support --csv, --json, --md, --xml, --yaml output types for the
      --ignored debug file.
    o Force IO encoding to allow wider Unicode characters for creating
      Windows exe's with PAR::Packer

                Release Notes for cloc version 1.80
                           Oct. 5, 2018

This is a bug-fix release to solve mis-handling of git inputs for
straight counts in 1.78 (--git --diff works ok in 1.78),

New Languages:
    o ReasonML

    o New SQL output style option with "--sql-style Named_Columns".  This
      includes the table "t" column names in each insert statement.
    o New option --file-encoding to create all output files using the
      given file encoding (for example "--file-encoding
    o Add escript as script language for Erlang.
    o Improved handling of custom Smarty definitions through
    o Better diff logic when comparing two files.
    o Faster program start on the Unix-tuned version of cloc when
      multiple processors are not used.


                Release Notes for cloc version 1.78
                           Sept. 7, 2018

New Languages:
    o EJS
    o Gradle
    o Igor Pro
    o JSON5
    o Nix
    o R Markdown
    o SparForte
    o Xtend

    o Interpret "--diff-timeout 0" as allowing unlimited time to compute
    o Add .inl extension for C++
    o Improve language rules for Assembly and JCL.
    o Better handling of OCaml comments (don't just use Pascal rules).
    o Handle unusual file names with --use-sloccount.
    o Remove GNU grep specific -P option with --use-sloccount (fall back
      to simpler BSD grep options).
    o Handle OCaml nested comments.
    o Remove debug print statement for counts of Rmd (R markdown) files.
    o New switch --include-ext to only count files with the given extension.
    o New switch --config to load command line switches from a file.
    o New switch --hide-rate to suppress header line (makes the output
    o Skip header line when combining diff reports.
    o Allow any number (including just one) of diff reports to be summed.
    o Exit early if --diff arguments are the same.
    o New switch --strip-str-comments to (try to) avoid 'Complex regular
      subexpression recursion limit' warning.
    o Run cleanly under Perl 5.28 and 5.32 by backslashing braces in regex.
    o Suppord Idris block comments.
    o Set UTF-8 encoding on XML and XSL files generated by cloc.
    o New switch --write-lang-def-incl-dup to include files with extension
      collisions (but should be used with care because the resulting language
      definition file will be rejected by cloc until all collisions have been

Bug Fixes:
    o Correctly handle --not-match-d and --follow-links together.
    o Fix --git --diff handling of large file sets.
    o Remove \$ from git pathspec filename-cleansing regex as git already
      handles such filename mangling
    o Remove debug die() invocation in make_file_list().
    o Fix improperly formatted JSON emitted with --by-file-by-lang.
    o Improve accuracy of C#/Smalltalk disambuguator (was biased toward
      counting .cs files as Smalltalk).
    o Improve accuracy of TypeScript/Qt Linguist disambuguator.
    o More robust YAML output by quoting file and language names.
    o Handle more unusual file names with --git --diff
   2019-08-11 15:25:21 by Thomas Klausner | Files touched by this commit (3557) | Package updated
Log message:
Bump PKGREVISIONs for perl 5.30.0
   2019-05-13 15:58:53 by Makoto Fujiwara | Files touched by this commit (1)
Log message:
(devel/cloc) Add missing DEPENDS (p5-Parallel-ForkManager)
   2018-08-22 11:48:07 by Thomas Klausner | Files touched by this commit (3558)
Log message:
Recursive bump for perl5-5.28.0
   2018-05-29 04:56:49 by Brian Ginsbach | Files touched by this commit (2) | Package updated
Log message:
Update to 1.76

New Languages:
    o Agda              o AsciiDoc          o BrightScript      o Chapel
    o Cucumber          o Drools            o F# Script         o Fish Shell
    o Gencat NLS        o GraphQL           o HCL               o Idris
    o Lean              o Literate Idris    o Oracle PL/SQL     o PL/M
    o ProGuard          o RAML              o SWIG              o Skylark
    o Smalltalk         o Solidity          o Stata             o TOML

    o Performance improvement by using multiple cores for both
      straight counts and --diff via the new --processes option
      added by Sietse Snel, https://github.com/stsnel.
    o Support --git on Windows.
    o Improve identification of Qt Project files (instead of IDL).
    o Fix language determination logic so that languages that map
      to the same file extension and have ties in the number of
      accumulated points always return the same result.
    o Add support for replace_between_regex in --write_lang_def and
    o Add SUM section to JSON, YAML output with --diff.
    o Make numeric values in JSON output numbers instead of strings.
    o Optionally exclude autogenerated files with new --no-autogen
      (currently only supports the Go language).
    o New option, --git, to allow git commit hashes and branch
      names as inputs (issue 205).
    o Add .asd extension for Lisp.
    o Add .snapshot to the list of excluded directories.
    o New option --no-autogen to ignore files generated
      by code production systems like GNU autoconf.
    o Rename "ASP.Net" to "ASP.NET".
    o Improvements to Specman e parsing (issue 175).
    o Support uppercase CPP extension (issue 177).
    o Support triple extensions.
    o Improve language distinction between C# and Smalltalk (issue 160).
    o Consider Elixir docs as comments.
    o Handle Python docstrings made with single quotes.
    o Replace built-in "is it a file?" and "is it a directory?"
      with native Perl -f and -d operators (these were unreliable
      on older versions of Perl on Windows).
    o Put timeout around Regexp::Common regex evaluation to prevent
      hangs on unbalanced comment markers within huge strings (issue 206).
    o Fix Pascal regex wiht '{' for Perl version >= 5.26 (issue 209)
      and '(*', '*)' comment matching (issue 212).
    o Rename Antlr to ANTLR Grammar.
    o Add .g4 extension fo ANTLR Grammar.
    o Replace soon-to-be deprecated File::Glob::glob() with
      File::Glob::bsd_glob() (issue 214).
    o Revert from charset=iso-8859-1 to charset=utf-8 on undocumented
      --html option.
    o For Assembly, process # comments before C++ comments.

Bug Fixes:
    o Remove temp directory prefix for YAML and JSON output when
      counting git archives with --by-file.
    o Properly handle git files with spaces embedded in the file name.
    o Remove a debug regex inadvertently included in v1.74.
    o Correct handling of remove_between_general and
      remove_between_regex when running with --read-lang-def (issue 166)
    o Fix bug handling balanced parentheses in Forth (issue 183)
    o Force legal output filenames with --count-and-diff and --out
      (issue #220).

(from cloc-1.76/Unix/NEWS)