replicas-cli 0.3.439 → 0.3.441

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/index.cjs +26 -7
  2. package/package.json +1 -1
package/dist/index.cjs CHANGED
@@ -22609,7 +22609,7 @@ function designColors({ mode, palette, accent, custom: custom2 }) {
22609
22609
  const colors = { ...DESIGN_COLORS[mode], ...paletteColors, ...accent === "custom" ? customAccent(custom2.accent, paletteColors) : ACCENT_COLORS[accent][mode] };
22610
22610
  return resolved === "custom" ? { ...colors, ...Object.fromEntries(READABLE_TEXT_KEYS.map((key) => [key, readableText(colors[key], paletteColors)])) } : colors;
22611
22611
  }
22612
- var plain, THEME_PREFERENCES, PALETTE_PRESETS, PALETTES, PALETTE_COLORS, ACCENT_PRESETS, ACCENTS, ACCENT_COLORS, dark, DESIGN_COLORS, SERIES, BRAND_COLORS, channels, mix, luminance, contrast, customMode, themeCode, DEFAULT_APPEARANCE, resolvePalette, READABLE_TEXT_KEYS;
22612
+ var plain, THEME_PREFERENCES, PALETTE_PRESETS, PALETTES, PALETTE_COLORS, ACCENT_PRESETS, ACCENTS, ACCENT_COLORS, dark, DESIGN_COLORS, SERIES, BRAND_COLORS, channels, mix, luminance, contrast, customMode, themeCode, DEFAULT_THEME, resolvePalette, READABLE_TEXT_KEYS;
22613
22613
  var init_design_tokens = __esm({
22614
22614
  "../shared/src/design-tokens.ts"() {
22615
22615
  "use strict";
@@ -22737,7 +22737,7 @@ var init_design_tokens = __esm({
22737
22737
  };
22738
22738
  customMode = ({ background, foreground }) => luminance(background) < luminance(foreground) ? "dark" : "light";
22739
22739
  themeCode = ({ background, foreground, accent }) => [background, foreground, accent].join(",");
22740
- DEFAULT_APPEARANCE = {
22740
+ DEFAULT_THEME = {
22741
22741
  palette: "default",
22742
22742
  accent: "green",
22743
22743
  custom: { background: PALETTE_COLORS.dark.default.background, foreground: PALETTE_COLORS.dark.default.foreground, accent: "#888888" }
@@ -25709,7 +25709,8 @@ Use this when:
25709
25709
  - The user asks you to manage environments, environment variables, or environment files
25710
25710
  - The user asks "what envs / repos / automations do I have?"
25711
25711
  - The user asks you to scaffold a \`replicas.json\` / \`replicas.yaml\` in a repo
25712
- - You need to run a long-lived service (dev server, daemon) \u2014 always use \`replicas service start\` so it survives workspace sleep/wake`;
25712
+ - You need to run a long-lived service (dev server, daemon) \u2014 always use \`replicas service start\` so it survives workspace sleep/wake
25713
+ - The user asks you to change how their Replicas app looks (theme, colors, accent) \u2014 use \`replicas theme set\` (see *Themes*)`;
25713
25714
  REFERENCE12 = `# Replicas (in-workspace CLI)
25714
25715
 
25715
25716
  This guide covers how to take action *with* Replicas itself from inside a Replicas workspace \u2014 managing automations, environments (and their variables/files), repos, previews, and the user's \`replicas.json\` config \u2014 using the pre-installed \`replicas\` CLI.
@@ -25757,6 +25758,7 @@ In agent mode the CLI hides commands that don't make sense for in-workspace agen
25757
25758
  | \`replicas skills suggest <SKILL.md> --title <text>\` | Suggest saving a lasting user instruction as a learning (an organization skill); the user accepts or dismisses it |
25758
25759
  | \`replicas skills suggest --delete <name-or-id>\` | When the user asks you to delete a learning, suggest removing it; the user accepts or dismisses it |
25759
25760
  | \`replicas slack thread ...\` | Attach or switch Slack thread routing (covered in \`SLACK.md\`) |
25761
+ | \`replicas theme get\` / \`replicas theme set ...\` | Show or change the web and desktop app theme of the person who wrote in this workspace (see *Themes*) |
25760
25762
 
25761
25763
  \`replicas <command> --help\` is always the source of truth for flags.
25762
25764
 
@@ -25780,6 +25782,7 @@ In agent mode the CLI hides commands that don't make sense for in-workspace agen
25780
25782
  | "Ignore Dependabot for this PR automation" | \`replicas automation edit <id> --trigger-github-exclude-users 'dependabot[bot]'\` |
25781
25783
  | "Also run this PR automation on every push" | \`replicas automation edit <id> --keep-triggers --trigger-github pull_request.synchronize --trigger-github-repos acme/web\` |
25782
25784
  | "What repos are connected?" | \`replicas repos\` |
25785
+ | "Make my Replicas dark / purple / match these colors" | \`replicas theme set ...\` (see *Themes*) |
25783
25786
  | "Set up a \`replicas.json\` in this repo" | \`replicas init\` (\`-y\` for YAML) |
25784
25787
 
25785
25788
  ## Environments
@@ -25979,6 +25982,23 @@ Notes:
25979
25982
  - Logs stream to \`~/.replicas/services/<name>.log\`.
25980
25983
  - After starting, verify the service is actually healthy (check \`logs\`, then \`curl\` its port) before telling the user it's up or creating a preview for it.
25981
25984
 
25985
+ ## Themes
25986
+
25987
+ When the user asks you to change how their Replicas app looks, change it for them. It is saved to their account, so their open web and desktop apps repaint on their own, on every computer. The phone app has its own setting and does not follow it.
25988
+
25989
+ \`\`\`bash
25990
+ replicas theme get
25991
+ replicas theme set --theme light
25992
+ replicas theme set --theme dark --color-theme slate
25993
+ replicas theme set --accent purple
25994
+ replicas theme set --accent ff5500
25995
+ replicas theme set --code 0d1117,e6ecf4,ff5500
25996
+ \`\`\`
25997
+
25998
+ A color theme always goes with \`--theme light\` or \`--theme dark\`. An accent is a preset name or any hex color. A theme code is three hex colors: background, text, accent. Write hex colors without the \`#\`, which the shell reads as a comment. \`replicas theme set --help\` lists the names. For a look the presets don't cover, choose the three colors yourself and pass them as \`--code\`; the text has to read clearly on the background, or it is refused.
25999
+
26000
+ It changes the theme of the one person who has written in this workspace, and prints their email. You cannot pick someone else. When several people have written here, or nobody has yet (a workspace started by an automation, another agent, the API or the CLI, until its person sends a message in it), it refuses: tell them they can change their own under **Themes** in the account menu. A workspace created before this command existed answers \`unknown command\`: say the same.
26001
+
25982
26002
  ## Repositories
25983
26003
 
25984
26004
  Read-only listing of repos connected to the org. Use when the user asks "what repos can I use?", or to validate a \`--repository\` value before passing it to \`environment create\` / \`automation create\`:
@@ -26238,8 +26258,8 @@ curl -sS --fail-with-body -X POST "\${REPLICAS_MONOLITH_URL:-$MONOLITH_URL}/v1/e
26238
26258
  });
26239
26259
 
26240
26260
  // ../shared/src/visuals.ts
26241
- function visualTheme(mode, fontUrl, appearance = DEFAULT_APPEARANCE) {
26242
- const colors = designColors({ ...appearance, mode });
26261
+ function visualTheme(mode, fontUrl, theme = DEFAULT_THEME) {
26262
+ const colors = designColors({ ...theme, mode });
26243
26263
  return {
26244
26264
  appearance: mode,
26245
26265
  variables: {
@@ -26616,7 +26636,6 @@ var init_replicas_agent = __esm({
26616
26636
  "../shared/src/default-skills/replicas-agent/index.ts"() {
26617
26637
  "use strict";
26618
26638
  init_registry();
26619
- init_replicas();
26620
26639
  init_registry();
26621
26640
  }
26622
26641
  });
@@ -38650,7 +38669,7 @@ var CLI_VERSION;
38650
38669
  var init_cli_version = __esm({
38651
38670
  "../shared/src/cli-version.ts"() {
38652
38671
  "use strict";
38653
- CLI_VERSION = "0.3.439";
38672
+ CLI_VERSION = "0.3.441";
38654
38673
  }
38655
38674
  });
38656
38675
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "replicas-cli",
3
- "version": "0.3.439",
3
+ "version": "0.3.441",
4
4
  "description": "CLI for managing Replicas workspaces - SSH into cloud dev environments with automatic port forwarding",
5
5
  "main": "dist/index.cjs",
6
6
  "bin": {