1
1
// Copyright 2024 the JSR authors. MIT license.
2
2
import * as path from "node:path" ;
3
3
import * as fs from "node:fs" ;
4
- import { styleText } from ' ./utils'
4
+ import { styleText } from " ./utils" ;
5
5
import {
6
6
exec ,
7
7
fileExists ,
@@ -26,7 +26,7 @@ async function wrapWithStatus(msg: string, fn: () => Promise<void>) {
26
26
27
27
try {
28
28
await fn ( ) ;
29
- process . stdout . write ( styleText ( "green" , "ok" ) + "\n" ) ;
29
+ process . stdout . write ( styleText ( "green" , "ok" ) + "\n" ) ;
30
30
} catch ( err ) {
31
31
process . stdout . write ( styleText ( "red" , "error" ) + "\n" ) ;
32
32
throw err ;
@@ -235,16 +235,17 @@ export async function showPackageInfo(raw: string) {
235
235
236
236
console . log ( ) ;
237
237
console . log (
238
- styleText ( "cyan" , `@${ pkg . scope } /${ pkg . name } @${ pkg . version } `
239
- ) +
238
+ styleText ( "cyan" , `@${ pkg . scope } /${ pkg . name } @${ pkg . version } ` ) +
240
239
` | latest: ${ styleText ( "magenta" , meta . latest ?? "-" ) } | versions: ${
241
240
styleText ( "magenta" , versionCount . toString ( ) )
242
241
} `,
243
242
) ;
244
243
console . log ( npmInfo . description ) ;
245
244
console . log ( ) ;
246
245
console . log ( `npm tarball: ${ styleText ( "cyan" , versionInfo . dist . tarball ) } ` ) ;
247
- console . log ( `npm integrity: ${ styleText ( "cyan" , versionInfo . dist . integrity ) } ` ) ;
246
+ console . log (
247
+ `npm integrity: ${ styleText ( "cyan" , versionInfo . dist . integrity ) } ` ,
248
+ ) ;
248
249
console . log ( ) ;
249
250
console . log (
250
251
`published: ${ styleText ( "magenta" , timeAgo ( Date . now ( ) - publishTime ) ) } ` ,
0 commit comments