Coder Social home page Coder Social logo

Unknown option: by_percent about cloc HOT 4 CLOSED

aldanial avatar aldanial commented on July 17, 2024
Unknown option: by_percent

from cloc.

Comments (4)

AlDanial avatar AlDanial commented on July 17, 2024

That's odd, works for me. Note that --by-percent takes an argument that defines how the denominator in the percentage is computed. Here's output I get when I count lines of cloc itself using code count as the denominator:

ubuntu> cloc --by-percent c cloc
       1 text file.
       1 unique file.                              
       0 files ignored.
https://github.com/AlDanial/cloc v 1.65  T=0.07 s (13.7 files/s, 147685.2 lines/s)
-------------------------------------------------------------------------------
Language                     files        blank %      comment %           code
-------------------------------------------------------------------------------
Perl                             1           8.14          12.90           8891
-------------------------------------------------------------------------------

What happens when you run

cloc --by-percent c cloc
?

from cloc.

samhavens avatar samhavens commented on July 17, 2024

Hi, sorry for the delay. I just had a kid, things are crazy :) Here's the output:

sam@sam-VirtualBox ~ $ cloc --by-percent c cloc
Unknown option: by-percent

from cloc.

AlDanial avatar AlDanial commented on July 17, 2024

hey, that's great! The sleep deprivation in the early year(s) is a real drag though.

Anyway, I have a theory on what's going on: the cloc command you're invoking may not be the one you downloaded. What do you get for

cloc --version

? If it isn't 1.65, then you aren't running a version that has the feature. You can download the source to a local directory then run

./cloc --version

and you should see the latest.

from cloc.

samhavens avatar samhavens commented on July 17, 2024

thanks! It was versioning...

from cloc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.