From e8107f562293892bc6f6ac8a527cb836cf43ecd9 Mon Sep 17 00:00:00 2001 From: Vadym Samoilenko Date: Fri, 17 Apr 2026 13:12:42 +0100 Subject: [PATCH] vault backup: 2026-04-17 13:12:42 --- 99 Daily/2026-04-17.md | 6 ++ .../Securely deploying AI agents.md | 0 .../Sessions - Wez's Terminal Emulator.md | 0 wiki/_master-index.md | 4 +- wiki/agent-sdk/_index.md | 1 + wiki/dotfiles/_index.md | 1 + wiki/dotfiles/wezterm-workspaces.md | 74 +++++++++++++++++++ 7 files changed, 84 insertions(+), 2 deletions(-) rename raw/{ => _processed}/Securely deploying AI agents.md (100%) rename raw/{ => _processed}/Sessions - Wez's Terminal Emulator.md (100%) create mode 100644 wiki/dotfiles/wezterm-workspaces.md diff --git a/99 Daily/2026-04-17.md b/99 Daily/2026-04-17.md index 358b8d1..a083a56 100644 --- a/99 Daily/2026-04-17.md +++ b/99 Daily/2026-04-17.md @@ -263,3 +263,9 @@ tags: [daily] - 13:10 (<1min) | `Barclays-banner-builder` - **Asked:** Analyzed folder data and created app concept with Docker/Ubuntu deployment plan avoiding WebSockets | Designed architecture for Docker containerization with Apache reverse proxy and load balancer SSL termination | Architecture document - **Done:** Created idempotent deployment script with Docker build, database initialization, and Alembic migrations | Built bash script for automated container deployment with caching and migration handling | deploy.sh, docker-compose.yml +- 13:11 | `memory-compiler` + - **Asked:** Compiled new wiki article on agent SDK secure deployment | Created structured article with threat model, features, isolation technologies, and credential management guidance | wiki/agent-sdk/secure-deployment.md, wiki/agent-sdk/_index.md, Knowledge Base — Master Index + - **Done:** Agent SDK secure deployment | Threat model, isolation technologies, credential management, filesystem sections | secure-deployment.md, _index.md +- 13:12 (<1min) | `memory-compiler` + - **Asked:** Compile a new article about WezTerm workspaces into the wiki knowledge base. + - **Done:** Created structured wiki article and updated master index with new dotfiles entry. diff --git a/raw/Securely deploying AI agents.md b/raw/_processed/Securely deploying AI agents.md similarity index 100% rename from raw/Securely deploying AI agents.md rename to raw/_processed/Securely deploying AI agents.md diff --git a/raw/Sessions - Wez's Terminal Emulator.md b/raw/_processed/Sessions - Wez's Terminal Emulator.md similarity index 100% rename from raw/Sessions - Wez's Terminal Emulator.md rename to raw/_processed/Sessions - Wez's Terminal Emulator.md diff --git a/wiki/_master-index.md b/wiki/_master-index.md index c147c42..0991df7 100644 --- a/wiki/_master-index.md +++ b/wiki/_master-index.md @@ -28,9 +28,9 @@ This 3-hop pattern works for hundreds of articles without vector search. | [[wiki/qa/_index\|qa/]] | Filed answers to queries (saved with `--file-back`) | 0 | | [[wiki/homelab/_index\|homelab/]] | Self-hosted infra: Proxmox install, IOMMU/PCI passthrough, hypervisor setup, budget builds | 2 | | [[wiki/web-agency/_index\|web-agency/]] | AI-assisted website building & selling: Claude Code, Nanobanana 2, Kling, LaunchPath MCP | 1 | -| [[wiki/dotfiles/_index\|dotfiles/]] | Linux terminal ricing: Kitty, Fish, WezTerm CLI, modern Rust CLI tools, LazyVim, unified themes, Tabby | 18 | +| [[wiki/dotfiles/_index\|dotfiles/]] | Linux terminal ricing: Kitty, Fish, WezTerm CLI, modern Rust CLI tools, LazyVim, unified themes, Tabby | 19 | -| [[wiki/agent-sdk/_index\|agent-sdk/]] | Claude Agent SDK (formerly Claude Code SDK) — build autonomous AI agents in Python and TypeScript | 20 | +| [[wiki/agent-sdk/_index\|agent-sdk/]] | Claude Agent SDK (formerly Claude Code SDK) — build autonomous AI agents in Python and TypeScript | 21 | | [[wiki/llm-models/_index\|llm-models/]] | OpenAI model catalog — GPT-5.x, o-series reasoning, audio/realtime, embeddings, moderation | 1 | | [[wiki/claude-code/_index\|claude-code/]] | Claude Code product docs — install, capabilities, surfaces, MCP, hooks, scheduling, multi-agent, plugins, skills, channels, error recovery | 11 | diff --git a/wiki/agent-sdk/_index.md b/wiki/agent-sdk/_index.md index 063a05b..775fb37 100644 --- a/wiki/agent-sdk/_index.md +++ b/wiki/agent-sdk/_index.md @@ -34,3 +34,4 @@ Build production AI agents using the same tools, agent loop, and context managem | [[wiki/agent-sdk/quickstart\|quickstart]] | Minimal working agent: query(), allowed_tools, permission modes, message stream types, troubleshooting | raw/Quickstart.md | 2026-04-17 | | [[wiki/agent-sdk/file-checkpointing\|file-checkpointing]] | Track file changes per turn, rewind files to any checkpoint UUID; patterns, limitations, troubleshooting | raw/Rewind file changes with checkpointing.md | 2026-04-17 | | [[wiki/agent-sdk/tool-search\|tool-search]] | Scale to 10,000 tools via dynamic discovery; ENABLE_TOOL_SEARCH config, auto:N threshold, naming tips | raw/Scale to many tools with tool search.md | 2026-04-17 | +| [[wiki/agent-sdk/secure-deployment\|secure-deployment]] | Threat model, built-in security, isolation technologies (sandbox/Docker/gVisor/VM), proxy credential pattern, filesystem controls | raw/Securely deploying AI agents.md | 2026-04-17 | diff --git a/wiki/dotfiles/_index.md b/wiki/dotfiles/_index.md index 93df157..31cffdb 100644 --- a/wiki/dotfiles/_index.md +++ b/wiki/dotfiles/_index.md @@ -22,3 +22,4 @@ Linux terminal customization, shell configs, CLI tool setups, and ricing guides. | [[wiki/dotfiles/wezterm-mouse-bindings\|wezterm-mouse-bindings]] | Mouse binding config: default assignments, custom bindings, wheel events, Up/Down event gotcha | wezterm.org/config/mouse.html | 2026-04-17 | | [[wiki/dotfiles/wezterm-pane-to-lua\|wezterm-pane-to-lua]] | Passing data from pane to Lua: User Vars (OSC 1337), OSC 7 CWD, title OSC, local process APIs | wezterm.org/recipes/passing-data.html | 2026-04-17 | | [[wiki/dotfiles/wezterm-plugins\|wezterm-plugins]] | Plugin system: install via HTTPS/file URL, update_all(), remove, develop, fork existing plugins | wezterm.org/config/plugins.html | 2026-04-17 | +| [[wiki/dotfiles/wezterm-workspaces\|wezterm-workspaces]] | Workspaces (sessions): named MuxWindow groups, switching key assignments, gui-startup pre-built layouts | wezterm.org/recipes/workspaces.html | 2026-04-17 | diff --git a/wiki/dotfiles/wezterm-workspaces.md b/wiki/dotfiles/wezterm-workspaces.md new file mode 100644 index 0000000..55dd406 --- /dev/null +++ b/wiki/dotfiles/wezterm-workspaces.md @@ -0,0 +1,74 @@ +--- +title: "WezTerm Workspaces (Sessions)" +aliases: [wezterm-sessions, wezterm-workspaces] +tags: [wezterm, terminal, workspaces, sessions, tmux] +sources: [raw/Sessions - Wez's Terminal Emulator.md] +created: 2026-04-17 +updated: 2026-04-17 +--- + +## What Are Workspaces? + +Workspaces are WezTerm's equivalent of **tmux sessions** — named groups of windows (MuxWindows) that can be switched between without closing anything. + +- Every `MuxWindow` carries a **workspace label** +- The GUI renders only the windows in the **active workspace** +- Switching workspaces swaps all visible GUI windows simultaneously +- Windows in other workspaces are hidden but still running + +## Switching Workspaces + +| Key Assignment | Action | +|---|---| +| `SwitchToWorkspace` | Jump to a named workspace | +| `SwitchWorkspaceRelative` | Cycle forward/backward through workspaces | +| `ShowLauncher` / `ShowLauncherArgs` | Interactive list of all workspaces to pick from | + +Any spawn command (new window, new tab) can also accept a `workspace` argument to open into a non-active workspace immediately. + +## Pre-defining Layouts at Startup + +Use startup events to build a workspace layout automatically when WezTerm launches: + +- **`gui-startup`** — fires when the GUI starts; use `mux.spawn_window { workspace = "name" }` to create named workspaces with pre-arranged tabs/panes +- **`mux-startup`** — fires for the multiplexer daemon; useful for headless / server setups + +```lua +-- Example: gui-startup pre-built workspaces +local mux = wezterm.mux +wezterm.on("gui-startup", function() + local _, _, window = mux.spawn_window { workspace = "work" } + window:gui_window():set_right_status("work") + + mux.spawn_window { workspace = "personal" } + mux.set_active_workspace("work") +end) +``` + +## Comparison with tmux Sessions + +| Concept | tmux | WezTerm | +|---|---|---| +| Session | `tmux new-session -s name` | Workspace label | +| Switch session | `tmux switch-client -t name` | `SwitchToWorkspace` | +| List sessions | `tmux ls` | `ShowLauncher` | +| Pre-define layout | `.tmux.conf` + scripting | `gui-startup` event | + +## Key Takeaways + +- Workspaces are **labels on MuxWindows** — no separate process or socket like tmux sessions +- The GUI shows **only the active workspace**; background workspaces are hidden but alive +- Use `ShowLauncher` as the interactive workspace picker (bind it to a convenient key) +- Pre-built layouts go in the **`gui-startup`** event handler in `wezterm.lua` +- Any spawn call can target a non-active workspace by name — useful for background task windows + +## Related + +- [[wiki/dotfiles/wezterm-config|WezTerm Config]] — Lua config structure and file locations +- [[wiki/dotfiles/wezterm-key-bindings|WezTerm Key Bindings]] — how to bind SwitchToWorkspace +- [[wiki/dotfiles/wezterm-key-tables|WezTerm Key Tables]] — modal layers for workspace switching +- [[wiki/dotfiles/wezterm-launching-programs|WezTerm Launching Programs]] — spawn options and CWD + +## Sources + +- [wezterm.org/recipes/workspaces.html](https://wezterm.org/recipes/workspaces.html)