mozilla / bedrock
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
in
editorconfig
cfg
tpl
prettierignore
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.

main124405 LOC (67%) 1,677 files
test36130 LOC (19%) 315 files
generated278 LOC (<1%) 2 files
build and deployment176 LOC (<1%) 2 files
other22258 LOC (12%) 450 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
in
cfg
tpl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 1677 files match defined criteria (124,405 LOC, 100.0% vs. main code):
    • 693 *.html files (62,101 LOC)
    • 319 *.scss files (27,562 LOC)
    • 291 *.py files (18,424 LOC)
    • 187 *.js files (10,440 LOC)
    • 139 *.ftl files (4,783 LOC)
    • 6 *.toml files (463 LOC)
    • 31 *.css files (400 LOC)
    • 4 *.in files (77 LOC)
    • 2 *.yaml files (73 LOC)
    • 3 *.xml files (46 LOC)
    • 1 *.cfg files (20 LOC)
    • 1 *.tpl files (16 LOC)
  • " *.html" is biggest, containing 49.92% of LOC.
  • " *.tpl" is smallest, containing 0.01% of LOC.


*.html62101 LOC (49%) 693 files
*.scss27562 LOC (22%) 319 files
*.py18424 LOC (14%) 291 files
*.js10440 LOC (8%) 187 files
*.ftl4783 LOC (3%) 139 files
*.toml463 LOC (<1%) 6 files
*.css400 LOC (<1%) 31 files
*.in77 LOC (<1%) 4 files
*.yaml73 LOC (<1%) 2 files
*.xml46 LOC (<1%) 3 files
*.cfg20 LOC (<1%) 1 file
*.tpl16 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 ".*_tests[.].*".
    • files with paths like ".*/[Tt]ests/.*".
    • files with paths like ".*/test_.*".
    • files with paths like ".*/[Ss]pecs/.*".
    • files with paths like ".*[.]spec[.]js".
    • files with paths like ".*/testing[.].*".
    • files with paths like ".*[.][Tt]est[.].*".
    • files with paths like ".*[.]test[.].*".
    • files with paths like ".*/test[.].*".
    • files with paths like ".*[-]tests/.*".
  • 315 files match defined criteria (36,130 LOC, 29.0% vs. main code):
    • 184 *.py files (20,857 LOC)
    • 116 *.js files (15,180 LOC)
    • 7 *.html files (52 LOC)
    • 6 *.ftl files (39 LOC)
    • 2 *.css files (2 LOC)
  • " *.py" is biggest, containing 57.73% of LOC.
  • " *.css" is smallest, containing 0.01% of LOC.


*.py20857 LOC (57%) 184 files
*.js15180 LOC (42%) 116 files
*.html52 LOC (<1%) 7 files
*.ftl39 LOC (<1%) 6 files
*.css2 LOC (<1%) 2 files
Generated Code
Automatically generated files, not manually changed after generation.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/package[-]lock[.]json".
    • files with paths like ".*[.](html|html|xhtml)" AND any line of content like "[ ]*[<]meta name[=]"generator" .*".
  • 2 files match defined criteria (278 LOC, 0.2% vs. main code):
    • 1 *.html files (145 LOC)
    • 1 *.json files (133 LOC)
  • " *.html" is biggest, containing 52.16% of LOC.
  • " *.json" is smallest, containing 47.84% of LOC.


*.html145 LOC (52%) 1 file
*.json133 LOC (47%) 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 ".*/package[.]json".
    • files with paths like ".*/package[-]lock[.]json".
    • files with paths like ".*([.]|/)webpack([.]|/).*".
  • 2 files match defined criteria (176 LOC, 0.1% vs. main code). All matches are in *.js files.


*.js176 LOC (100%) 2 files
Other Code
txt
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]editorconfig".
    • files with paths like ".*[.]txt".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*[.]md".
    • files with paths like ".*[.]json".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*/[.]dockerignore".
    • files with paths like ".*[.]svg".
    • files with paths like ".*/[.]prettierignore".
  • 450 files match defined criteria (22,258 LOC, 17.9% vs. main code):
    • 392 *.svg files (9,650 LOC)
    • 41 *.json files (7,163 LOC)
    • 15 *.txt files (5,401 LOC)
    • 2 *.md files (44 LOC)
  • " *.svg" is biggest, containing 43.36% of LOC.
  • " *.md" is smallest, containing 0.2% of LOC.


*.svg9650 LOC (43%) 392 files
*.json7163 LOC (32%) 41 files
*.txt5401 LOC (24%) 15 files
*.md44 LOC (<1%) 2 files
Analyzers
Info about analyzers used for source code examinations.


2025-05-11 19:40