scanoss 0.7.9 → 0.7.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (424) hide show
  1. package/build/main/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.d.ts +1 -1
  2. package/build/main/tsconfig.tsbuildinfo +1 -1
  3. package/build/module/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.d.ts +1 -1
  4. package/build/module/tsconfig.module.tsbuildinfo +1 -1
  5. package/package.json +2 -2
  6. package/.circleci/config.yml +0 -64
  7. package/.cspell.json +0 -36
  8. package/.editorconfig +0 -15
  9. package/.eslintrc.json +0 -37
  10. package/.github/workflows/reuse.yml +0 -15
  11. package/.github/workflows/scanoss.yml +0 -24
  12. package/.gitignore +0 -10
  13. package/.idea/.gitignore +0 -5
  14. package/.idea/codeStyles/Project.xml +0 -61
  15. package/.idea/codeStyles/codeStyleConfig.xml +0 -5
  16. package/.idea/inspectionProfiles/Project_Default.xml +0 -6
  17. package/.idea/modules.xml +0 -8
  18. package/.idea/scanoss.js.iml +0 -12
  19. package/.idea/vcs.xml +0 -6
  20. package/.idea/workspace.xml +0 -313
  21. package/.nyc_output/3da9f448-90e4-4399-887b-e4fd1b8d7052.json +0 -1
  22. package/.nyc_output/processinfo/3da9f448-90e4-4399-887b-e4fd1b8d7052.json +0 -1
  23. package/.nyc_output/processinfo/index.json +0 -1
  24. package/.prettierignore +0 -2
  25. package/.reuse/dep5 +0 -16
  26. package/.vscode/extensions.json +0 -8
  27. package/.vscode/launch.json +0 -29
  28. package/.vscode/settings.json +0 -7
  29. package/LICENSES/CC0-1.0.txt +0 -121
  30. package/LICENSES/MIT.txt +0 -9
  31. package/assets/ReportHTMLTemplate/index.html +0 -1181
  32. package/build/main/package.json +0 -120
  33. package/build/main/sdk/filters/DefaultFilterForDependencies.d.ts +0 -16
  34. package/build/main/sdk/filters/DefaultFilterForDependencies.js +0 -145
  35. package/build/main/sdk/filters/DefaultFilterForScanning.d.ts +0 -16
  36. package/build/main/sdk/filters/DefaultFilterForScanning.js +0 -194
  37. package/build/main/sdk/filters/filtering.d.ts +0 -32
  38. package/build/main/sdk/filters/filtering.js +0 -228
  39. package/build/main/src/cli/bin/cli-bin.d.ts +0 -2
  40. package/build/main/src/cli/bin/cli-bin.js +0 -68
  41. package/build/main/src/cli/commands/dep.d.ts +0 -1
  42. package/build/main/src/cli/commands/dep.js +0 -38
  43. package/build/main/src/cli/commands/helpers.d.ts +0 -2
  44. package/build/main/src/cli/commands/helpers.js +0 -25
  45. package/build/main/src/cli/commands/scan.d.ts +0 -1
  46. package/build/main/src/cli/commands/scan.js +0 -138
  47. package/build/main/src/cli/commands/wfp.d.ts +0 -1
  48. package/build/main/src/cli/commands/wfp.js +0 -54
  49. package/build/main/src/index.d.ts +0 -14
  50. package/build/main/src/index.js +0 -30
  51. package/build/main/src/sdk/DataLayer/DataLayerTypes.d.ts +0 -108
  52. package/build/main/src/sdk/DataLayer/DataLayerTypes.js +0 -5
  53. package/build/main/src/sdk/DataLayer/DataProviderManager.d.ts +0 -7
  54. package/build/main/src/sdk/DataLayer/DataProviderManager.js +0 -24
  55. package/build/main/src/sdk/DataLayer/DataProviders/ComponentDataProvider.d.ts +0 -13
  56. package/build/main/src/sdk/DataLayer/DataProviders/ComponentDataProvider.js +0 -164
  57. package/build/main/src/sdk/DataLayer/DataProviders/DependencyDataProvider.d.ts +0 -9
  58. package/build/main/src/sdk/DataLayer/DataProviders/DependencyDataProvider.js +0 -37
  59. package/build/main/src/sdk/DataLayer/DataProviders/LicenseDataProvider.d.ts +0 -18
  60. package/build/main/src/sdk/DataLayer/DataProviders/LicenseDataProvider.js +0 -148
  61. package/build/main/src/sdk/DataLayer/DataProviders/SummaryDataProvider.d.ts +0 -11
  62. package/build/main/src/sdk/DataLayer/DataProviders/SummaryDataProvider.js +0 -33
  63. package/build/main/src/sdk/Decompress/DecompressionManager.d.ts +0 -12
  64. package/build/main/src/sdk/Decompress/DecompressionManager.js +0 -73
  65. package/build/main/src/sdk/Decompress/Decompressor/DecompressTgz.d.ts +0 -5
  66. package/build/main/src/sdk/Decompress/Decompressor/DecompressTgz.js +0 -22
  67. package/build/main/src/sdk/Decompress/Decompressor/DecompressZips.d.ts +0 -5
  68. package/build/main/src/sdk/Decompress/Decompressor/DecompressZips.js +0 -24
  69. package/build/main/src/sdk/Decompress/Decompressor/Decompressor.d.ts +0 -10
  70. package/build/main/src/sdk/Decompress/Decompressor/Decompressor.js +0 -18
  71. package/build/main/src/sdk/Dependencies/DependencyScanner.d.ts +0 -11
  72. package/build/main/src/sdk/Dependencies/DependencyScanner.js +0 -96
  73. package/build/main/src/sdk/Dependencies/DependencyScannerCfg.d.ts +0 -4
  74. package/build/main/src/sdk/Dependencies/DependencyScannerCfg.js +0 -10
  75. package/build/main/src/sdk/Dependencies/DependencyTypes.d.ts +0 -21
  76. package/build/main/src/sdk/Dependencies/DependencyTypes.js +0 -2
  77. package/build/main/src/sdk/Dependencies/LocalDependency/DependencyTypes.d.ts +0 -16
  78. package/build/main/src/sdk/Dependencies/LocalDependency/DependencyTypes.js +0 -2
  79. package/build/main/src/sdk/Dependencies/LocalDependency/LocalDependency.d.ts +0 -8
  80. package/build/main/src/sdk/Dependencies/LocalDependency/LocalDependency.js +0 -102
  81. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/buildGradleParser.d.ts +0 -2
  82. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/buildGradleParser.js +0 -95
  83. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/golangParser.d.ts +0 -3
  84. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/golangParser.js +0 -97
  85. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/mavenParser.d.ts +0 -2
  86. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/mavenParser.js +0 -183
  87. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/npmParser.d.ts +0 -13
  88. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/npmParser.js +0 -187
  89. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/nugetParser.d.ts +0 -3
  90. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/nugetParser.js +0 -58
  91. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/pyParser.d.ts +0 -2
  92. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/pyParser.js +0 -64
  93. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/rubyParser.d.ts +0 -3
  94. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/rubyParser.js +0 -132
  95. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/utils.d.ts +0 -2
  96. package/build/main/src/sdk/Dependencies/LocalDependency/parsers/utils.js +0 -19
  97. package/build/main/src/sdk/Report/Report.d.ts +0 -8
  98. package/build/main/src/sdk/Report/Report.js +0 -26
  99. package/build/main/src/sdk/filters/DefaultFilterForDependencies.d.ts +0 -16
  100. package/build/main/src/sdk/filters/DefaultFilterForDependencies.js +0 -145
  101. package/build/main/src/sdk/filters/DefaultFilterForScanning.d.ts +0 -16
  102. package/build/main/src/sdk/filters/DefaultFilterForScanning.js +0 -194
  103. package/build/main/src/sdk/filters/filtering.d.ts +0 -32
  104. package/build/main/src/sdk/filters/filtering.js +0 -228
  105. package/build/main/src/sdk/grpc/GrpcDependencyService.d.ts +0 -11
  106. package/build/main/src/sdk/grpc/GrpcDependencyService.js +0 -86
  107. package/build/main/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_grpc_pb.d.ts +0 -0
  108. package/build/main/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_grpc_pb.js +0 -2
  109. package/build/main/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_pb.d.ts +0 -1
  110. package/build/main/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_pb.js +0 -404
  111. package/build/main/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_grpc_pb.d.ts +0 -39
  112. package/build/main/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_grpc_pb.js +0 -98
  113. package/build/main/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_pb.d.ts +0 -1
  114. package/build/main/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_pb.js +0 -1197
  115. package/build/main/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_grpc_pb.d.ts +0 -19
  116. package/build/main/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_grpc_pb.js +0 -66
  117. package/build/main/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_pb.d.ts +0 -1
  118. package/build/main/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_pb.js +0 -14
  119. package/build/main/src/sdk/scanner/Dispatcher/DispatchableItem.d.ts +0 -19
  120. package/build/main/src/sdk/scanner/Dispatcher/DispatchableItem.js +0 -43
  121. package/build/main/src/sdk/scanner/Dispatcher/Dispatcher.d.ts +0 -20
  122. package/build/main/src/sdk/scanner/Dispatcher/Dispatcher.js +0 -160
  123. package/build/main/src/sdk/scanner/Dispatcher/DispatcherResponse.d.ts +0 -12
  124. package/build/main/src/sdk/scanner/Dispatcher/DispatcherResponse.js +0 -33
  125. package/build/main/src/sdk/scanner/Dispatcher/GlobalControllerAborter.d.ts +0 -10
  126. package/build/main/src/sdk/scanner/Dispatcher/GlobalControllerAborter.js +0 -32
  127. package/build/main/src/sdk/scanner/Fingerprint.d.ts +0 -16
  128. package/build/main/src/sdk/scanner/Fingerprint.js +0 -78
  129. package/build/main/src/sdk/scanner/Scannable/ScannableItem.d.ts +0 -15
  130. package/build/main/src/sdk/scanner/Scannable/ScannableItem.js +0 -27
  131. package/build/main/src/sdk/scanner/Scanner.d.ts +0 -46
  132. package/build/main/src/sdk/scanner/Scanner.js +0 -283
  133. package/build/main/src/sdk/scanner/ScannerCfg.d.ts +0 -16
  134. package/build/main/src/sdk/scanner/ScannerCfg.js +0 -30
  135. package/build/main/src/sdk/scanner/ScannerTypes.d.ts +0 -121
  136. package/build/main/src/sdk/scanner/ScannerTypes.js +0 -48
  137. package/build/main/src/sdk/scanner/WfpProvider/FingerprintPackage.d.ts +0 -9
  138. package/build/main/src/sdk/scanner/WfpProvider/FingerprintPackage.js +0 -31
  139. package/build/main/src/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.d.ts +0 -20
  140. package/build/main/src/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.js +0 -492
  141. package/build/main/src/sdk/scanner/WfpProvider/WfpProvider.d.ts +0 -35
  142. package/build/main/src/sdk/scanner/WfpProvider/WfpProvider.js +0 -68
  143. package/build/main/src/sdk/scanner/WfpProvider/WfpSplitter/WfpSplitter.d.ts +0 -21
  144. package/build/main/src/sdk/scanner/WfpProvider/WfpSplitter/WfpSplitter.js +0 -139
  145. package/build/main/src/sdk/tree/File.d.ts +0 -7
  146. package/build/main/src/sdk/tree/File.js +0 -24
  147. package/build/main/src/sdk/tree/Filters/DecompressionFilter.d.ts +0 -7
  148. package/build/main/src/sdk/tree/Filters/DecompressionFilter.js +0 -21
  149. package/build/main/src/sdk/tree/Filters/DependencyFilter.d.ts +0 -7
  150. package/build/main/src/sdk/tree/Filters/DependencyFilter.js +0 -17
  151. package/build/main/src/sdk/tree/Filters/Filter.d.ts +0 -4
  152. package/build/main/src/sdk/tree/Filters/Filter.js +0 -6
  153. package/build/main/src/sdk/tree/Filters/ScanFilter.d.ts +0 -7
  154. package/build/main/src/sdk/tree/Filters/ScanFilter.js +0 -17
  155. package/build/main/src/sdk/tree/Folder.d.ts +0 -12
  156. package/build/main/src/sdk/tree/Folder.js +0 -58
  157. package/build/main/src/sdk/tree/Node.d.ts +0 -17
  158. package/build/main/src/sdk/tree/Node.js +0 -25
  159. package/build/main/src/sdk/tree/Tree.d.ts +0 -18
  160. package/build/main/src/sdk/tree/Tree.js +0 -70
  161. package/build/module/package.json +0 -120
  162. package/build/module/sdk/filters/DefaultFilterForDependencies.d.ts +0 -16
  163. package/build/module/sdk/filters/DefaultFilterForDependencies.js +0 -143
  164. package/build/module/sdk/filters/DefaultFilterForScanning.d.ts +0 -16
  165. package/build/module/sdk/filters/DefaultFilterForScanning.js +0 -192
  166. package/build/module/sdk/filters/filtering.d.ts +0 -32
  167. package/build/module/sdk/filters/filtering.js +0 -203
  168. package/build/module/src/cli/bin/cli-bin.d.ts +0 -2
  169. package/build/module/src/cli/bin/cli-bin.js +0 -67
  170. package/build/module/src/cli/commands/dep.d.ts +0 -1
  171. package/build/module/src/cli/commands/dep.js +0 -32
  172. package/build/module/src/cli/commands/helpers.d.ts +0 -2
  173. package/build/module/src/cli/commands/helpers.js +0 -19
  174. package/build/module/src/cli/commands/scan.d.ts +0 -1
  175. package/build/module/src/cli/commands/scan.js +0 -135
  176. package/build/module/src/cli/commands/wfp.d.ts +0 -1
  177. package/build/module/src/cli/commands/wfp.js +0 -48
  178. package/build/module/src/index.d.ts +0 -14
  179. package/build/module/src/index.js +0 -19
  180. package/build/module/src/sdk/DataLayer/DataLayerTypes.d.ts +0 -108
  181. package/build/module/src/sdk/DataLayer/DataLayerTypes.js +0 -5
  182. package/build/module/src/sdk/DataLayer/DataProviderManager.d.ts +0 -7
  183. package/build/module/src/sdk/DataLayer/DataProviderManager.js +0 -21
  184. package/build/module/src/sdk/DataLayer/DataProviders/ComponentDataProvider.d.ts +0 -13
  185. package/build/module/src/sdk/DataLayer/DataProviders/ComponentDataProvider.js +0 -159
  186. package/build/module/src/sdk/DataLayer/DataProviders/DependencyDataProvider.d.ts +0 -9
  187. package/build/module/src/sdk/DataLayer/DataProviders/DependencyDataProvider.js +0 -34
  188. package/build/module/src/sdk/DataLayer/DataProviders/LicenseDataProvider.d.ts +0 -18
  189. package/build/module/src/sdk/DataLayer/DataProviders/LicenseDataProvider.js +0 -145
  190. package/build/module/src/sdk/DataLayer/DataProviders/SummaryDataProvider.d.ts +0 -11
  191. package/build/module/src/sdk/DataLayer/DataProviders/SummaryDataProvider.js +0 -30
  192. package/build/module/src/sdk/Decompress/DecompressionManager.d.ts +0 -12
  193. package/build/module/src/sdk/Decompress/DecompressionManager.js +0 -67
  194. package/build/module/src/sdk/Decompress/Decompressor/DecompressTgz.d.ts +0 -5
  195. package/build/module/src/sdk/Decompress/Decompressor/DecompressTgz.js +0 -16
  196. package/build/module/src/sdk/Decompress/Decompressor/DecompressZips.d.ts +0 -5
  197. package/build/module/src/sdk/Decompress/Decompressor/DecompressZips.js +0 -18
  198. package/build/module/src/sdk/Decompress/Decompressor/Decompressor.d.ts +0 -10
  199. package/build/module/src/sdk/Decompress/Decompressor/Decompressor.js +0 -15
  200. package/build/module/src/sdk/Dependencies/DependencyScanner.d.ts +0 -11
  201. package/build/module/src/sdk/Dependencies/DependencyScanner.js +0 -93
  202. package/build/module/src/sdk/Dependencies/DependencyScannerCfg.d.ts +0 -4
  203. package/build/module/src/sdk/Dependencies/DependencyScannerCfg.js +0 -7
  204. package/build/module/src/sdk/Dependencies/DependencyTypes.d.ts +0 -21
  205. package/build/module/src/sdk/Dependencies/DependencyTypes.js +0 -2
  206. package/build/module/src/sdk/Dependencies/LocalDependency/DependencyTypes.d.ts +0 -16
  207. package/build/module/src/sdk/Dependencies/LocalDependency/DependencyTypes.js +0 -2
  208. package/build/module/src/sdk/Dependencies/LocalDependency/LocalDependency.d.ts +0 -8
  209. package/build/module/src/sdk/Dependencies/LocalDependency/LocalDependency.js +0 -96
  210. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/buildGradleParser.d.ts +0 -2
  211. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/buildGradleParser.js +0 -87
  212. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/golangParser.d.ts +0 -3
  213. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/golangParser.js +0 -88
  214. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/mavenParser.d.ts +0 -2
  215. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/mavenParser.js +0 -180
  216. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/npmParser.d.ts +0 -13
  217. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/npmParser.js +0 -175
  218. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/nugetParser.d.ts +0 -3
  219. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/nugetParser.js +0 -49
  220. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/pyParser.d.ts +0 -2
  221. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/pyParser.js +0 -57
  222. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/rubyParser.d.ts +0 -3
  223. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/rubyParser.js +0 -125
  224. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/utils.d.ts +0 -2
  225. package/build/module/src/sdk/Dependencies/LocalDependency/parsers/utils.js +0 -15
  226. package/build/module/src/sdk/Report/Report.d.ts +0 -8
  227. package/build/module/src/sdk/Report/Report.js +0 -20
  228. package/build/module/src/sdk/filters/DefaultFilterForDependencies.d.ts +0 -16
  229. package/build/module/src/sdk/filters/DefaultFilterForDependencies.js +0 -143
  230. package/build/module/src/sdk/filters/DefaultFilterForScanning.d.ts +0 -16
  231. package/build/module/src/sdk/filters/DefaultFilterForScanning.js +0 -192
  232. package/build/module/src/sdk/filters/filtering.d.ts +0 -32
  233. package/build/module/src/sdk/filters/filtering.js +0 -203
  234. package/build/module/src/sdk/grpc/GrpcDependencyService.d.ts +0 -11
  235. package/build/module/src/sdk/grpc/GrpcDependencyService.js +0 -64
  236. package/build/module/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_grpc_pb.d.ts +0 -0
  237. package/build/module/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_grpc_pb.js +0 -2
  238. package/build/module/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_pb.d.ts +0 -1
  239. package/build/module/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_pb.js +0 -404
  240. package/build/module/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_grpc_pb.d.ts +0 -39
  241. package/build/module/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_grpc_pb.js +0 -98
  242. package/build/module/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_pb.d.ts +0 -1
  243. package/build/module/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_pb.js +0 -1197
  244. package/build/module/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_grpc_pb.d.ts +0 -19
  245. package/build/module/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_grpc_pb.js +0 -66
  246. package/build/module/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_pb.d.ts +0 -1
  247. package/build/module/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_pb.js +0 -14
  248. package/build/module/src/sdk/scanner/Dispatcher/DispatchableItem.d.ts +0 -19
  249. package/build/module/src/sdk/scanner/Dispatcher/DispatchableItem.js +0 -37
  250. package/build/module/src/sdk/scanner/Dispatcher/Dispatcher.d.ts +0 -20
  251. package/build/module/src/sdk/scanner/Dispatcher/Dispatcher.js +0 -135
  252. package/build/module/src/sdk/scanner/Dispatcher/DispatcherResponse.d.ts +0 -12
  253. package/build/module/src/sdk/scanner/Dispatcher/DispatcherResponse.js +0 -30
  254. package/build/module/src/sdk/scanner/Dispatcher/GlobalControllerAborter.d.ts +0 -10
  255. package/build/module/src/sdk/scanner/Dispatcher/GlobalControllerAborter.js +0 -26
  256. package/build/module/src/sdk/scanner/Fingerprint.d.ts +0 -16
  257. package/build/module/src/sdk/scanner/Fingerprint.js +0 -54
  258. package/build/module/src/sdk/scanner/Scannable/ScannableItem.d.ts +0 -15
  259. package/build/module/src/sdk/scanner/Scannable/ScannableItem.js +0 -24
  260. package/build/module/src/sdk/scanner/Scanner.d.ts +0 -46
  261. package/build/module/src/sdk/scanner/Scanner.js +0 -275
  262. package/build/module/src/sdk/scanner/ScannerCfg.d.ts +0 -16
  263. package/build/module/src/sdk/scanner/ScannerCfg.js +0 -27
  264. package/build/module/src/sdk/scanner/ScannerTypes.d.ts +0 -121
  265. package/build/module/src/sdk/scanner/ScannerTypes.js +0 -46
  266. package/build/module/src/sdk/scanner/WfpProvider/FingerprintPackage.d.ts +0 -9
  267. package/build/module/src/sdk/scanner/WfpProvider/FingerprintPackage.js +0 -28
  268. package/build/module/src/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.d.ts +0 -20
  269. package/build/module/src/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.js +0 -486
  270. package/build/module/src/sdk/scanner/WfpProvider/WfpProvider.d.ts +0 -35
  271. package/build/module/src/sdk/scanner/WfpProvider/WfpProvider.js +0 -65
  272. package/build/module/src/sdk/scanner/WfpProvider/WfpSplitter/WfpSplitter.d.ts +0 -21
  273. package/build/module/src/sdk/scanner/WfpProvider/WfpSplitter/WfpSplitter.js +0 -132
  274. package/build/module/src/sdk/tree/File.d.ts +0 -7
  275. package/build/module/src/sdk/tree/File.js +0 -19
  276. package/build/module/src/sdk/tree/Filters/DecompressionFilter.d.ts +0 -7
  277. package/build/module/src/sdk/tree/Filters/DecompressionFilter.js +0 -18
  278. package/build/module/src/sdk/tree/Filters/DependencyFilter.d.ts +0 -7
  279. package/build/module/src/sdk/tree/Filters/DependencyFilter.js +0 -14
  280. package/build/module/src/sdk/tree/Filters/Filter.d.ts +0 -4
  281. package/build/module/src/sdk/tree/Filters/Filter.js +0 -3
  282. package/build/module/src/sdk/tree/Filters/ScanFilter.d.ts +0 -7
  283. package/build/module/src/sdk/tree/Filters/ScanFilter.js +0 -14
  284. package/build/module/src/sdk/tree/Folder.d.ts +0 -12
  285. package/build/module/src/sdk/tree/Folder.js +0 -53
  286. package/build/module/src/sdk/tree/Node.d.ts +0 -17
  287. package/build/module/src/sdk/tree/Node.js +0 -22
  288. package/build/module/src/sdk/tree/Tree.d.ts +0 -18
  289. package/build/module/src/sdk/tree/Tree.js +0 -64
  290. package/package-lock.json +0 -17116
  291. package/src/cli/bin/cli-bin.ts +0 -81
  292. package/src/cli/commands/dep.ts +0 -37
  293. package/src/cli/commands/helpers.ts +0 -19
  294. package/src/cli/commands/scan.ts +0 -173
  295. package/src/cli/commands/wfp.ts +0 -60
  296. package/src/index.ts +0 -31
  297. package/src/sdk/DataLayer/DataLayerTypes.ts +0 -129
  298. package/src/sdk/DataLayer/DataProviderManager.ts +0 -27
  299. package/src/sdk/DataLayer/DataProviders/ComponentDataProvider.ts +0 -195
  300. package/src/sdk/DataLayer/DataProviders/DependencyDataProvider.ts +0 -48
  301. package/src/sdk/DataLayer/DataProviders/LicenseDataProvider.ts +0 -184
  302. package/src/sdk/DataLayer/DataProviders/SummaryDataProvider.ts +0 -47
  303. package/src/sdk/Decompress/DecompressionManager.ts +0 -91
  304. package/src/sdk/Decompress/Decompressor/DecompressTgz.ts +0 -20
  305. package/src/sdk/Decompress/Decompressor/DecompressZips.ts +0 -21
  306. package/src/sdk/Decompress/Decompressor/Decompressor.ts +0 -20
  307. package/src/sdk/Dependencies/DependencyScanner.ts +0 -108
  308. package/src/sdk/Dependencies/DependencyScannerCfg.ts +0 -7
  309. package/src/sdk/Dependencies/DependencyTypes.ts +0 -24
  310. package/src/sdk/Dependencies/LocalDependency/DependencyTypes.ts +0 -21
  311. package/src/sdk/Dependencies/LocalDependency/LocalDependency.ts +0 -111
  312. package/src/sdk/Dependencies/LocalDependency/parsers/buildGradleParser.ts +0 -115
  313. package/src/sdk/Dependencies/LocalDependency/parsers/golangParser.ts +0 -130
  314. package/src/sdk/Dependencies/LocalDependency/parsers/mavenParser.ts +0 -209
  315. package/src/sdk/Dependencies/LocalDependency/parsers/npmParser.ts +0 -227
  316. package/src/sdk/Dependencies/LocalDependency/parsers/nugetParser.ts +0 -64
  317. package/src/sdk/Dependencies/LocalDependency/parsers/pyParser.ts +0 -58
  318. package/src/sdk/Dependencies/LocalDependency/parsers/rubyParser.ts +0 -174
  319. package/src/sdk/Dependencies/LocalDependency/parsers/utils.ts +0 -15
  320. package/src/sdk/FileCount/FileCount.ts +0 -81
  321. package/src/sdk/FileCount/FileCountFilter.ts +0 -14
  322. package/src/sdk/FileCount/Interfaces.ts +0 -23
  323. package/src/sdk/Filtering/DefaultFilterForDependencies.ts +0 -148
  324. package/src/sdk/Filtering/DefaultFilterForScanning.ts +0 -206
  325. package/src/sdk/Filtering/Filtering.ts +0 -273
  326. package/src/sdk/Report/Report.ts +0 -30
  327. package/src/sdk/grpc/GrpcDependencyService.ts +0 -72
  328. package/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_grpc_pb.d.ts +0 -1
  329. package/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_grpc_pb.js +0 -1
  330. package/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_pb.d.ts +0 -79
  331. package/src/sdk/grpc/scanoss/api/common/v2/scanoss-common_pb.js +0 -482
  332. package/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_grpc_pb.d.ts +0 -30
  333. package/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_grpc_pb.js +0 -109
  334. package/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_pb.d.ts +0 -206
  335. package/src/sdk/grpc/scanoss/api/dependencies/v2/scanoss-dependencies_pb.js +0 -1489
  336. package/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_grpc_pb.d.ts +0 -25
  337. package/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_grpc_pb.js +0 -73
  338. package/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_pb.d.ts +0 -6
  339. package/src/sdk/grpc/scanoss/api/scanning/v2/scanoss-scanning_pb.js +0 -15
  340. package/src/sdk/scanner/Dispatcher/DispatchableItem.ts +0 -62
  341. package/src/sdk/scanner/Dispatcher/Dispatcher.ts +0 -173
  342. package/src/sdk/scanner/Dispatcher/DispatcherResponse.ts +0 -40
  343. package/src/sdk/scanner/Dispatcher/GlobalControllerAborter.ts +0 -33
  344. package/src/sdk/scanner/Fingerprint.ts +0 -82
  345. package/src/sdk/scanner/Scannable/ScannableItem.ts +0 -43
  346. package/src/sdk/scanner/Scanner.ts +0 -360
  347. package/src/sdk/scanner/ScannerCfg.ts +0 -43
  348. package/src/sdk/scanner/ScannerTypes.ts +0 -127
  349. package/src/sdk/scanner/WfpProvider/FingerprintPackage.ts +0 -34
  350. package/src/sdk/scanner/WfpProvider/WfpCalculator/WfpCalculator.ts +0 -516
  351. package/src/sdk/scanner/WfpProvider/WfpProvider.ts +0 -105
  352. package/src/sdk/scanner/WfpProvider/WfpSplitter/WfpSplitter.ts +0 -184
  353. package/src/sdk/tree/File.ts +0 -22
  354. package/src/sdk/tree/Filters/DecompressionFilter.ts +0 -22
  355. package/src/sdk/tree/Filters/DependencyFilter.ts +0 -22
  356. package/src/sdk/tree/Filters/Filter.ts +0 -5
  357. package/src/sdk/tree/Filters/ScanFilter.ts +0 -22
  358. package/src/sdk/tree/Folder.ts +0 -57
  359. package/src/sdk/tree/Node.ts +0 -39
  360. package/src/sdk/tree/Tree.ts +0 -82
  361. package/tests/scanoss.sh +0 -56
  362. package/tests/sdk/DataLayer/DataProviders/ComponentDataProvider.spec.ts +0 -176
  363. package/tests/sdk/DataLayer/DataProviders/DependencyDataProvider.spec.ts +0 -51
  364. package/tests/sdk/DataLayer/DataProviders/SummaryDataProvider.spec.ts +0 -35
  365. package/tests/sdk/DataLayer/DataProviders/samples/results-with-dep.json +0 -665
  366. package/tests/sdk/DataLayer/DataProviders/samples/results.json +0 -556
  367. package/tests/sdk/DataLayer/samples/simple/results-with-dep.json +0 -665
  368. package/tests/sdk/DataLayer/samples/simple-1/output1.json +0 -1196
  369. package/tests/sdk/Dependencies/LocalDependency/LocalDependency.spec.ts +0 -24
  370. package/tests/sdk/Dependencies/LocalDependency/Parsers/buildGradle.spec.ts +0 -48
  371. package/tests/sdk/Dependencies/LocalDependency/Parsers/golangParser.spec.ts +0 -146
  372. package/tests/sdk/Dependencies/LocalDependency/Parsers/npmParser.spec.ts +0 -135
  373. package/tests/sdk/Dependencies/LocalDependency/Parsers/nugetParser.spec.ts +0 -73
  374. package/tests/sdk/Dependencies/LocalDependency/Parsers/pomParser.spec.ts +0 -45
  375. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/1/Gemfile +0 -6
  376. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/1/Gemfile~ +0 -0
  377. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/2/Gemfile +0 -3
  378. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/2/Gemfile~ +0 -6
  379. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/3/Gemfile +0 -7
  380. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/3/Gemfile~ +0 -6
  381. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/4/Gemfile +0 -31
  382. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile/4/Gemfile~ +0 -7
  383. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile.lock/1/Gemfile.lock +0 -180
  384. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile.lock/2/Gemfile.lock +0 -60
  385. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/Gemfile.lock/2/Gemfile.lock~ +0 -0
  386. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/go.sum/1/go.sum +0 -119
  387. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/go.sum/depJSON.sh +0 -23
  388. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/gradle/1/build.gradle +0 -26
  389. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/gradle/2/build.gradle +0 -16
  390. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/nuget/NoDependencies.csproj +0 -115
  391. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/nuget/netcore-2.csproj +0 -18
  392. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/nuget/netcore.csproj +0 -14
  393. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/nuget/packageConfig-1/packages.config +0 -5
  394. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/pom.xml/1/pom.xml +0 -670
  395. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/pom.xml/2/pom.xml +0 -780
  396. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/generate_expected_output.sh +0 -4
  397. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1/yarn.lock +0 -50
  398. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1/yarn.lock-expected +0 -13
  399. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1-complex/yarn.lock +0 -27
  400. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1-complex/yarn.lock-expected +0 -8
  401. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1_2/scancode-out.json +0 -149662
  402. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1_2/yarn.lock +0 -8409
  403. package/tests/sdk/Dependencies/LocalDependency/Parsers/samples/yarn-lock/v1_2/yarn.lock-expected +0 -1153
  404. package/tests/sdk/FileCount/FileCount.spec.ts +0 -35
  405. package/tests/sdk/FileCount/samples/16557/.y.ts +0 -27
  406. package/tests/sdk/FileCount/samples/16557/.z.ts +0 -129
  407. package/tests/sdk/FileCount/samples/16557/files/a.ts +0 -195
  408. package/tests/sdk/FileCount/samples/16557/files/b.ts +0 -184
  409. package/tests/sdk/FileCount/samples/16557/files/c.ts +0 -47
  410. package/tests/sdk/FileCount/samples/22036/files/a.ts +0 -195
  411. package/tests/sdk/FileCount/samples/22036/files/b.ts +0 -184
  412. package/tests/sdk/FileCount/samples/22036/files/c.ts +0 -47
  413. package/tests/sdk/FileCount/samples/22036/files/d.ts +0 -48
  414. package/tests/sdk/FileCount/samples/22036/y.ts +0 -27
  415. package/tests/sdk/FileCount/samples/22036/z.ts +0 -129
  416. package/tests/sdk/Scanner/WfpProvider/WfpCalculator/WfpCalculator.spec.ts +0 -102
  417. package/tests/sdk/Scanner/WfpProvider/WfpCalculator/samples/file1.c +0 -41
  418. package/tests/sdk/Scanner/WfpProvider/WfpCalculator/samples/file2.go +0 -87
  419. package/tests/sdk/Scanner/WfpProvider/WfpSplitter/WfpSplitter.spec.ts +0 -35
  420. package/tests/sdk/Scanner/WfpProvider/WfpSplitter/samples/wfp.wfp +0 -68
  421. package/tests/sdk/Scanner/WfpProvider/WfpSplitter/samples/wfp.wfp~ +0 -68
  422. package/tsconfig.json +0 -31
  423. package/tsconfig.module.json +0 -11
  424. package/yarn.lock +0 -5481
@@ -1,174 +0,0 @@
1
- import path from "path";
2
- import { PackageURL } from "packageurl-js";
3
- import { ILocalDependency, ILocalPurl } from '../DependencyTypes';
4
-
5
-
6
- const PURL_TYPE = 'gem';
7
-
8
-
9
- // Parse a gemfile file from ruby
10
- // See reference on: https://bundler.io/gemfile.html
11
- // and https://bundler.io/man/gemfile.5.html
12
- const MANIFEST_FILE = 'Gemfile';
13
- export function gemfileParser(fileContent: string, filePath: string): Promise<ILocalDependency> {
14
-
15
- // If the file is not a manifest file, return an empty results
16
- const results: ILocalDependency = {file: filePath, purls: []};
17
- if(path.basename(filePath) != MANIFEST_FILE)
18
- return Promise.resolve(results);
19
-
20
-
21
- const lines: Array<string> = fileContent.split('\n');
22
- let compName: string = '';
23
-
24
- for (let line of lines) {
25
- line = line.trim();
26
- if (!line.startsWith('#') && line.length>0) { // Avoid comments and empty lines
27
- // Line contains a package name and/or version.
28
- const res = line.match(/^gem\s*(["']\w+["'])/); //Extract name
29
- if (res) {
30
- compName = res.length > 1 ? res[1] : ' ';
31
- compName = compName.replace(/['"]/g, '');
32
- const purlString = new PackageURL(PURL_TYPE, undefined, compName, undefined, undefined, undefined).toString();
33
- results.purls.push({purl: purlString});
34
- }
35
- }
36
- }
37
- return Promise.resolve(results);
38
- }
39
-
40
-
41
- const MANIFEST_FILE_1 = 'Gemfile.lock';
42
- export function gemfilelockParser(fileContent: string, filePath: string): Promise<ILocalDependency> {
43
-
44
- // If the file is not a manifest file, return an empty results
45
- const results: ILocalDependency = {file: filePath, purls: []};
46
- if(path.basename(filePath) != MANIFEST_FILE_1)
47
- return Promise.resolve(results);
48
-
49
- const gemlockParser = new GemfileLockParser();
50
- const purls = gemlockParser.getDependencies(fileContent);
51
- for (const purl of purls) {
52
- results.purls.push(purl);
53
- }
54
-
55
- return Promise.resolve(results);
56
- }
57
-
58
-
59
- // Section headings: these are also used as switches to track a parsing state
60
-
61
- const PATH = 'PATH';
62
- const GIT = 'GIT';
63
- const SVN = 'SVN';
64
- const GEM = 'GEM';
65
- const PLATFORMS = 'PLATFORMS';
66
- const DEPENDENCIES = 'DEPENDENCIES';
67
- const SPECS = ' specs:';
68
-
69
- // types of Gems, which is really where they are provisioned from
70
- // RubyGems repo, local path or VCS
71
- const GEM_TYPES = [GEM, PATH, GIT, SVN];
72
-
73
-
74
- const specRegex = /(?<name>[^ \)\(,!:]+)?(?: \((?<version>[^-]*?)(?:-(?<platform>[^!]*))?\))?/;
75
- const firstDepLevelRegex = /^ {4}(?! )/;
76
- /*
77
- The parsing use a simple state machine, switching states based on sections
78
- headings. The result is a list of purls
79
- */
80
- class GemfileLockParser {
81
-
82
- private statesMap;
83
-
84
- private state;
85
-
86
- private current_options: Record<string, string>;
87
-
88
- private current_gem;
89
-
90
- private purlList: Array<ILocalPurl>;
91
-
92
- constructor () {
93
-
94
- this.purlList = [];
95
-
96
- // map of a line start string to the next parsing state function
97
- this.statesMap = {};
98
- this.statesMap[DEPENDENCIES] = this.parseDependency;
99
- this.statesMap[PLATFORMS] = this.parsePlatform;
100
- this.statesMap[GIT] = this.parseOptions;
101
- this.statesMap[PATH] = this.parseOptions;
102
- this.statesMap[SVN] = this.parseOptions;
103
- this.statesMap[GEM] = this.parseOptions;
104
- this.statesMap[SPECS] = this.parseSpec;
105
- }
106
-
107
- public getDependencies(filecontent: string): Array<ILocalPurl> {
108
- this.resetState();
109
- let file = filecontent.split('\n');
110
- for (let line of file) {
111
- line = line.trimEnd();
112
-
113
- //reset state on empty lines
114
- if (!line.length) {
115
- this.resetState();
116
- continue;
117
- }
118
-
119
- //switch to new state
120
- if (line in this.statesMap) {
121
- if (GEM_TYPES.includes(line))
122
- this.current_gem = line;
123
- this.state=this.statesMap[line];
124
- continue;
125
- }
126
-
127
- // process the line
128
- if (this.state) this.state(line);
129
- }
130
- return this.purlList;
131
- }
132
-
133
- private resetState() {
134
- this.current_options = {};
135
- this.state = null;
136
- }
137
-
138
- private parseOptions(line: string) {
139
- const match = line.match(/\s*(\w+):\s*(.*)/);
140
- const key = match.length>=1 ? match[1] : null;
141
- const value = match.length>=2 ? match[2] : null;
142
- if(key) this.current_options[key] = value;
143
- }
144
-
145
- private parseDependency(line: string) {}
146
- private parsePlatform(line: string){}
147
-
148
-
149
- private parseSpec(line: string) {
150
-
151
- if(this.current_gem == GEM) {
152
- if(firstDepLevelRegex.test(line)) {
153
- line = line.trimStart();
154
- const match = line.match(specRegex);
155
-
156
- const purl = new PackageURL( PURL_TYPE,
157
- null,
158
- match.groups.name,
159
- null,
160
- null,
161
- null ).toString();
162
- this.purlList.push({purl: purl, requirement: match.groups.version});
163
-
164
- } else { // Second level of dependence
165
-
166
- }
167
- }
168
-
169
- if(this.current_gem == GIT) {}
170
-
171
- // Purl from local dependencies are not generated
172
- if(this.current_gem == PATH){}
173
- }
174
- }
@@ -1,15 +0,0 @@
1
- import { URL } from "url";
2
-
3
- export function isValidUrl(string: string): boolean {
4
- let url: URL;
5
- try {
6
- new URL(string);
7
- } catch (_) {
8
- return false;
9
- }
10
- return true;
11
- }
12
-
13
- export function isValidPath(string: string): boolean {
14
- return /^((?:\.\.?)|(?:[a-zA-Z]:\\)|(?:\/))/gm.test(string);
15
- }
@@ -1,81 +0,0 @@
1
- import fs from "fs";
2
- import path from "path";
3
- import {FileCountOptions, Format, IDirSummary, IFileSummary} from "./Interfaces";
4
- import { FilterList } from '../Filtering/Filtering';
5
- import { FileCountFilter } from './FileCountFilter';
6
-
7
-
8
- export class FileCount {
9
-
10
- public static async walk(rootPath: string, option?: FileCountOptions) {
11
-
12
- //By default hidden folders and files are ignored
13
- const filters = new FilterList(FileCountFilter);
14
- if(option?.filters?.countHidden) filters.unload();
15
-
16
- const data = await this.exploreBFS(rootPath,filters);
17
-
18
- if (option?.output == Format.CSV) return this.produceCsv(data.fileSummary);
19
- return data;
20
- }
21
-
22
-
23
-
24
- private static async exploreBFS(rootPath: string, filters: FilterList): Promise<IDirSummary> {
25
-
26
- const results: IDirSummary = {fileSummary: new Map(), totalFileSize: 0};
27
- const queue: Array<string> = [];
28
-
29
- //TODO: Improve the queue implementation for a linked list
30
- queue.push(rootPath)
31
-
32
- while(queue.length) {
33
- const currentPath = queue.shift() as string;
34
- const entries = await fs.promises.readdir( currentPath , {withFileTypes: true});
35
-
36
- for await (const entry of entries) {
37
- const newPath = path.join(currentPath, entry.name);
38
- if (filters.include(newPath)) {
39
- if (entry.isDirectory()) queue.push(newPath);
40
- else if (entry.isFile() && !entry.isSymbolicLink()) {
41
- const currentExt = path.extname(entry.name);
42
- const currentFileSize = (await fs.promises.stat(path.join(currentPath, entry.name))).size;
43
- if (results.fileSummary.has(currentExt) ) {
44
- const fileSum = results.fileSummary.get(currentExt)
45
- fileSum.count++
46
- fileSum.size += currentFileSize;
47
- } else {
48
- results.fileSummary.set(currentExt, {count: 1, size: currentFileSize, percentage: 0});
49
- }
50
- results.totalFileSize+= currentFileSize;
51
- }
52
- }
53
- }
54
- }
55
-
56
- //Update percentage
57
- for (const ext of results.fileSummary.keys()) {
58
- const entry = results.fileSummary.get(ext);
59
- entry.percentage = Number((entry.size / results.totalFileSize).toFixed(2));
60
- }
61
- return results;
62
- }
63
-
64
-
65
- private static produceCsv(data: Map<string,IFileSummary>): string {
66
- let csv = '';
67
- for (const key of data.keys()) {
68
- const value = data.get(key);
69
- const newLine = `${key},${value?.count},${value?.percentage}\n`
70
- csv+=newLine;
71
- }
72
- return csv;
73
- }
74
-
75
-
76
- }
77
-
78
-
79
-
80
-
81
-
@@ -1,14 +0,0 @@
1
- import {
2
- FilterScope,
3
- FilterType,
4
- FilterListType,
5
- NameFilter, IFilter
6
- } from '../Filtering/Filtering';
7
-
8
- export const FileCountFilter: IFilter = {
9
- type: FilterListType.BANNED,
10
- filters: [
11
- { ftype: FilterType.NAME, condition: NameFilter.STARTS, value: '.', scope: FilterScope.ALL },
12
- ],
13
- };
14
-
@@ -1,23 +0,0 @@
1
- export interface IDirSummary {
2
- fileSummary: Map<string,IFileSummary>;
3
- totalFileSize: number;
4
- }
5
-
6
- export interface IFileSummary {
7
- count: number;
8
- size: number;
9
- percentage: number;
10
- }
11
-
12
-
13
- export enum Format {
14
- RAW,
15
- CSV
16
- }
17
- export interface FileCountOptions {
18
- filters?: {
19
- countHidden: boolean
20
- }
21
- output: Format;
22
- }
23
-
@@ -1,148 +0,0 @@
1
- // ------ FILTERS SYNC WITH PYTHON CLIENT 06/10/2021 ------ //
2
- import { FilterListType, FilterScope, FilterType, IFilter } from './Filtering';
3
-
4
-
5
- export const defaultFilterForDependencies: IFilter = {
6
- type: FilterListType.BANNED,
7
- filters: [
8
- { condition: '=', value: '0', ftype: FilterType.SIZE, scope: FilterScope.FILE },
9
-
10
- //Folders and files filters
11
- { condition: 'starts', value: '.', ftype: FilterType.NAME, scope: FilterScope.ALL },
12
-
13
- //Folder filters
14
- { condition: 'ends', value: '.egg-info', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
15
-
16
- { condition: 'fullmatch', value: 'nbproject', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
17
- { condition: 'fullmatch', value: 'nbbuild', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
18
- { condition: 'fullmatch', value: 'nbdist', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
19
- { condition: 'fullmatch', value: '__pycache__', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
20
- { condition: 'fullmatch', value: 'venv', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
21
- { condition: 'fullmatch', value: '_yardoc', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
22
- { condition: 'fullmatch', value: 'eggs', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
23
- { condition: 'fullmatch', value: 'wheels', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
24
- { condition: 'fullmatch', value: 'node_modules', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
25
- { condition: 'fullmatch', value: '__pypackages__', ftype: FilterType.NAME, scope: FilterScope.FOLDER },
26
-
27
- { condition: '=', value: '.1', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
28
- { condition: '=', value: '.2', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
29
- { condition: '=', value: '.3', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
30
- { condition: '=', value: '.4', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
31
- { condition: '=', value: '.5', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
32
- { condition: '=', value: '.6', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
33
- { condition: '=', value: '.7', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
34
- { condition: '=', value: '.8', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
35
- { condition: '=', value: '.9', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
36
- { condition: '=', value: '.ac', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
37
- { condition: '=', value: '.adoc', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
38
- { condition: '=', value: '.am', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
39
- { condition: '=', value: '.asciidoc', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
40
- { condition: '=', value: '.bmp', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
41
- { condition: '=', value: '.build', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
42
- { condition: '=', value: '.cfg', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
43
- { condition: '=', value: '.chm', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
44
- { condition: '=', value: '.class', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
45
- { condition: '=', value: '.cmake', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
46
- { condition: '=', value: '.cnf', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
47
- { condition: '=', value: '.conf', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
48
- { condition: '=', value: '.contributors', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
49
- { condition: '=', value: '.copying', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
50
- { condition: '=', value: '.crt', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
51
- { condition: '=', value: '.css', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
52
- { condition: '=', value: '.csv', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
53
- { condition: '=', value: '.dat', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
54
- { condition: '=', value: '.data', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
55
- { condition: '=', value: '.doc', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
56
- { condition: '=', value: '.docx', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
57
- { condition: '=', value: '.dtd', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
58
- { condition: '=', value: '.dts', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
59
- { condition: '=', value: '.iws', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
60
- { condition: '=', value: '.c9', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
61
- { condition: '=', value: '.c9revisions', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
62
- { condition: '=', value: '.dtsi', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
63
- { condition: '=', value: '.dump', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
64
- { condition: '=', value: '.eot', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
65
- { condition: '=', value: '.eps', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
66
- { condition: '=', value: '.geojson', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
67
- { condition: '=', value: '.gdoc', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
68
- { condition: '=', value: '.gif', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
69
- { condition: '=', value: '.glif', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
70
- { condition: '=', value: '.gmo', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
71
- { condition: '=', value: '.guess', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
72
- { condition: '=', value: '.htm', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
73
- { condition: '=', value: '.html', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
74
- { condition: '=', value: '.ico', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
75
- { condition: '=', value: '.iml', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
76
- { condition: '=', value: '.in', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
77
- { condition: '=', value: '.inc', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
78
- { condition: '=', value: '.info', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
79
- { condition: '=', value: '.ini', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
80
- { condition: '=', value: '.jpeg', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
81
- { condition: '=', value: '.jpg', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
82
- { condition: '=', value: '.m4', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
83
- { condition: '=', value: '.map', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
84
- { condition: '=', value: '.markdown', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
85
- { condition: '=', value: '.md', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
86
- { condition: '=', value: '.md5', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
87
- { condition: '=', value: '.meta', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
88
- { condition: '=', value: '.mk', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
89
- { condition: '=', value: '.mxml', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
90
- { condition: '=', value: '.o', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
91
- { condition: '=', value: '.otf', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
92
- { condition: '=', value: '.out', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
93
- { condition: '=', value: '.pbtxt', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
94
- { condition: '=', value: '.pdf', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
95
- { condition: '=', value: '.phtml', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
96
- { condition: '=', value: '.plist', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
97
- { condition: '=', value: '.png', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
98
- { condition: '=', value: '.po', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
99
- { condition: '=', value: '.ppt', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
100
- { condition: '=', value: '.prefs', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
101
- { condition: '=', value: '.properties', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
102
- { condition: '=', value: '.qdoc', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
103
- { condition: '=', value: '.result', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
104
- { condition: '=', value: '.rgb', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
105
- { condition: '=', value: '.rst', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
106
- { condition: '=', value: '.scss', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
107
- { condition: '=', value: '.sha', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
108
- { condition: '=', value: '.sha1', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
109
- { condition: '=', value: '.sha2', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
110
- { condition: '=', value: '.sha256', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
111
- { condition: '=', value: '.sln', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
112
- { condition: '=', value: '.spec', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
113
- { condition: '=', value: '.sql', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
114
- { condition: '=', value: '.sub', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
115
- { condition: '=', value: '.svg', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
116
- { condition: '=', value: '.svn-base', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
117
- { condition: '=', value: '.tab', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
118
- { condition: '=', value: '.template', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
119
- { condition: '=', value: '.test', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
120
- { condition: '=', value: '.tex', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
121
- { condition: '=', value: '.tiff', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
122
- { condition: '=', value: '.ttf', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
123
- { condition: '=', value: '.utf-8', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
124
- { condition: '=', value: '.vim', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
125
- { condition: '=', value: '.wav', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
126
- { condition: '=', value: '.whl', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
127
- { condition: '=', value: '.woff', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
128
- { condition: '=', value: '.xht', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
129
- { condition: '=', value: '.xhtml', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
130
- { condition: '=', value: '.xls', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
131
- { condition: '=', value: '.xlsx', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
132
- { condition: '=', value: '.xpm', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
133
- { condition: '=', value: '.xsd', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
134
- { condition: '=', value: '.xul', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
135
- { condition: '=', value: '.wfp', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
136
- { condition: '=', value: '.editorconfig', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
137
- { condition: '=', value: '.dotcover', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
138
- { condition: '=', value: '.pid', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
139
- { condition: '=', value: '.lcov', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
140
- { condition: '=', value: '.egg', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
141
- { condition: '=', value: '.manifest', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
142
- { condition: '=', value: '.cache', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
143
- { condition: '=', value: '.coverage', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
144
- { condition: '=', value: '.cover', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
145
- { condition: '=', value: '.lst', ftype: FilterType.EXTENSION, scope: FilterScope.FILE },
146
- ],
147
- };
148
-