@@ -4,14 +4,8 @@ const score = require('./score')
44
55const SOURCE_PACKAGE_TYPE = 'sourcePackage'
66const ALTERNATIVE_PACKAGE_TYPE = 'alternativePackage'
7- const PACKAGE_DISPLAY_HEADERS = [ 'Package Name' , 'Smart Version' , 'License' , 'Description' , 'My Usage' , 'Score' ]
8- const VERSION_DISPLAY_HEADERS = [
9- 'Package Name' ,
10- 'package.json Version' ,
11- 'Smart Version' ,
12- 'Latest Version' ,
13- 'Description'
14- ]
7+ const PACKAGE_DISPLAY_HEADERS = [ 'Package Name' , 'Version' , 'License' , 'Description' , 'My Usage' , 'Score' ]
8+ const VERSION_DISPLAY_HEADERS = [ 'Package Name' , 'package.json Version' , 'Latest Version' , 'Description' ]
159
1610class Renderer {
1711 constructor ( { logger } ) {
@@ -63,7 +57,7 @@ class Renderer {
6357 if ( data . quality . deprecated ) style = style . red
6458 const dataSet = [
6559 `${ style ( data . name || '' ) } ` ,
66- `${ style ( data . recommendedVersion || 'No Insight' ) } ` ,
60+ `${ style ( data . version || 'No Insight' ) } ` ,
6761 `${ style ( this . trimStringToLength ( data . license , 4 ) || '' ) } ` ,
6862 `${ style ( this . trimStringToLength ( data . description , 20 ) || '' ) } `
6963 ]
@@ -81,7 +75,6 @@ class Renderer {
8175 return [
8276 `${ style ( data . name || '' ) } ` ,
8377 `${ style ( data . pkgJsonVersion || '' ) } ` ,
84- `${ style ( data . recommendedVersion || 'No Insight' ) } ` ,
8578 `${ style ( data . version ) } ` ,
8679 `${ style ( this . trimStringToLength ( data . description , 20 ) || '' ) } `
8780 ]
@@ -179,14 +172,14 @@ class Renderer {
179172 let packages = [ pkgSet . source . name ]
180173 if ( pkgSet . alternatives && pkgSet . alternatives . length > 0 ) {
181174 packages = packages . concat ( pkgSet . alternatives . map ( alt => alt . name ) )
182- this . queue . push ( chalk `{blue.bold https://platform .datree.io/pkg/alternative-packages/${ packages . join ( ',' ) } }` )
175+ this . queue . push ( chalk `{blue.bold https://app .datree.io/pkg/alternative-packages/${ packages . join ( ',' ) } }` )
183176 }
184177 }
185178
186179 _renderSinglePackageLinks ( packageList ) {
187180 for ( const pkg of packageList )
188181 if ( pkg && pkg . source && pkg . source . quality && pkg . source . quality . deprecated )
189- this . queue . push ( chalk `{blue.bold https://platform .datree.io/pkg/single-package/${ pkg . source . name } }` )
182+ this . queue . push ( chalk `{blue.bold https://app .datree.io/pkg/single-package/${ pkg . source . name } }` )
190183 }
191184}
192185
0 commit comments