Function
getCLIOptions
({
apiUrl,
builder,
env = {},
extendEnv = true,
}: {
apiUrl?: string
builder?: { directory?: string } | undefined
cwd?: string
env?: CommonOptions<string>['env']
extendEnv?: CommonOptions<string>['extendEnv']
})
Source from the content-addressed store, hash-verified
| 187 | * @returns {import('execa').Options<string>} |
| 188 | */ |
| 189 | export const getCLIOptions = ({ |
| 190 | apiUrl, |
| 191 | builder, |
| 192 | env = {}, |
| 193 | extendEnv = true, |
| 194 | }: { |
| 195 | apiUrl?: string |
| 196 | builder?: { directory?: string } | undefined |
| 197 | cwd?: string |
| 198 | env?: CommonOptions<string>['env'] |
| 199 | extendEnv?: CommonOptions<string>['extendEnv'] |
| 200 | }): NodeOptions => ({ |
| 201 | cwd: builder?.directory, |
| 202 | env: { ...getEnvironmentVariables({ apiUrl }), ...env }, |
| 203 | extendEnv, |
| 204 | }) |