keypin 0.0.0 → 0.1.0

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.
@@ -1,10 +1,9 @@
1
1
  // @bun
2
2
  import {
3
- __require,
3
+ messageOf,
4
4
  errorCode,
5
- installProblem,
6
- messageOf
7
- } from "./chunk-9dz90rbw.js";
5
+ installProblem
6
+ } from "./chunk-8agfxsqt.js";
8
7
 
9
8
  // src/start.ts
10
9
  import { homedir as homedir2 } from "os";
@@ -1083,14 +1082,14 @@ function onePasswordBackend(connect = desktopConnect) {
1083
1082
  const id = await vaultId(sdk, ref);
1084
1083
  const found = await find(sdk, id, ref);
1085
1084
  if (!found) {
1086
- const fields2 = [passwordField(secret)];
1085
+ const fields = [passwordField(secret)];
1087
1086
  if (rotated)
1088
- fields2.push(rotatedField(rotated));
1087
+ fields.push(rotatedField(rotated));
1089
1088
  await sdk.items.create({
1090
1089
  category: "Password",
1091
1090
  vaultId: id,
1092
1091
  title: ref.item,
1093
- fields: fields2
1092
+ fields
1094
1093
  });
1095
1094
  return;
1096
1095
  }
@@ -1282,12 +1281,12 @@ import { parseArgs as parseArgs2 } from "util";
1282
1281
  function announce(stderr, what, refs) {
1283
1282
  const groups = new Map;
1284
1283
  for (const ref of refs) {
1285
- const where2 = `1Password account ${ref.account}, vault "${ref.vault}"`;
1286
- groups.set(where2, (groups.get(where2) ?? new Set).add(ref.item));
1284
+ const where = `1Password account ${ref.account}, vault "${ref.vault}"`;
1285
+ groups.set(where, (groups.get(where) ?? new Set).add(ref.item));
1287
1286
  }
1288
- for (const [where2, items] of groups) {
1287
+ for (const [where, items] of groups) {
1289
1288
  const names = [...items].map((item) => `"${item}"`).join(", ");
1290
- stderr.write(`keypin: reading ${what} from ${where2}: ${names}
1289
+ stderr.write(`keypin: reading ${what} from ${where}: ${names}
1291
1290
  `);
1292
1291
  }
1293
1292
  }
@@ -1604,7 +1603,7 @@ async function status(args, deps) {
1604
1603
  `);
1605
1604
  }
1606
1605
  }
1607
- const refs = distinctRefs([...maps.values()].flatMap((result2) => result2.ok ? result2.map.keys.flatMap((key) => Object.values(key.environments).map((e) => e.ref)) : []));
1606
+ const refs = distinctRefs([...maps.values()].flatMap((result) => result.ok ? result.map.keys.flatMap((key) => Object.values(key.environments).map((e) => e.ref)) : []));
1608
1607
  const metadata = new Map;
1609
1608
  if (refs.length) {
1610
1609
  announce(deps.stderr, "rotation fields (no values)", refs);
@@ -1723,7 +1722,7 @@ async function unregister2(args, deps) {
1723
1722
  return 0;
1724
1723
  }
1725
1724
  // ../../package.json
1726
- var version = "0.0.0";
1725
+ var version = "0.1.0";
1727
1726
 
1728
1727
  // src/cli.ts
1729
1728
  var USAGE = `Usage:
@@ -1,6 +1,4 @@
1
1
  // @bun
2
- var __require = import.meta.require;
3
-
4
2
  // src/install.ts
5
3
  import { fileURLToPath } from "url";
6
4
 
@@ -30,4 +28,4 @@ function installProblem(error, repo = checkout()) {
30
28
  return `${name ? `the package ${name}` : "a package"} isn't installed; ${fix}`;
31
29
  }
32
30
 
33
- export { __require, messageOf, errorCode, installProblem };
31
+ export { messageOf, errorCode, installProblem };
package/main.js CHANGED
@@ -1,9 +1,8 @@
1
1
  #!/usr/bin/env bun
2
2
  // @bun
3
3
  import {
4
- __require,
5
4
  installProblem
6
- } from "./chunk-9dz90rbw.js";
5
+ } from "./chunk-8agfxsqt.js";
7
6
 
8
7
  // src/runtime.ts
9
8
  var MIN_BUN = "1.4.4";
@@ -37,7 +36,7 @@ if (problem) {
37
36
  }
38
37
  var start;
39
38
  try {
40
- start = await import("./chunk-a195bqr7.js");
39
+ start = await import("./chunk-03233dfg.js");
41
40
  } catch (error) {
42
41
  const hint = installProblem(error);
43
42
  if (!hint)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "keypin",
3
- "version": "0.0.0",
3
+ "version": "0.1.0",
4
4
  "description": "A map of every app key across your projects, published to the account it's pinned to. Values stay in your vault.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://github.com/caiopizzol/keypin#readme",