@@ -144,16 +144,6 @@ function provisionOptions(y: Argv) {
144144 'include-merged-configuration' : { type : 'boolean' , default : false , description : 'Include merged configuration in result.' } ,
145145 } )
146146 . check ( argv => {
147- const idLabels = ( argv [ 'id-label' ] && ( Array . isArray ( argv [ 'id-label' ] ) ? argv [ 'id-label' ] : [ argv [ 'id-label' ] ] ) ) as string [ ] | undefined ;
148- if ( idLabels ?. some ( idLabel => ! / .+ = .+ / . test ( idLabel ) ) ) {
149- throw new Error ( 'Unmatched argument format: id-label must match <name>=<value>' ) ;
150- }
151- if ( ! ( argv [ 'workspace-folder' ] || argv [ 'id-label' ] ) ) {
152- throw new Error ( 'Missing required argument: workspace-folder or id-label' ) ;
153- }
154- if ( ! ( argv [ 'workspace-folder' ] || argv [ 'override-config' ] ) ) {
155- throw new Error ( 'Missing required argument: workspace-folder or override-config' ) ;
156- }
157147 const mounts = ( argv . mount && ( Array . isArray ( argv . mount ) ? argv . mount : [ argv . mount ] ) ) as string [ ] | undefined ;
158148 if ( mounts ?. some ( mount => ! mountRegex . test ( mount ) ) ) {
159149 throw new Error ( 'Unmatched argument format: mount must match type=<bind|volume>,source=<source>,target=<target>[,external=<true|false>]' ) ;
@@ -218,7 +208,7 @@ async function provision({
218208 'include-merged-configuration' : includeMergedConfig ,
219209} : ProvisionArgs ) {
220210
221- const workspaceFolder = workspaceFolderArg ? path . resolve ( process . cwd ( ) , workspaceFolderArg ) : undefined ;
211+ const workspaceFolder = path . resolve ( process . cwd ( ) , workspaceFolderArg ?? '.' ) ;
222212 const addRemoteEnvs = addRemoteEnv ? ( Array . isArray ( addRemoteEnv ) ? addRemoteEnv as string [ ] : [ addRemoteEnv ] ) : [ ] ;
223213 const addCacheFroms = addCacheFrom ? ( Array . isArray ( addCacheFrom ) ? addCacheFrom as string [ ] : [ addCacheFrom ] ) : [ ] ;
224214 const additionalFeatures = additionalFeaturesJson ? jsonc . parse ( additionalFeaturesJson ) as Record < string , string | boolean | Record < string , string | boolean > > : { } ;
0 commit comments