File tree 1 file changed +3
-1
lines changed
1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ import {splitPatternAndLineNumbers} from './line-numbers.js';
21
21
import { loadConfig } from './load-config.js' ;
22
22
import normalizeModuleTypes from './module-types.js' ;
23
23
import normalizeNodeArguments from './node-arguments.js' ;
24
+ import pkg from './pkg.cjs' ;
24
25
import providerManager from './provider-manager.js' ;
25
26
import DefaultReporter from './reporters/default.js' ;
26
27
import TapReporter from './reporters/tap.js' ;
@@ -102,7 +103,7 @@ export default async function loadCli() { // eslint-disable-line complexity
102
103
let conf ;
103
104
let confError ;
104
105
try {
105
- const { argv : { config : configFile } } = yargs ( hideBin ( process . argv ) ) . help ( false ) ;
106
+ const { argv : { config : configFile } } = yargs ( hideBin ( process . argv ) ) . help ( false ) . version ( false ) ;
106
107
conf = await loadConfig ( { configFile} ) ;
107
108
if ( conf . configFile && path . basename ( conf . configFile ) !== path . relative ( conf . projectDir , conf . configFile ) ) {
108
109
console . log ( chalk . magenta ( ` ${ figures . warning } Using configuration from ${ conf . configFile } ` ) ) ;
@@ -132,6 +133,7 @@ export default async function loadCli() { // eslint-disable-line complexity
132
133
133
134
let resetCache = false ;
134
135
const { argv} = yargs ( hideBin ( process . argv ) )
136
+ . version ( pkg . version )
135
137
. parserConfiguration ( {
136
138
'boolean-negation' : true ,
137
139
'camel-case-expansion' : false ,
You can’t perform that action at this time.
0 commit comments