Skip to content

Commit

Permalink
[eas-cli] improve eas env:pull logging
Browse files Browse the repository at this point in the history
  • Loading branch information
szdziedzic committed Nov 22, 2024
1 parent bd2d39f commit 6caa62c
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions packages/eas-cli/src/commands/env/pull.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export default class EnvPull extends EasCommand {
return `${variable.name}=${currentEnvLocal[variable.name]}`;
}
skippedSecretVariables.push(variable.name);
return `# ${variable.name}=***** (secret variables are not available for reading)`;
return `# ${variable.name}=***** (secret)`;
}
if (variable.type === EnvironmentSecretType.FileBase64 && variable.valueWithFileContent) {
const filePath = path.join(envDir, variable.name);
Expand All @@ -130,20 +130,20 @@ export default class EnvPull extends EasCommand {
await fs.writeFile(targetPath, filePrefix + envFileContentLines.join('\n'));

Log.log(
`Pulled environment variables from ${environment.toLowerCase()} environment to ${targetPath}.`
`Pulled plain text and sensitive environment variables from "${environment.toLowerCase()}" environment to ${targetPath}.`
);

if (overridenSecretVariables.length > 0) {
Log.addNewLineIfNone();
Log.log(`Reused local values for following secrets: ${overridenSecretVariables.join('\n')}`);
Log.log(`Reused local values for following secrets: ${overridenSecretVariables.join('\n')}.`);
}

if (skippedSecretVariables.length > 0) {
Log.addNewLineIfNone();
Log.warn(
`The following variables have the secret visibility and can not be read outside of EAS servers. Set their values manually in .env.local: ${skippedSecretVariables.join(
'\n'
)}`
Log.log(
`The following variables have the secret visibility and can't be read outside of EAS servers. Set their values manually in your .env file: ${skippedSecretVariables.join(
', '
)}.`
);
}
}
Expand Down

0 comments on commit 6caa62c

Please sign in to comment.