File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import consola from 'consola' ;
22import spawn from 'nano-spawn' ;
33import { resolve } from 'node:path' ;
4+ import { version } from '../../../packages/wxt/package.json' ;
45
56const cliDir = resolve ( 'packages/wxt/src/cli/commands' ) ;
67const cliDirGlob = resolve ( cliDir , '**' ) ;
@@ -44,12 +45,12 @@ async function getHelp(command: string): Promise<string> {
4445 return result . stdout ;
4546}
4647
47- function getWxtHelp ( command : string ) : Promise < string > {
48- return getHelp ( `bun run --silent wxt ${ command } ` . trim ( ) ) ;
48+ async function getWxtHelp ( command : string ) : Promise < string > {
49+ const res = await getHelp ( `bun run --silent wxt ${ command } ` . trim ( ) ) ;
50+ return res . replaceAll ( '{{version}}' , version ) ;
4951}
5052
5153async function getPublishExtensionHelp ( command : string ) : Promise < string > {
52- // console.error('\n\n\n', await fs.readdir('.'));
5354 const res = await getHelp (
5455 `bun run --silent publish-extension ${ command } ` . trim ( ) ,
5556 ) ;
You can’t perform that action at this time.
0 commit comments