microsoft / Static-Module-Verifier
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 7% duplication:
    • 3,569 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 279 duplicated lines
  • 26 duplicates
system7% (279 lines)
Duplication per Extension
cs6% (205 lines)
ps115% (58 lines)
cscfg57% (16 lines)
Duplication per Component (primary)
SmvCmdlets30% (125 lines)
SmvAutomation20% (58 lines)
SmvLibrary1% (24 lines)
SmvService16% (16 lines)
SmvCloudWorker6% (15 lines)
SMVActionsTable14% (12 lines)
SmvInterceptorWrapper2% (10 lines)
SmvInterceptor2% (10 lines)
StaticModuleVerifier3% (9 lines)
SmvDb0% (0 lines)
SmvLineCounter0% (0 lines)
deployment0% (0 lines)
Longest Duplicates
The list of 20 longest duplicates.
See data for all 26 duplicates...
Size#FoldersFilesLinesCode
29 x 2 SmvAutomation
SmvAutomation
BackgroundJobScript.ps1
SmvAutomation.ps1
12:40 (26%)
14:42 (23%)
view
22 x 2 SmvCmdlets
SmvCmdlets
GetBugsFolderWithoutSdxRoot.cs
GetModuleFolderWithoutSdxRoot.cs
20:52 (73%)
20:52 (75%)
view
15 x 2 SmvCmdlets
SmvCmdlets
GetBugsFolder.cs
Utility.cs
82:101 (24%)
33:52 (50%)
view
15 x 2 SmvCloudWorker
SmvLibrary
CloudConfig.cs
CloudConfig.cs
1:27 (100%)
1:27 (100%)
view
10 x 2 SmvCmdlets
SmvCmdlets
GetBugsFolder.cs
GetBugsFolderWithoutSdxRoot.cs
39:53 (16%)
34:48 (33%)
view
10 x 2 SmvInterceptor
SmvInterceptorWrapper
GlobalSuppressions.cs
GlobalSuppressions.cs
1:21 (29%)
1:21 (62%)
view
10 x 2 SmvCmdlets
SmvCmdlets
GetBugsFolder.cs
GetModuleFolderWithoutSdxRoot.cs
39:53 (16%)
34:48 (34%)
view
9 x 2 SmvLibrary
StaticModuleVerifier
GlobalSuppressions.cs
GlobalSuppressions.cs
1:17 (10%)
1:17 (40%)
view
9 x 2 SmvCmdlets
SmvCmdlets
GetBugsFolder.cs
GetModuleFolderWithoutSdxRoot.cs
20:32 (14%)
20:33 (31%)
view
9 x 2 SmvInterceptor
SmvLibrary
GlobalSuppressions.cs
GlobalSuppressions.cs
1:17 (26%)
1:17 (10%)
view
9 x 2 SmvInterceptor
StaticModuleVerifier
GlobalSuppressions.cs
GlobalSuppressions.cs
1:17 (26%)
1:17 (40%)
view
9 x 2 SmvCmdlets
SmvCmdlets
GetBugsFolder.cs
GetBugsFolderWithoutSdxRoot.cs
20:32 (14%)
20:33 (30%)
view
9 x 2 SmvAutomation
SmvAutomation
BackgroundJobScript.ps1
SmvAutomation.ps1
13:21 (8%)
30:38 (7%)
view
9 x 2 SmvInterceptorWrapper
SmvLibrary
GlobalSuppressions.cs
GlobalSuppressions.cs
1:17 (56%)
1:17 (10%)
view
9 x 2 SmvInterceptorWrapper
StaticModuleVerifier
GlobalSuppressions.cs
GlobalSuppressions.cs
1:17 (56%)
1:17 (40%)
view
9 x 2 SmvAutomation
SmvAutomation
SmvAutomation.ps1
SmvAutomation.ps1
15:23 (7%)
30:38 (7%)
view
9 x 2 SmvAutomation
SmvAutomation
BackgroundJobScript.ps1
BackgroundJobScript.ps1
13:21 (8%)
28:36 (8%)
view
9 x 2 SmvAutomation
SmvAutomation
BackgroundJobScript.ps1
SmvAutomation.ps1
28:36 (8%)
15:23 (7%)
view
8 x 2 SmvCmdlets
SmvCmdlets
GetSessionBugDetails.cs
GetSessionOverview.cs
16:28 (50%)
16:28 (50%)
view
8 x 2 SmvService
SmvService
cscfg
ServiceConfiguration.Cloud.cscfg
ServiceConfiguration.Local.cscfg
7:15 (57%)
7:15 (57%)
view