wrapt-cli 0.1.5 → 0.1.6

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/README.md CHANGED
@@ -68,6 +68,7 @@ npx wrapt-cli render --name "Ada" --theme pastel
68
68
  |---|---|
69
69
  | `--name "Ada"` | Your first name on the cover. Without it, the cover says “Your 2026”. |
70
70
  | `--theme bold\|mono\|pastel` | Color theme. Default: `bold`. |
71
+ | `--no-credit` | Leave out the line crediting wrapt's creator, Mayank Agarwal, with his LinkedIn (`in/whomayankagarwal`) and Instagram (`@whomayankagarwal`) handles. By default it is on the last card. |
71
72
  | `--show-projects` | Put your real project names on the cards. By default they show as “Project A”, “Project B”. |
72
73
  | `--year 2025` | Make the cards for another year. Add it to each command. Default: this year. |
73
74
  | `--source claude\|copilot` | Only read one tool's history. Default: every supported tool found. |
package/dist/cli.js CHANGED
@@ -26,7 +26,7 @@ Run it with npx: npx wrapt-cli <command> (or install it: npm i -g wrapt-cli, t
26
26
 
27
27
  Usage
28
28
  wrapt analyze [--year 2026] [--source all|claude|copilot] [--json] [--samples] [--projects-dir <dir>]
29
- wrapt render [--year 2026] [--name "Ada"] [--show-projects] [--theme bold|mono|pastel] [--out <dir>]
29
+ wrapt render [--year 2026] [--name "Ada"] [--show-projects] [--theme bold|mono|pastel] [--no-credit] [--out <dir>]
30
30
  wrapt schema [--validate <narrative.json>]
31
31
  wrapt share [--year 2026] [--minutes 15] [--port <n>]
32
32
  wrapt airdrop [--year 2026] [--set story|carousel|all]
@@ -56,6 +56,8 @@ Options
56
56
  --samples analyze: also save samples.json, prompt excerpts for the /wrapt skill. Off by default.
57
57
  --name Name for the cover (default: "Your 2026 with Claude")
58
58
  --show-projects Put your real project names on the cards (default: "Project A/B/C")
59
+ --no-credit Leave out the line crediting wrapt's creator (LinkedIn and Instagram handles)
60
+ on the last card. It is shown by default.
59
61
  --theme Colour theme: ${Object.keys(THEMES).join(", ")} (default: bold)
60
62
  -h, --help Show help
61
63
  `;
@@ -76,6 +78,9 @@ async function main(argv) {
76
78
  // Older flag: project names are hidden by default now, so this is a no-op kept for scripts.
77
79
  "hide-projects": { type: "boolean", default: false },
78
80
  theme: { type: "string" },
81
+ // The creator credit is on by default; --no-credit turns it off. --credit is accepted for scripts.
82
+ credit: { type: "boolean", default: true },
83
+ "no-credit": { type: "boolean", default: false },
79
84
  validate: { type: "string" },
80
85
  minutes: { type: "string" },
81
86
  set: { type: "string" },
@@ -143,7 +148,7 @@ async function main(argv) {
143
148
  process.stderr.write(`Ignoring invalid narrative.json:\n${parsed.error.message}\n`);
144
149
  }
145
150
  const t0 = Date.now();
146
- const res = await renderAll({ stats, narrative, name: values.name, hideProjects: values["hide-projects"] || !values["show-projects"], theme: values.theme, outDir: dir, infoDir: dataDir });
151
+ const res = await renderAll({ stats, narrative, name: values.name, hideProjects: values["hide-projects"] || !values["show-projects"], theme: values.theme, credit: !values["no-credit"], outDir: dir, infoDir: dataDir });
147
152
  // Every card of a set in one file, for downloading or sending in one go.
148
153
  const zipNames = [];
149
154
  for (const [set, buf] of Object.entries(cardZips(dir, year, collectAssets(dir)))) {
@@ -1,6 +1,6 @@
1
1
  import { brandFor } from "../brand.js";
2
2
  import { displayTool, human } from "../format.js";
3
- import { SITE, SITE_URL, qrSvgDataUri } from "../site.js";
3
+ import { CREATOR, SITE, SITE_URL, qrSvgDataUri } from "../site.js";
4
4
  import { h } from "./h.js";
5
5
  import { textWidthEm } from "./measure.js";
6
6
  export const SIZES = {
@@ -385,6 +385,24 @@ export function outroStats(ctx) {
385
385
  lang ? { value: lang, label: "top language" } : { value: human(t.sessions), label: "sessions" },
386
386
  ];
387
387
  }
388
+ /** "wrapt by Mayank Agarwal" and the LinkedIn and Instagram handles, unless `render --no-credit`. One line when `inline`, else two. */
389
+ function CreditLine(props) {
390
+ if (!props.ctx.credit)
391
+ return null;
392
+ const s = props.size;
393
+ const sep = h("span", { style: { opacity: 0.45, marginLeft: 0.4 * s, marginRight: 0.4 * s } }, "\u00B7");
394
+ const by = (h("div", { style: { display: "flex" } },
395
+ h("span", { style: { opacity: 0.7, marginRight: 0.3 * s } }, "wrapt by"),
396
+ h("span", { style: { fontWeight: 700 } }, CREATOR.name)));
397
+ const handles = (h("div", { style: { display: "flex", opacity: 0.85, marginTop: props.inline ? 0 : 0.3 * s } },
398
+ h("span", null, `LinkedIn ${CREATOR.linkedin}`),
399
+ sep,
400
+ h("span", null, `Instagram ${CREATOR.instagram}`)));
401
+ return (h("div", { style: { display: "flex", flexDirection: props.inline ? "row" : "column", fontSize: s, fontWeight: 500, marginTop: props.marginTop } },
402
+ by,
403
+ props.inline ? sep : null,
404
+ handles));
405
+ }
388
406
  function Outro(ctx) {
389
407
  const d = dims(ctx.size);
390
408
  const { u } = d;
@@ -428,7 +446,8 @@ function Outro(ctx) {
428
446
  h("span", { style: { fontSize: 120 * u, fontWeight: 700, lineHeight: 1, letterSpacing: -4 * u, color: ctx.palette.accent } }, String(ctx.stats.year)),
429
447
  h("span", { style: { fontSize: fitFont(`with ${brand.long}`, 380 * u, 40 * u), fontWeight: 700, lineHeight: 1, marginBottom: 28 * u } }, `with ${brand.long}`),
430
448
  cta),
431
- grid)));
449
+ grid),
450
+ h(CreditLine, { ctx: ctx, size: 20 * u, marginTop: 28 * u, inline: true })));
432
451
  }
433
452
  return (h(Frame, { ctx: ctx, kicker: "That\u2019s a wrap" },
434
453
  h("span", { style: {
@@ -440,7 +459,8 @@ function Outro(ctx) {
440
459
  marginBottom: 44 * u,
441
460
  } }, title),
442
461
  grid,
443
- h("div", { style: { display: "flex", marginTop: 48 * u } }, cta)));
462
+ h("div", { style: { display: "flex", marginTop: 48 * u } }, cta),
463
+ h(CreditLine, { ctx: ctx, size: (d.tall ? 23 : 26) * u, marginTop: (d.tall ? 40 : 24) * u })));
444
464
  }
445
465
  export const CARDS = [Cover, BigNumber, Rhythm, TopAsks, WordOfYear, Stack, Archetype, Outro];
446
466
  export const CARD_NAMES = ["cover", "big-number", "rhythm", "top-asks", "word", "stack", "archetype", "outro"];
@@ -34,6 +34,7 @@ export async function renderAll(opts) {
34
34
  narrative: opts.narrative,
35
35
  name: opts.name,
36
36
  hideProjects: opts.hideProjects ?? true,
37
+ credit: opts.credit ?? true,
37
38
  total: CARDS.length,
38
39
  };
39
40
  const ctxFor = (size, i) => ({ ...base, size, palette: palettes[i], index: i + 1 });
@@ -54,7 +55,7 @@ export async function renderAll(opts) {
54
55
  fs.writeFileSync(out.xCard, await toPng(Outro(ctxFor(SIZES.x, CARDS.length - 1)), SIZES.x));
55
56
  fs.writeFileSync(out.pdf, await carouselPdf(carouselPngs, opts.stats.year, brandFor(opts.stats).long));
56
57
  // Remember how the cards were made, so `wrapt publish` can warn before project names go public.
57
- fs.writeFileSync(path.join(opts.infoDir ?? opts.outDir, "render.json"), JSON.stringify({ name: opts.name ?? null, hideProjects: opts.hideProjects ?? true, theme: opts.theme ?? "bold", renderedAt: new Date().toISOString() }, null, 2) + "\n", { mode: 0o600 });
58
+ fs.writeFileSync(path.join(opts.infoDir ?? opts.outDir, "render.json"), JSON.stringify({ name: opts.name ?? null, hideProjects: opts.hideProjects ?? true, credit: opts.credit ?? true, theme: opts.theme ?? "bold", renderedAt: new Date().toISOString() }, null, 2) + "\n", { mode: 0o600 });
58
59
  fs.chmodSync(path.join(opts.infoDir ?? opts.outDir, "render.json"), 0o600); // also when the file already existed
59
60
  return out;
60
61
  }
package/dist/site.js CHANGED
@@ -2,6 +2,12 @@ import { createRequire } from "node:module";
2
2
  /** Where people go to make their own wrapt. Shown on the cards and in share captions. */
3
3
  export const SITE = "wrapt.cc";
4
4
  export const SITE_URL = `https://${SITE}`;
5
+ /** wrapt's creator, credited on the last card unless the user passes `render --no-credit`. */
6
+ export const CREATOR = {
7
+ name: "Mayank Agarwal",
8
+ linkedin: "in/whomayankagarwal",
9
+ instagram: "@whomayankagarwal",
10
+ };
5
11
  const require = createRequire(import.meta.url);
6
12
  // qrcode-terminal ships a plain QR encoder; reuse it rather than adding another dependency.
7
13
  const QRCode = require("qrcode-terminal/vendor/QRCode/index.js");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wrapt-cli",
3
- "version": "0.1.5",
3
+ "version": "0.1.6",
4
4
  "description": "Your year with Claude Code and GitHub Copilot, wrapped. Share cards made on your own computer.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -41,6 +41,12 @@
41
41
  "./package.json": "./package.json"
42
42
  },
43
43
  "homepage": "https://wrapt.cc",
44
+ "repository": {
45
+ "type": "git",
46
+ "url": "git+https://github.com/m-scudder/wrapt.git",
47
+ "directory": "packages/cli"
48
+ },
49
+ "bugs": "https://github.com/m-scudder/wrapt/issues",
44
50
  "keywords": [
45
51
  "claude",
46
52
  "claude-code",