flosse / sloc

simple tool to count SLOC (source lines of code)
MIT License
943 stars 84 forks source link

Fix regression in 0.3.0 #139

Closed sebamarynissen closed 6 months ago

sebamarynissen commented 8 months ago

This fixes #137.

flosse commented 8 months ago

Shouldn't we rather adapt the code instead of reverting to an outdated library?

flosse commented 8 months ago

BTW: readdirp seems to be outdated anyway :rofl:

flosse commented 8 months ago

What do you think about using glob?

sebamarynissen commented 8 months ago

Yeah I know, reverting to an outdated library doesn't seem like the ideal solution, but I just wanted to find something that could get the library working again with as little effort as possible.

Just checked and glob has like a 123 million downloads a week on npm, so that seems a solid choice lol.

chenrui333 commented 8 months ago

this patch does not work for my PR, ie, the format option still does not work.

$ sloc --format=csv .

---------- Result ------------

            Physical :  4
              Source :  4
             Comment :  0
 Single-line comment :  0
       Block comment :  0
               Mixed :  0
 Empty block comment :  0
               Empty :  0
               To Do :  0

Number of files read :  1

----------------------------
flosse commented 6 months ago

... this should now be obsolete, since #143 is merged. Thanks anyway!