You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Able to identify many #! files ADVANCED! https://github.com/boyter/scc/issues/115
188
188
- Can ignore large files by lines or bytes
189
189
- Can calculate the ULOC or unique lines of code by file, language or project
190
-
- Supports multiple output formats for integration, csv, sql, json, html and more
190
+
- Supports multiple output formats for integration, CSV, SQL, JSON, HTML and more
191
191
192
192
Why not use `scc`?
193
193
@@ -402,7 +402,7 @@ The increment happens for each of the matching conditions and produces the numbe
402
402
### Unique Lines of Code (ULOC)
403
403
404
404
ULOC stands for Unique Lines of Code and represents the unique lines across languages, files and the project itself. This idea was taken from
405
-
https://cmcenroe.me/2018/12/14/uloc.html where the calculation is presented using standard unix tools `sort -u *.h *.c | wc -l`. This metric is
405
+
https://cmcenroe.me/2018/12/14/uloc.html where the calculation is presented using standard Unix tools `sort -u *.h *.c | wc -l`. This metric is
406
406
there to assist with the estimation of complexity within the project. Quoting the source
407
407
408
408
> In my opinion, the number this produces should be a better estimate of the complexity of a project. Compared to SLOC, not only are blank lines discounted, but so are close-brace lines and other repetitive code such as common includes. On the other hand, ULOC counts comments, which require just as much maintenance as the code around them does, while avoiding inflating the result with license headers which appear in every file, for example.
Generally `scc` will the fastest code counter compared to any I am aware of and have compared against. The below comparisons are taken from the fastest alternative counters. See `Other similar projects` above to see all of the other code counters compared against. It is designed to scale to as many CPU's cores as you can provide.
759
759
760
-
However if you want greater performance and you have RAM to spare you can disable the garbage collector like the following on linux`GOGC=-1 scc .` which should speed things up considerably. For some repositories turning off the code complexity calculation via `-c` can reduce runtime as well.
760
+
However if you want greater performance and you have RAM to spare you can disable the garbage collector like the following on Linux`GOGC=-1 scc .` which should speed things up considerably. For some repositories turning off the code complexity calculation via `-c` can reduce runtime as well.
761
761
762
762
Benchmarks are run on fresh 32 Core CPU Optimised Digital Ocean Virtual Machine 2022/09/20 all done using [hyperfine](https://github.com/sharkdp/hyperfine) with 3 warm-up runs and 10 timed runs.
763
763
@@ -899,7 +899,7 @@ The `--format-multi` option is especially useful in CI/CD where you want to get
899
899
900
900
If you want to hack away feel free! PR's are accepted. Some things to keep in mind. If you want to change a language definition you need to update `languages.json` and then run `go generate` which will convert it into the `processor/constants.go` file.
901
901
902
-
For all other changes ensure you run all tests before submitting. You can do so using `go test ./...`. However for maximum coverage please run `test-all.sh` which will run `gofmt`, unit tests, race detector and then all of the integration tests. All of those must pass to ensure a stable release.
902
+
For all other changes ensure you run all tests before submitting. You can do so using `go test ./...`. However, for maximum coverage please run `test-all.sh` which will run `gofmt`, unit tests, race detector and then all of the integration tests. All of those must pass to ensure a stable release.
903
903
904
904
### API Support
905
905
@@ -987,7 +987,7 @@ Packaging as of version v3.1.0 is done through https://goreleaser.com/
987
987
988
988
Note if you plan to run `scc` in Alpine containers you will need to build with CGO_ENABLED=0.
989
989
990
-
See the below dockerfile as an example on how to achieve this based on this issue https://github.com/boyter/scc/issues/208
990
+
See the below Dockerfile as an example on how to achieve this based on this issue https://github.com/boyter/scc/issues/208
991
991
992
992
```
993
993
FROM golang as scc-get
@@ -1043,10 +1043,10 @@ You can find the source code for badges in the repository at https://github.com/
0 commit comments