gitlab-org / omnibus-gitlab
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
patch
rake
hcl
txt
gitattributes
ini
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.

main65523 LOC (64%) 945 files
test235 LOC (<1%) 45 files
generated0 LOC (0%) 0 files
build and deployment450 LOC (<1%) 22 files
other35237 LOC (34%) 186 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
hcl
rake
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 945 files match defined criteria (65,523 LOC, 100.0% vs. main code):
    • 738 *.rb files (56,046 LOC)
    • 185 *.erb files (8,070 LOC)
    • 6 *.hcl files (778 LOC)
    • 13 *.rake files (557 LOC)
    • 1 *.css files (49 LOC)
    • 1 *.html files (12 LOC)
    • 1 *.js files (11 LOC)
  • " *.rb" is biggest, containing 85.54% of LOC.
  • " *.js" is smallest, containing 0.02% of LOC.


*.rb56046 LOC (85%) 738 files
*.erb8070 LOC (12%) 185 files
*.hcl778 LOC (1%) 6 files
*.rake557 LOC (<1%) 13 files
*.css49 LOC (<1%) 1 file
*.html12 LOC (<1%) 1 file
*.js11 LOC (<1%) 1 file
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 ".*/test[.].*".
  • 45 files match defined criteria (235 LOC, 0.4% vs. main code):
    • 43 *.rb files (203 LOC)
    • 1 *.sh files (31 LOC)
    • 1 *.erb files (1 LOC)
  • " *.rb" is biggest, containing 86.38% of LOC.
  • " *.erb" is smallest, containing 0.43% of LOC.


*.rb203 LOC (86%) 43 files
*.sh31 LOC (13%) 1 file
*.erb1 LOC (<1%) 1 file
Build and Deployment Code
Source code used to configure or support build and deployment process.
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".
  • 22 files match defined criteria (450 LOC, 0.7% vs. main code). All matches are in *.sh files.


*.sh450 LOC (100%) 22 files
Other Code
patch
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*/[Ee]xamples/.*".
    • files with paths like ".*[.]txt".
    • files with paths like ".*[.]json".
    • files with paths like ".*[.]patch".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]ini".
    • files with paths like ".*/[.]dockerignore".
  • 186 files match defined criteria (35,237 LOC, 53.8% vs. main code):
    • 84 *.md files (17,558 LOC)
    • 92 *.patch files (9,496 LOC)
    • 9 *.json files (8,169 LOC)
    • 1 *.rb files (14 LOC)
  • " *.md" is biggest, containing 49.83% of LOC.
  • " *.rb" is smallest, containing 0.04% of LOC.


*.md17558 LOC (49%) 84 files
*.patch9496 LOC (26%) 92 files
*.json8169 LOC (23%) 9 files
*.rb14 LOC (<1%) 1 file
Analyzers
Info about analyzers used for source code examinations.


2025-05-16 13:51