GoogleCloudPlatform / pi-delivery
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
mod
hcl
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.

main5085 LOC (58%) 69 files
test1849 LOC (21%) 12 files
generated0 LOC (0%) 0 files
build and deployment487 LOC (5%) 16 files
other1305 LOC (14%) 32 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 69 files match defined criteria (5,085 LOC, 100.0% vs. main code):
    • 17 *.go files (1,393 LOC)
    • 12 *.tsx files (1,054 LOC)
    • 6 *.scss files (802 LOC)
    • 11 *.ts files (745 LOC)
    • 8 *.tf files (692 LOC)
    • 7 *.html files (143 LOC)
    • 1 *.cc files (120 LOC)
    • 3 *.js files (57 LOC)
    • 1 *.erb files (51 LOC)
    • 2 *.yaml files (15 LOC)
    • 1 *.rb files (13 LOC)
  • " *.go" is biggest, containing 27.39% of LOC.
  • " *.rb" is smallest, containing 0.26% of LOC.


*.go1393 LOC (27%) 17 files
*.tsx1054 LOC (20%) 12 files
*.scss802 LOC (15%) 6 files
*.ts745 LOC (14%) 11 files
*.tf692 LOC (13%) 8 files
*.html143 LOC (2%) 7 files
*.cc120 LOC (2%) 1 file
*.js57 LOC (1%) 3 files
*.erb51 LOC (1%) 1 file
*.yaml15 LOC (<1%) 2 files
*.rb13 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 ".*/[Tt]est/.*".
    • files with paths like ".*[.][Tt]est[.].*".
    • files with paths like ".*[.]test[.].*".
    • files with paths like ".*/[Tt]ests/.*".
    • files with paths like ".*/mock[a-zA-Z0-9_\- ]+/.*".
    • files with paths like ".*/[Mm]ocks/.*".
  • 12 files match defined criteria (1,849 LOC, 36.4% vs. main code):
    • 10 *.go files (1,823 LOC)
    • 2 *.js files (26 LOC)
  • " *.go" is biggest, containing 98.59% of LOC.
  • " *.js" is smallest, containing 1.41% of LOC.


*.go1823 LOC (98%) 10 files
*.js26 LOC (1%) 2 files
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 ".*/package[.]json".
    • files with paths like ".*([.]|/)webpack([.]|/).*".
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]sh".
  • 16 files match defined criteria (487 LOC, 9.6% vs. main code):
    • 13 *.sh files (332 LOC)
    • 3 *.js files (155 LOC)
  • " *.sh" is biggest, containing 68.17% of LOC.
  • " *.js" is smallest, containing 31.83% of LOC.


*.sh332 LOC (68%) 13 files
*.js155 LOC (31%) 3 files
Other Code
mod
txt
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]json".
    • files with paths like ".*[.]svg".
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*/[Dd]emos?/.*".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]txt".
    • files with paths like ".*/go[.]mod".
  • 32 files match defined criteria (1,305 LOC, 25.7% vs. main code):
    • 19 *.md files (563 LOC)
    • 4 *.tsx files (495 LOC)
    • 5 *.json files (188 LOC)
    • 1 *.mod files (45 LOC)
    • 2 *.svg files (11 LOC)
    • 1 *.txt files (3 LOC)
  • " *.md" is biggest, containing 43.14% of LOC.
  • " *.txt" is smallest, containing 0.23% of LOC.


*.md563 LOC (43%) 19 files
*.tsx495 LOC (37%) 4 files
*.json188 LOC (14%) 5 files
*.mod45 LOC (3%) 1 file
*.svg11 LOC (<1%) 2 files
*.txt3 LOC (<1%) 1 file
Analyzers
Info about analyzers used for source code examinations.


2025-05-04 15:43