@salesforce/core 3.30.0 → 3.30.2
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/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [3.30.2](https://github.com/forcedotcom/sfdx-core/compare/v3.30.1...v3.30.2) (2022-09-16)
|
|
6
|
+
|
|
7
|
+
### Bug Fixes
|
|
8
|
+
|
|
9
|
+
- **logger:** support `SF_*` env vars ([#637](https://github.com/forcedotcom/sfdx-core/issues/637)) ([53c4296](https://github.com/forcedotcom/sfdx-core/commit/53c4296d0ab0728a798e39626a29168371e1a062))
|
|
10
|
+
|
|
11
|
+
### [3.30.1](https://github.com/forcedotcom/sfdx-core/compare/v3.30.0...v3.30.1) (2022-09-15)
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
- await postOrgCreate hook ([#636](https://github.com/forcedotcom/sfdx-core/issues/636)) ([b9934d2](https://github.com/forcedotcom/sfdx-core/commit/b9934d2df6f5ea49b4f8bae44779aa5cab0e897f))
|
|
16
|
+
|
|
5
17
|
## [3.30.0](https://github.com/forcedotcom/sfdx-core/compare/v3.26.3...v3.30.0) (2022-09-12)
|
|
6
18
|
|
|
7
19
|
### [3.26.3](https://github.com/forcedotcom/sfdx-core/compare/v3.26.2...v3.26.3) (2022-09-06)
|
package/lib/config/envVars.d.ts
CHANGED
|
@@ -25,6 +25,7 @@ export declare enum EnvironmentVariable {
|
|
|
25
25
|
'SFDX_IMPROVED_CODE_COVERAGE' = "SFDX_IMPROVED_CODE_COVERAGE",
|
|
26
26
|
'SFDX_INSTANCE_URL' = "SFDX_INSTANCE_URL",
|
|
27
27
|
'SFDX_JSON_TO_STDOUT' = "SFDX_JSON_TO_STDOUT",
|
|
28
|
+
'SFDX_DISABLE_LOG_FILE' = "SFDX_DISABLE_LOG_FILE",
|
|
28
29
|
'SFDX_LOG_LEVEL' = "SFDX_LOG_LEVEL",
|
|
29
30
|
'SFDX_LOG_ROTATION_COUNT' = "SFDX_LOG_ROTATION_COUNT",
|
|
30
31
|
'SFDX_LOG_ROTATION_PERIOD' = "SFDX_LOG_ROTATION_PERIOD",
|
|
@@ -59,6 +60,7 @@ export declare enum EnvironmentVariable {
|
|
|
59
60
|
'SF_IMPROVED_CODE_COVERAGE' = "SF_IMPROVED_CODE_COVERAGE",
|
|
60
61
|
'SF_ORG_INSTANCE_URL' = "SF_ORG_INSTANCE_URL",
|
|
61
62
|
'SF_JSON_TO_STDOUT' = "SF_JSON_TO_STDOUT",
|
|
63
|
+
'SF_DISABLE_LOG_FILE' = "SF_DISABLE_LOG_FILE",
|
|
62
64
|
'SF_LOG_LEVEL' = "SF_LOG_LEVEL",
|
|
63
65
|
'SF_LOG_ROTATION_COUNT' = "SF_LOG_ROTATION_COUNT",
|
|
64
66
|
'SF_LOG_ROTATION_PERIOD' = "SF_LOG_ROTATION_PERIOD",
|
package/lib/config/envVars.js
CHANGED
|
@@ -39,6 +39,7 @@ var EnvironmentVariable;
|
|
|
39
39
|
EnvironmentVariable["SFDX_IMPROVED_CODE_COVERAGE"] = "SFDX_IMPROVED_CODE_COVERAGE";
|
|
40
40
|
EnvironmentVariable["SFDX_INSTANCE_URL"] = "SFDX_INSTANCE_URL";
|
|
41
41
|
EnvironmentVariable["SFDX_JSON_TO_STDOUT"] = "SFDX_JSON_TO_STDOUT";
|
|
42
|
+
EnvironmentVariable["SFDX_DISABLE_LOG_FILE"] = "SFDX_DISABLE_LOG_FILE";
|
|
42
43
|
EnvironmentVariable["SFDX_LOG_LEVEL"] = "SFDX_LOG_LEVEL";
|
|
43
44
|
EnvironmentVariable["SFDX_LOG_ROTATION_COUNT"] = "SFDX_LOG_ROTATION_COUNT";
|
|
44
45
|
EnvironmentVariable["SFDX_LOG_ROTATION_PERIOD"] = "SFDX_LOG_ROTATION_PERIOD";
|
|
@@ -73,6 +74,7 @@ var EnvironmentVariable;
|
|
|
73
74
|
EnvironmentVariable["SF_IMPROVED_CODE_COVERAGE"] = "SF_IMPROVED_CODE_COVERAGE";
|
|
74
75
|
EnvironmentVariable["SF_ORG_INSTANCE_URL"] = "SF_ORG_INSTANCE_URL";
|
|
75
76
|
EnvironmentVariable["SF_JSON_TO_STDOUT"] = "SF_JSON_TO_STDOUT";
|
|
77
|
+
EnvironmentVariable["SF_DISABLE_LOG_FILE"] = "SF_DISABLE_LOG_FILE";
|
|
76
78
|
EnvironmentVariable["SF_LOG_LEVEL"] = "SF_LOG_LEVEL";
|
|
77
79
|
EnvironmentVariable["SF_LOG_ROTATION_COUNT"] = "SF_LOG_ROTATION_COUNT";
|
|
78
80
|
EnvironmentVariable["SF_LOG_ROTATION_PERIOD"] = "SF_LOG_ROTATION_PERIOD";
|
|
@@ -186,6 +188,10 @@ exports.SUPPORTED_ENV_VARS = {
|
|
|
186
188
|
description: getMessage(EnvironmentVariable.SFDX_JSON_TO_STDOUT),
|
|
187
189
|
synonymOf: EnvironmentVariable.SF_JSON_TO_STDOUT,
|
|
188
190
|
},
|
|
191
|
+
[EnvironmentVariable.SFDX_DISABLE_LOG_FILE]: {
|
|
192
|
+
description: getMessage(EnvironmentVariable.SFDX_DISABLE_LOG_FILE),
|
|
193
|
+
synonymOf: EnvironmentVariable.SF_DISABLE_LOG_FILE,
|
|
194
|
+
},
|
|
189
195
|
[EnvironmentVariable.SFDX_LOG_LEVEL]: {
|
|
190
196
|
description: getMessage(EnvironmentVariable.SFDX_LOG_LEVEL),
|
|
191
197
|
synonymOf: EnvironmentVariable.SF_LOG_LEVEL,
|
|
@@ -323,6 +329,10 @@ exports.SUPPORTED_ENV_VARS = {
|
|
|
323
329
|
description: getMessage(EnvironmentVariable.SF_JSON_TO_STDOUT),
|
|
324
330
|
synonymOf: null,
|
|
325
331
|
},
|
|
332
|
+
[EnvironmentVariable.SF_DISABLE_LOG_FILE]: {
|
|
333
|
+
description: getMessage(EnvironmentVariable.SF_DISABLE_LOG_FILE),
|
|
334
|
+
synonymOf: EnvironmentVariable.SFDX_DISABLE_LOG_FILE,
|
|
335
|
+
},
|
|
326
336
|
[EnvironmentVariable.SF_LOG_LEVEL]: {
|
|
327
337
|
description: getMessage(EnvironmentVariable.SF_LOG_LEVEL),
|
|
328
338
|
synonymOf: null,
|
package/lib/logger.js
CHANGED
|
@@ -155,7 +155,8 @@ class Logger {
|
|
|
155
155
|
}
|
|
156
156
|
const rootLogger = (this.rootLogger = new Logger(Logger.ROOT_NAME).setLevel());
|
|
157
157
|
// disable log file writing, if applicable
|
|
158
|
-
|
|
158
|
+
const disableLogFile = new kit_1.Env().getString('SF_DISABLE_LOG_FILE');
|
|
159
|
+
if (disableLogFile !== 'true' && global_1.Global.getEnvironmentMode() !== global_1.Mode.TEST) {
|
|
159
160
|
await rootLogger.addLogFileStream(global_1.Global.LOG_FILE_PATH);
|
|
160
161
|
}
|
|
161
162
|
rootLogger.enableDEBUG();
|
|
@@ -353,7 +354,8 @@ class Logger {
|
|
|
353
354
|
*/
|
|
354
355
|
setLevel(level) {
|
|
355
356
|
if (level == null) {
|
|
356
|
-
|
|
357
|
+
const logLevelFromEnvVar = new kit_1.Env().getString('SF_LOG_LEVEL');
|
|
358
|
+
level = logLevelFromEnvVar ? Logger.getLevelByName(logLevelFromEnvVar) : Logger.DEFAULT_LEVEL;
|
|
357
359
|
}
|
|
358
360
|
this.bunyan.level(level);
|
|
359
361
|
return this;
|
|
@@ -39,7 +39,7 @@ const isHookField = (key) => {
|
|
|
39
39
|
return postOrgCreateHookFields.includes(key);
|
|
40
40
|
};
|
|
41
41
|
const emitPostOrgCreate = async (authFields) => {
|
|
42
|
-
emitter.emit('postorgcreate', Object.fromEntries(Object.entries(authFields).filter(([key]) => isHookField(key))));
|
|
42
|
+
await emitter.emit('postorgcreate', Object.fromEntries(Object.entries(authFields).filter(([key]) => isHookField(key))));
|
|
43
43
|
};
|
|
44
44
|
exports.emitPostOrgCreate = emitPostOrgCreate;
|
|
45
45
|
//# sourceMappingURL=scratchOrgLifecycleEvents.js.map
|
|
@@ -11,7 +11,7 @@ const sfdcUrl_1 = require("./sfdcUrl");
|
|
|
11
11
|
async function getJwtAudienceUrl(options) {
|
|
12
12
|
if (options.loginUrl) {
|
|
13
13
|
const url = new sfdcUrl_1.SfdcUrl(options.loginUrl);
|
|
14
|
-
return
|
|
14
|
+
return url.getJwtAudienceUrl(options.createdOrgInstance);
|
|
15
15
|
}
|
|
16
16
|
return sfdcUrl_1.SfdcUrl.PRODUCTION;
|
|
17
17
|
}
|
package/messages/envVars.md
CHANGED
|
@@ -90,6 +90,10 @@ URL of the Salesforce instance that is hosting your org. Default value is https:
|
|
|
90
90
|
|
|
91
91
|
Set to true to send messages resulting from failed Salesforce CLI commands to stdout instead of stderr.
|
|
92
92
|
|
|
93
|
+
# sfdxDisableLogFile
|
|
94
|
+
|
|
95
|
+
Set to true to disable log file writing
|
|
96
|
+
|
|
93
97
|
# sfdxLogLevel
|
|
94
98
|
|
|
95
99
|
Level of messages that the CLI writes to the log file. Valid values are trace, debug, info, warn, error, fatal. Default value is warn.
|
|
@@ -226,6 +230,10 @@ URL of the Salesforce instance that is hosting your org. Default value is https:
|
|
|
226
230
|
|
|
227
231
|
Set to true to send messages resulting from failed Salesforce CLI commands to stdout instead of stderr.
|
|
228
232
|
|
|
233
|
+
# sfDisableLogFile
|
|
234
|
+
|
|
235
|
+
Set to true to disable log file writing
|
|
236
|
+
|
|
229
237
|
# sfLogLevel
|
|
230
238
|
|
|
231
239
|
Level of messages that the CLI writes to the log file. Valid values are trace, debug, info, warn, error, fatal. Default value is warn.
|