@netlify/config 23.0.6 → 23.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/main.js
CHANGED
|
@@ -104,7 +104,6 @@ export const resolveConfig = async function (opts) {
|
|
|
104
104
|
const configA = addLegacyFunctionsDirectory(config);
|
|
105
105
|
const updatedIntegrations = await handleAutoInstallExtensions({
|
|
106
106
|
featureFlags,
|
|
107
|
-
accounts,
|
|
108
107
|
integrations,
|
|
109
108
|
siteId,
|
|
110
109
|
accountId,
|
|
@@ -6,12 +6,11 @@ interface AutoInstallOptions {
|
|
|
6
6
|
accountId: string;
|
|
7
7
|
token: string;
|
|
8
8
|
cwd: string;
|
|
9
|
-
accounts: any;
|
|
10
9
|
integrations: IntegrationResponse[];
|
|
11
10
|
offline: boolean;
|
|
12
11
|
testOpts: any;
|
|
13
12
|
mode: ModeOption;
|
|
14
13
|
extensionApiBaseUrl: string;
|
|
15
14
|
}
|
|
16
|
-
export declare function handleAutoInstallExtensions({ featureFlags, siteId, accountId, token, cwd,
|
|
15
|
+
export declare function handleAutoInstallExtensions({ featureFlags, siteId, accountId, token, cwd, integrations, offline, testOpts, mode, extensionApiBaseUrl, }: AutoInstallOptions): Promise<IntegrationResponse[]>;
|
|
17
16
|
export {};
|
|
@@ -6,7 +6,7 @@ function getPackageJSON(directory) {
|
|
|
6
6
|
const require = createRequire(join(directory, 'package.json'));
|
|
7
7
|
return require('./package.json');
|
|
8
8
|
}
|
|
9
|
-
export async function handleAutoInstallExtensions({ featureFlags, siteId, accountId, token, cwd,
|
|
9
|
+
export async function handleAutoInstallExtensions({ featureFlags, siteId, accountId, token, cwd, integrations, offline, testOpts = {}, mode, extensionApiBaseUrl, }) {
|
|
10
10
|
if (!featureFlags?.auto_install_required_extensions) {
|
|
11
11
|
return integrations;
|
|
12
12
|
}
|
|
@@ -61,17 +61,6 @@ export async function handleAutoInstallExtensions({ featureFlags, siteId, accoun
|
|
|
61
61
|
return integrations;
|
|
62
62
|
}
|
|
63
63
|
try {
|
|
64
|
-
const account = accounts?.find((account) => account.id === accountId);
|
|
65
|
-
if (!account) {
|
|
66
|
-
console.error(`Failed to auto install extension(s): Couldn't find 'account' with id '${accountId}'`, {
|
|
67
|
-
accountId,
|
|
68
|
-
siteId,
|
|
69
|
-
cwd,
|
|
70
|
-
offline,
|
|
71
|
-
mode,
|
|
72
|
-
});
|
|
73
|
-
return integrations;
|
|
74
|
-
}
|
|
75
64
|
const packageJson = getPackageJSON(cwd);
|
|
76
65
|
if (!packageJson?.dependencies ||
|
|
77
66
|
typeof packageJson?.dependencies !== 'object' ||
|
|
@@ -86,7 +75,7 @@ export async function handleAutoInstallExtensions({ featureFlags, siteId, accoun
|
|
|
86
75
|
return integrations;
|
|
87
76
|
}
|
|
88
77
|
const results = await Promise.all(extensionsToInstall.map(async (ext) => {
|
|
89
|
-
console.log(`Installing extension "${ext.slug}" on team "${
|
|
78
|
+
console.log(`Installing extension "${ext.slug}" on team "${accountId}" required by package(s): "${ext.packages.join('",')}"`);
|
|
90
79
|
return installExtension({
|
|
91
80
|
accountId,
|
|
92
81
|
netlifyToken: token,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@netlify/config",
|
|
3
|
-
"version": "23.0.
|
|
3
|
+
"version": "23.0.8",
|
|
4
4
|
"description": "Netlify config module",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": "./lib/index.js",
|
|
@@ -59,9 +59,9 @@
|
|
|
59
59
|
"license": "MIT",
|
|
60
60
|
"dependencies": {
|
|
61
61
|
"@iarna/toml": "^2.2.5",
|
|
62
|
-
"@netlify/api": "^14.0.
|
|
63
|
-
"@netlify/headers-parser": "^9.0.
|
|
64
|
-
"@netlify/redirect-parser": "^15.0.
|
|
62
|
+
"@netlify/api": "^14.0.3",
|
|
63
|
+
"@netlify/headers-parser": "^9.0.1",
|
|
64
|
+
"@netlify/redirect-parser": "^15.0.2",
|
|
65
65
|
"chalk": "^5.0.0",
|
|
66
66
|
"cron-parser": "^4.1.0",
|
|
67
67
|
"deepmerge": "^4.2.2",
|
|
@@ -79,11 +79,11 @@
|
|
|
79
79
|
"p-locate": "^6.0.0",
|
|
80
80
|
"path-type": "^6.0.0",
|
|
81
81
|
"tomlify-j0.4": "^3.0.0",
|
|
82
|
-
"validate-npm-package-name": "^
|
|
82
|
+
"validate-npm-package-name": "^5.0.0",
|
|
83
83
|
"yargs": "^17.6.0"
|
|
84
84
|
},
|
|
85
85
|
"devDependencies": {
|
|
86
|
-
"@types/node": "^
|
|
86
|
+
"@types/node": "^18.0.0",
|
|
87
87
|
"ava": "^5.0.0",
|
|
88
88
|
"c8": "^10.0.0",
|
|
89
89
|
"has-ansi": "^6.0.0",
|
|
@@ -94,5 +94,5 @@
|
|
|
94
94
|
"engines": {
|
|
95
95
|
"node": ">=18.14.0"
|
|
96
96
|
},
|
|
97
|
-
"gitHead": "
|
|
97
|
+
"gitHead": "df148594017a78f0f419591da402311ed08e4d64"
|
|
98
98
|
}
|