Update checked-in dependencies
This commit is contained in:
parent
4fad06f438
commit
40a500c743
4168 changed files with 298222 additions and 374905 deletions
26
node_modules/execa/index.js
generated
vendored
26
node_modules/execa/index.js
generated
vendored
|
|
@ -232,25 +232,39 @@ export function execaSync(file, args, options) {
|
|||
};
|
||||
}
|
||||
|
||||
const normalizeScriptStdin = ({input, inputFile, stdio}) => input === undefined && inputFile === undefined && stdio === undefined
|
||||
? {stdin: 'inherit'}
|
||||
: {};
|
||||
|
||||
const normalizeScriptOptions = (options = {}) => ({
|
||||
preferLocal: true,
|
||||
...normalizeScriptStdin(options),
|
||||
...options,
|
||||
});
|
||||
|
||||
function create$(options) {
|
||||
function $(templatesOrOptions, ...expressions) {
|
||||
if (Array.isArray(templatesOrOptions)) {
|
||||
const [file, ...args] = parseTemplates(templatesOrOptions, expressions);
|
||||
return execa(file, args, options);
|
||||
if (!Array.isArray(templatesOrOptions)) {
|
||||
return create$({...options, ...templatesOrOptions});
|
||||
}
|
||||
|
||||
return create$({...options, ...templatesOrOptions});
|
||||
const [file, ...args] = parseTemplates(templatesOrOptions, expressions);
|
||||
return execa(file, args, normalizeScriptOptions(options));
|
||||
}
|
||||
|
||||
$.sync = (templates, ...expressions) => {
|
||||
if (!Array.isArray(templates)) {
|
||||
throw new TypeError('Please use $(options).sync`command` instead of $.sync(options)`command`.');
|
||||
}
|
||||
|
||||
const [file, ...args] = parseTemplates(templates, expressions);
|
||||
return execaSync(file, args, options);
|
||||
return execaSync(file, args, normalizeScriptOptions(options));
|
||||
};
|
||||
|
||||
return $;
|
||||
}
|
||||
|
||||
export const $ = create$({preferLocal: true});
|
||||
export const $ = create$();
|
||||
|
||||
export function execaCommand(command, options) {
|
||||
const [file, ...args] = parseCommand(command);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue