envpkt 0.6.3 → 0.6.4

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.
Files changed (2) hide show
  1. package/dist/cli.js +9 -5
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -3055,13 +3055,17 @@ const runSeal = async (options) => {
3055
3055
  console.log("");
3056
3056
  const values = await (async () => {
3057
3057
  if (options.reseal && alreadySealed.length > 0) {
3058
- const identityPath = config.identity?.key_file ? resolve(configDir, expandPath(config.identity.key_file)) : void 0;
3058
+ const identityPath = config.identity?.key_file ? resolve(configDir, expandPath(config.identity.key_file)) : (() => {
3059
+ const defaultPath = resolveKeyPath();
3060
+ return existsSync(defaultPath) ? defaultPath : void 0;
3061
+ })();
3059
3062
  if (!identityPath) {
3060
- console.error(`${RED}Error:${RESET} identity.key_file is required for --reseal (needed to decrypt existing secrets)`);
3063
+ console.error(`${RED}Error:${RESET} No identity key found for --reseal (needed to decrypt existing secrets)`);
3061
3064
  console.error("");
3062
- console.error(`${DIM}Add to your envpkt.toml:${RESET}`);
3063
- console.error(`${DIM} [identity]${RESET}`);
3064
- console.error(`${DIM} key_file = "path/to/identity.txt"${RESET}`);
3065
+ console.error(`${DIM}Looked in:${RESET}`);
3066
+ console.error(`${DIM} 1. identity.key_file in envpkt.toml${RESET}`);
3067
+ console.error(`${DIM} 2. ENVPKT_AGE_KEY_FILE env var${RESET}`);
3068
+ console.error(`${DIM} 3. ~/.envpkt/age-key.txt${RESET}`);
3065
3069
  process.exit(2);
3066
3070
  }
3067
3071
  const decrypted = unsealSecrets(Object.fromEntries(alreadySealed.map((k) => [k, allSecretEntries[k]])), identityPath).fold((err) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "envpkt",
3
- "version": "0.6.3",
3
+ "version": "0.6.4",
4
4
  "description": "Credential lifecycle and fleet management for AI agents",
5
5
  "keywords": [
6
6
  "credentials",