You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -57,162 +57,158 @@ export function createMarkdownReport(data: PurlDataResponse) {
57
57
},
58
58
}=data
59
59
60
-
constarr: string[]=[]
61
-
62
-
arr.push('# Complete Package Score')
63
-
arr.push('')
60
+
consto: string[]=['# Complete Package Score','']
64
61
if(dependencyCount){
65
-
arr.push(
62
+
o.push(
66
63
`This is a Socket report for the package *"${purl}"* and its *${dependencyCount}* direct/transitive dependencies.`,
67
64
)
68
65
}else{
69
-
arr.push(
66
+
o.push(
70
67
`This is a Socket report for the package *"${purl}"*. It has *no dependencies*.`,
71
68
)
72
69
}
73
-
arr.push('')
70
+
o.push('')
74
71
if(dependencyCount){
75
-
arr.push(
72
+
o.push(
76
73
`It will show you the shallow score for just the package itself and a deep score for all the transitives combined. Additionally you can see which capabilities were found and the top alerts as well as a package that was responsible for it.`,
77
74
)
78
75
}else{
79
-
arr.push(
76
+
o.push(
80
77
`It will show you the shallow score for the package itself, which capabilities were found, and its top alerts.`,
81
78
)
82
-
arr.push('')
83
-
arr.push(
79
+
o.push('')
80
+
o.push(
84
81
'Since it has no dependencies, the shallow score is also the deep score.',
85
82
)
86
83
}
87
-
arr.push('')
84
+
o.push('')
88
85
if(dependencyCount){
89
86
// This doesn't make much sense if there are no dependencies. Better to omit it.
90
-
arr.push(
87
+
o.push(
91
88
'The report should give you a good insight into the status of this package.',
92
89
)
93
-
arr.push('')
94
-
arr.push('## Package itself')
95
-
arr.push('')
96
-
arr.push(
90
+
o.push('')
91
+
o.push('## Package itself')
92
+
o.push('')
93
+
o.push(
97
94
'Here are results for the package itself (excluding data from dependencies).',
98
95
)
99
96
}else{
100
-
arr.push('## Report')
101
-
arr.push('')
102
-
arr.push(
97
+
o.push('## Report')
98
+
o.push('')
99
+
o.push(
103
100
'The report should give you a good insight into the status of this package.',
104
101
)
105
102
}
106
-
arr.push('')
107
-
arr.push('### Shallow Score')
108
-
arr.push('')
109
-
arr.push('This score is just for the package itself:')
arr.push('There are currently no alerts for this package.')
140
+
o.push('There are currently no alerts for this package.')
144
141
}
145
-
arr.push('')
142
+
o.push('')
146
143
if(dependencyCount){
147
-
arr.push('## Transitive Package Results')
148
-
arr.push('')
149
-
arr.push(
144
+
o.push('## Transitive Package Results')
145
+
o.push('')
146
+
o.push(
150
147
'Here are results for the package and its direct/transitive dependencies.',
151
148
)
152
-
arr.push('')
153
-
arr.push('### Deep Score')
154
-
arr.push('')
155
-
arr.push(
149
+
o.push('')
150
+
o.push('### Deep Score')
151
+
o.push('')
152
+
o.push(
156
153
'This score represents the package and and its direct/transitive dependencies:',
157
154
)
158
-
arr.push(
155
+
o.push(
159
156
`The function used to calculate the values in aggregate is: *"${func}"*`,
160
157
)
161
-
arr.push('')
162
-
arr.push('- Overall: '+score.overall)
163
-
arr.push('- Maintenance: '+score.maintenance)
164
-
arr.push('- Quality: '+score.quality)
165
-
arr.push('- Supply Chain: '+score.supplyChain)
166
-
arr.push('- Vulnerability: '+score.vulnerability)
167
-
arr.push('- License: '+score.license)
168
-
arr.push('')
169
-
arr.push('### Capabilities')
170
-
arr.push('')
171
-
arr.push(
158
+
o.push('')
159
+
o.push(`- Overall: ${score.overall}`)
160
+
o.push(`- Maintenance: ${score.maintenance}`)
161
+
o.push(`- Quality: ${score.quality}`)
162
+
o.push(`- Supply Chain: ${score.supplyChain}`)
163
+
o.push(`- Vulnerability: ${score.vulnerability}`)
164
+
o.push(`- License: ${score.license}`)
165
+
o.push('')
166
+
o.push('### Capabilities')
167
+
o.push('')
168
+
o.push(
172
169
'These are the packages with the lowest recorded score. If there is more than one with the lowest score, just one is shown here. This may help you figure out the source of low scores.',
0 commit comments