gitlab-org / GitLab-Git
Source Code Overview

Analysis scope, overview of main, test, generated, deployment, build, and other code.

Source Code Analysis Scope
Files includes and excluded from analyses
txt
po
tcl
patch
diff
cocci
gitattributes
in
t
xsl
mbox
el
editorconfig
tcsh
plist
mak
m4
clang-format
gitmodules
Overview of Analyzed Files
Basic stats on analyzed files
Intro
For analysis purposes we separate files in scope into several categories: main, test, generated, deployment and build, and other.

  • The main category contains all manually created source code files that are being used in the production.
  • Files in the main category are used as input for other analyses: logical decomposition, concerns, duplication, file size, unit size, and conditional complexity.
  • Test source code files are used only for testing of the product. These files are normally not deployed to production.
  • Build and deployment source code files are used to configure or support build and deployment process.
  • Generated source code files are automatically generated files that have not been manually changed after generation.
  • While a source code folder may contain a number of files, we are primarily interested in the source code files that are being written and maintained by developers.
  • Files containing binaries, documentation, or third-party libraries, for instance, are excluded from analysis. The exception are third-party libraries that have been changed by developers.

main322286 LOC (47%) 979 files
test3496 LOC (<1%) 23 files
generated0 LOC (0%) 0 files
build and deployment230109 LOC (33%) 1,178 files
other128696 LOC (18%) 852 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
tcl
mbox
cocci
tcsh
t
in
el
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 979 files match defined criteria (322,286 LOC, 100.0% vs. main code):
    • 544 *.c files (250,533 LOC)
    • 279 *.h files (21,097 LOC)
    • 23 *.perl files (20,350 LOC)
    • 40 *.tcl files (11,202 LOC)
    • 25 *.pm files (7,495 LOC)
    • 3 *.py files (3,357 LOC)
    • 2 *.bash files (2,987 LOC)
    • 13 *.pl files (1,644 LOC)
    • 7 *.js files (781 LOC)
    • 3 *.mbox files (709 LOC)
    • 16 *.cocci files (605 LOC)
    • 1 *.css files (540 LOC)
    • 4 *.go files (421 LOC)
    • 1 *.zsh files (232 LOC)
    • 1 *.tcsh files (109 LOC)
    • 7 *.t files (109 LOC)
    • 8 *.in files (103 LOC)
    • 2 *.el files (12 LOC)
  • " *.c" is biggest, containing 77.74% of LOC.
  • " *.el" is smallest, containing 0% of LOC.


*.c250533 LOC (77%) 544 files
*.h21097 LOC (6%) 279 files
*.perl20350 LOC (6%) 23 files
*.tcl11202 LOC (3%) 40 files
*.pm7495 LOC (2%) 25 files
*.py3357 LOC (1%) 3 files
*.bash2987 LOC (<1%) 2 files
*.pl1644 LOC (<1%) 13 files
*.js781 LOC (<1%) 7 files
*.mbox709 LOC (<1%) 3 files
*.cocci605 LOC (<1%) 16 files
*.css540 LOC (<1%) 1 file
*.go421 LOC (<1%) 4 files
*.zsh232 LOC (<1%) 1 file
*.tcsh109 LOC (<1%) 1 file
*.t109 LOC (<1%) 7 files
*.in103 LOC (<1%) 8 files
*.el12 LOC (<1%) 2 files
Test Code
Used only for testing of the product. Normally not deployed in a production environment.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/test[.].*".
    • files with paths like ".*[-]test[-].*".
    • files with paths like ".*/[Tt]ests/.*".
    • files with paths like ".*_test[.].*".
    • files with paths like ".*/test_.*".
  • 23 files match defined criteria (3,496 LOC, 1.1% vs. main code):
    • 13 *.c files (2,699 LOC)
    • 5 *.sh files (474 LOC)
    • 3 *.pl files (284 LOC)
    • 1 *.h files (35 LOC)
    • 1 *.perl files (4 LOC)
  • " *.c" is biggest, containing 77.2% of LOC.
  • " *.perl" is smallest, containing 0.11% of LOC.


*.c2699 LOC (77%) 13 files
*.sh474 LOC (13%) 5 files
*.pl284 LOC (8%) 3 files
*.h35 LOC (1%) 1 file
*.perl4 LOC (<1%) 1 file
Build and Deployment Code
Source code used to configure or support build and deployment process.
mak
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]sh".
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*/[.]gitattributes".
    • files with paths like ".*[.]mak".
    • files with paths like ".*[.]bat".
    • files with paths like ".*/[.]gitmodules".
  • 1178 files match defined criteria (230,109 LOC, 71.4% vs. main code):
    • 1,174 *.sh files (229,785 LOC)
    • 3 *.bat files (235 LOC)
    • 1 *.mak files (89 LOC)
  • " *.sh" is biggest, containing 99.86% of LOC.
  • " *.mak" is smallest, containing 0.04% of LOC.


*.sh229785 LOC (99%) 1,174 files
*.bat235 LOC (<1%) 3 files
*.mak89 LOC (<1%) 1 file
Other Code
txt
po
patch
diff
xsl
plist
in
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]txt".
    • files with paths like ".*[.]patch".
    • files with paths like ".*[.]diff".
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*[.]po".
    • files with paths like ".*/LICENSE[.][a-z0-9]+".
    • files with paths like ".*/[Dd]ocumentation/.*".
    • files with paths like ".*[.]editorconfig".
    • files with paths like ".*[.]plist".
  • 852 files match defined criteria (128,696 LOC, 39.9% vs. main code):
    • 752 *.txt files (79,680 LOC)
    • 37 *.po files (45,254 LOC)
    • 18 *.patch files (2,146 LOC)
    • 6 *.md files (662 LOC)
    • 7 *.perl files (325 LOC)
    • 1 *.css files (243 LOC)
    • 4 *.sh files (138 LOC)
    • 18 *.diff files (100 LOC)
    • 6 *.xsl files (67 LOC)
    • 1 *.rb files (43 LOC)
    • 1 *.plist files (30 LOC)
    • 1 *.in files (8 LOC)
  • " *.txt" is biggest, containing 61.91% of LOC.
  • " *.in" is smallest, containing 0.01% of LOC.


*.txt79680 LOC (61%) 752 files
*.po45254 LOC (35%) 37 files
*.patch2146 LOC (1%) 18 files
*.md662 LOC (<1%) 6 files
*.perl325 LOC (<1%) 7 files
*.css243 LOC (<1%) 1 file
*.sh138 LOC (<1%) 4 files
*.diff100 LOC (<1%) 18 files
*.xsl67 LOC (<1%) 6 files
*.rb43 LOC (<1%) 1 file
*.plist30 LOC (<1%) 1 file
*.in8 LOC (<1%) 1 file
Analyzers
Info about analyzers used for source code examinations.


2025-05-16 13:40