| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| |
|
|
|
| |
They've moved from ~/src/tmp to ~/tmp/src, which /claude/tmp/ excludes
already.
|
| |
|
|
|
|
|
| |
Commands, Words, Options, and the list's columns, each command and
option on a line of its own, its description indented below it, the
headings in bold on a terminal; and an unknown option is a one-line
error now, not all of that.
|
| |
|
|
|
|
| |
--push and --show without BRANCH (the graph) take the repository the
current directory is in, when they get no REPO: by DIR as given, or
else physically (cd -P), so symlinks don't matter, without git.
|
| |
|
|
|
|
|
| |
A BRANCH without REPO is looked for in every repository in DIR, and
is_repo ran git remote get-url for each, which adds up with hundreds
(~0.4s for 300); [remote "claude"] in .git/config does it without git,
but where .git isn't a directory.
|
| |
|
|
|
|
|
| |
On a terminal, as completion has them: commands (and COMMAND),
options (and OPTION), REPO, BRANCH, and in an error, the repository and
branch it's about; truecolor, 256 or 8 colors, as the terminal has
them, and none with NO_COLOR, on a dumb terminal, or into a pipe.
|
| |
|
|
|
|
|
|
| |
When master isn't checked out anywhere, take does without a working
tree: it fast-forwards master by fetching into it (which takes
fast-forwards only), and take --force makes the new master a branch,
not a checkout. --pick still needs master checked out, and master
checked out in another worktree is refused.
|
| |
|
|
|
|
|
| |
Per branch, it ran cherry, rev-list, rev-parse (seen) and log (age);
now one for-each-ref per repository has tips, ages and what's been
seen, so it's cherry and rev-list per branch, and the repositories go
in parallel.
|
| |
|
|
|
|
|
|
| |
Running git twice per repository (remote get-url, for-each-ref) on
every TAB adds up, with many repositories; so read [remote "claude"]
from .git/config, and claude's branches from packed-refs and the loose
refs, and run git only where .git isn't a plain directory (a
worktree's), or the refs aren't files (reftable).
|
| |
|
|
|
|
|
|
|
|
| |
Readline prints escapes in candidates as ^[, so on a second TAB (just
listing, COMP_TYPE ?), the completion prints the list itself, in
columns like readline's, each kind in a color of its own, truecolor,
256 or 8 colors, as the terminal has them, and gives readline a single
blank candidate, to list instead, so that readline redraws the prompt
(one blank line, the price). With NO_COLOR, or a dumb terminal,
readline lists them, as before.
|
| |
|
|
|
|
| |
The commands, the options, REPOs, BRANCHes, in that order (complete -o
nosort, where bash has it, i.e. since 4.4), as bash can't color them;
and a name that's both a REPO and a BRANCH only once.
|
| |
|
|
|
|
| |
Without a command, it offers the commands, but none of their options;
with one, its options, and no other command; and no option that's there
already, nor --pick with -f, --force, or the other way round.
|
| |
|
|
|
|
|
|
|
|
|
| |
Commands are options now (--list, --show, --take, --push), in one set
with the others, without overlaps, so only REPO and BRANCH are words,
and each word is what exists: a repository in DIR, or a branch of
claude's in one, the one reading of all words that does, or an error.
Without REPO, BRANCH is in the one repository that has it; without a
command, it's --show if there's a BRANCH, else --list. --show fetches
first (REPO, or else all), --take doesn't: it takes what was shown.
An option that isn't for the command is an error, not ignored.
|
| |
|
|
|
| |
What's checked out is what one compares with, most likely, rather
than a local branch of the same name, which may well not be there.
|
| |
|
|
|
|
|
| |
take and push push master to claude's master, always, and by name,
which needs no upstream; but @{u} does (git log @{u}.., say), and
master has none after take --force when the old one had none. So
give it claude's then, but keep any it has already.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
rsync filter rules for /home/ of a guest with configs/claude.nix: a
blacklist of scratch (the remotes' tmp, never backed up, and src/tmp,
for repositories not worth a backup, like third parties', symlinked
from src), the claude.ai login (a secret; claude auth login again after
a restore), and what's rebuildable, transient, or synced again from the
account (caches, the crates cargo fetched, Claude Code's sessions,
snapshots, plugins). What remains: the repositories (uncommitted files,
branches only there), the remotes' directories, transcripts, memory,
links to claude.ai sessions, uploads, trust and settings, and the
remotes started with claude-remote. With how to use it, and how to
restore.
|
| |
|
|
|
|
|
|
| |
The commits of BRANCH that master doesn't have yet (git cherry's +, so
rebased ones master has are left out) get cherry-picked onto master,
which is then pushed, like take. On a conflict, it stops there, on
master: resolve, git cherry-pick --continue, then push; or --abort.
Until then, push refuses: master has only some of the picks.
|
| |
|
|
|
|
|
| |
A second take --force within the same second found its
abandoned/master-DATE taken already, and stopped (with git's error,
before changing anything). Now it adds -2, -3, ... to the name, as
long as that's taken.
|
| |
|
|
|
|
|
|
|
|
|
| |
The repository comes first now, then the command: claude-inbox REPO
show [BRANCH [--diff[=WHAT]]], REPO take [-f] BRANCH, REPO push [-f],
and REPO [list], which lists just REPO's branches (fetching only it).
Without REPO, list is all of them, as before. list and help are
commands there, anything else a REPO; after --, the next word is a REPO
in any case (a repository named list, say). The old order gets told
the new one. The command's own options (-f, --diff) still go anywhere
after it; the completion knows all of that.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For each repository the VM has (ssh claude: ~/src, but for symlinks,
i.e. third parties' in src/tmp), claude-inbox fetches its checkout here
(in $CLAUDE_INBOX_SRC, default ~/sync/src) from the remote claude, and
lists the branches there with something master doesn't have, compared
by content (git cherry), so rebased ones count as merged: with their
owner (the remote, by the branch's prefix, checked against the VM's
~/remotes, or tv, without one), what to do (review: it's new, on top of
master; rebase: master moved on, the remote's turn; done: master has
it all, to delete; yours: tv's own), what changed since show or take
(*), and whether master needs pushing (or, unexpectedly, the VM's has
something master doesn't). --by-remote groups by owner. show REPO
BRANCH shows master..BRANCH, with patches, show REPO BRANCH --diff=WHAT
the diff to it from WHAT (any branch or commit; by default, the local
branch of its name without the remote's prefix: B, for REMOTE/B), and
show REPO all branches, as a graph; take REPO BRANCH fast-forwards master
to it and pushes master to claude, or with -f (before or after the
arguments) renames master to abandoned/master-DATE, checks out BRANCH
as master (with the old one's upstream), and pushes that like push -f;
push REPO pushes master (with -f, a rewritten one, as long as claude's
is still the one last fetched: --force-with-lease). With bash
completion. A package for the host, of the claude facet's tools (the
name may still change, as it might serve hermes, too).
|
| |
|
|
|
|
|
|
| |
cargo, clippy, rustc and rustfmt from the host's nixpkgs, for every user
(so in the remotes' PATH), and what crates' build scripts commonly need:
nixpkgs' wrapped cc and pkg-config, and OpenSSL, with pkg-config finding
the system's .pc files through PKG_CONFIG_PATH. Meant to go below the
layers that change more often, as its image is big and changes rarely.
|
| |
|
|
|
|
|
|
| |
hermes.env (the API key, and the Webapp's sign-in) came from /xchg,
which every VM started in the same directory sees. Now it's a secret
(fc.secrets."hermes.env", /run/secrets/hermes.env), which the run
script requires: --secret hermes.env=FILE. (The module still copies it
into ~/.hermes/.env, onto the home drive.)
|
| |
|
|
|
|
|
| |
The remotes' PATH had only the packages of the service's path, so
fc-egress, claude-remote, and anything else installed system-wide
weren't there. Now /run/current-system/sw comes after them. claude's
own packages stay the service's (packages, that is, not that string).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
claude-remote list (the default) shows the remotes, static, dynamic,
with a unit loaded, or with a directory, with their kind, state, and
whether they trust their directory yet; inspect NAME shows a remote's
unit, directory, trust, claude.ai session (bridge-pointer.json), and
the last lines of its terminal; start, stop and restart NAME go through
systemctl (a remote started here is dynamic: it lasts until stopped
here), and start points to attach while the remote doesn't trust its
directory; attach [NAME] opens its terminal (it's claude-attach, which
is gone); log NAME shows its journal. Which remotes are static, it
asks systemd (multi-user.target's wants), so changing them doesn't
change it. A package (pkgs/claude-remote.nix), with bash completion of
the commands and the remotes' names.
|
| |
|
|
|
|
| |
Remote Control names the sessions it creates after the host, by
default, which all remotes share. Now it names them after the remote
(CLAUDE_REMOTE_CONTROL_SESSION_NAME_PREFIX), NAME-...
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
A remote started with systemctl start claude-remote-control@NAME, rather
than by multi-user.target's wants, now lasts until systemctl stop, across
reboots: while it's meant to run, it has a file of its name in
/home/.var/lib/claude/remote-control (the claude facet's part of what
would be in /var/lib, which is on the tmpfs, on the home drive; root's),
written when it starts (as root: ExecStartPre=+), and removed when it
stops, but not by a failure (it restarts) nor by a shutdown
(ExecStopPost=+, by SERVICE_RESULT and systemctl is-system-running). At
boot, claude-remote-control-restore starts them again, but for those
that are static by then, whose files it removes instead; static ones
never get one.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
A Remote Control server per directory meant a context per directory of
repositories, so two couldn't work on the same ones. Now
claude-remote-control@NAME is a remote, a context of its own: it works
in ~/remotes/NAME, its project for Claude Code (sessions, memory,
trust), created if need be; and every remote works on the repositories
in ~/src, an additional directory for all of them, by the machine's
managed settings (/etc/claude-code/managed-settings.json, which also
means for any claude here, and that nobody's own settings take it
away). The default remote is main (it was @src), and claude-attach's
default with it.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
claude-remote-control is a template now, claude-remote-control@DIR, one
per directory in ~claude, created if need be (but not ~ itself, nor
anything above it, nor a dot file): @src is the one there was, and
another layer can add more to multi-user.target's wants. Each runs in a
tmux of its own, /run/claude/DIR/tmux, in a runtime directory of its
own: a second tmux new-session in the same server would exit without a
process for systemd to follow (Type=forking), and stopping a unit
removes its runtime directory. claude-attach takes the DIR (default:
src).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Hermes copies its bundled (and optional) skills out of the store into
~/.hermes/skills with shutil.copytree, which keeps the store's modes,
so the copies were read-only, files and directories: skill_manage
couldn't patch a bundled skill, nor write its temporary files next to
it. Patch the three places that copy a skill (seeding, updating,
restoring) to make the copy writable for its owner afterwards, and
copy the categories' DESCRIPTION.md without its mode.
The manifest's hashes are of paths and contents only, so writable
copies don't count as user-modified, and updates still replace them.
Tested against the pinned source's tools/ with read-only bundled
skills: seeding, an update and a restore leave nothing read-only
(before: 382 paths), and nothing gets reported as user-modified.
Copies made before this stay read-only; chmod -R u+w ~/.hermes/skills
fixes them.
|
| |
|
|
|
|
|
|
|
|
| |
run-firecracker-vm's guests no longer have nix unless they have its
nix layer (layers/nix.nix). Claude builds and tries things with it
(nix-build, nix-shell), so claude asserts that it's there, as in
[ layers/nix.nix configs/claude.nix ], rather than coming up without.
With it, the run script requires --store, as before only for the store
to persist. hermes doesn't need nix: on its own, its store is
read-only.
|
| |
|
|
|
|
|
|
|
| |
claude and hermes each had their own claude-code and unfree predicate.
On top of each other, the predicates don't add up, one replaces the
other, and the claudes could drift apart with the next bump. Now both
import modules/claude-code.nix, which the module system takes only once:
claude-code, as pkgs.claude-code (an overlay), and its unfree predicate.
The package stays the same store path.
|
| |
|
|
|
|
|
| |
RequiresMountsFor only requires home.mount if there is one, which the
fc-home generator only makes with the drive (--home): without it, the
services started anyway, with their state on the tmpfs. Now they
assert that /home is a mount point, and fail otherwise.
|
| |
|
|
|
|
|
|
| |
The guest creates its users anew at every boot (userborn's state is on
the tmpfs), so a user's uid depended on which other users there were:
another layer's user could take claude's 1000, and the files on the
home drive would belong to someone else. claude keeps 1000, which its
files have already; hermes, and its group, get 1001.
|
| |
|
|
|
|
|
|
|
|
| |
hermes was the module's system user, with its home group-writable and
setgid (2770), for the module's hostUsers, which aren't used here: anyone
in the group could read the Claude login and hermes.env's secrets. Now
it's a normal user (still in its group hermes), and its home is 0700:
systemd-tmpfiles takes the first line for a path and ignores the
module's (with a warning), and hermes-agent-setup undoes the module
script's chmod 2770.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Both layers set fc.home.required, so the run script refuses to start
the guest without --home, instead of keeping the state on the tmpfs.
hermes' home (stateDir) moves from the store drive to /home/hermes,
where claude's is, too: the store drive is for the store, which should
be fine to throw away, and the home drive keeps what can't be. Like
claude's, the user's home doesn't get created with the user, as /home
isn't mounted yet then; the module's tmpfiles create it, and hermes'
services require the mount.
To keep the existing state, once, with both drives attached:
mv /nix/.rw-store/hermes /home/hermes
|
| | |
|
| |
|
|
|
| |
Denied by the egress list anyway: http-intake.logs.us5.datadoghq.com and
mcp-proxy.anthropic.com.
|
| |
|
|
|
| |
A Claude Code Remote Control server, on the Claude subscription, running
as claude in a tmux which root opens with claude-attach.
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Using the Claude subscription from Hermes, even through the official
claude CLI, is at best a gray area of Anthropic's terms, while an API
key from the Console organization linked to the subscription is what
they provide for, and the plan's monthly API credits cover it.
So the default is now Hermes' own anthropic provider with Claude Opus
5.5, and ANTHROPIC_API_KEY from hermes.env in the host's xchg, which the
setup merges into ~/.hermes/.env already. The subscription plugin stays
installed, selectable with /model or hermes model.
Without an API key, the anthropic provider would borrow the claude.ai
login in ~/.claude and send it passing itself off as Claude Code. That
login is claude's, for the plugin, so turn the borrowing off
(auth.adopt_external_logins); claude reads it itself, so the plugin
keeps working.
|
| |
|
|
|
|
| |
Root's login shell ran hermes-attach, which starts hermes' tmux, and
root logs in automatically on the console. Root attaches with
hermes-attach when it wants to.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
hermes-tmux.service started at boot and restarted hermes whenever it
quit, and as its RuntimeDirectory, /run/hermes went away whenever it
stopped, so attaching failed with "error creating /run/hermes/tmux".
Now hermes-tmux.socket holds /run/hermes/tmux, and the first client
starts tmux (-D, on systemd's socket), whose config starts hermes in
session hermes. Quitting hermes ends the session, and with exit-empty
the server and the service, until the next client. Detaching doesn't.
Hermes imports provider plugins from copies under
~/.hermes/runtime/provider-plugins, a set per process, reclaimed by
later processes. Copies of the read-only plugin from before couldn't
be removed, and crashes leave theirs: remove them all at boot, before
any Hermes runs.
|
| |
|
|
|
|
|
| |
The gateway formats its stderr log lines with a timestamp of their own,
which journald adds anyway. Patch hermes-agent's source to leave it out
when stderr is the journal (JOURNAL_STREAM is set); the log files in
~/.hermes/logs keep theirs.
|
| |
|
|
|
|
|
|
|
| |
Managed (HERMES_MANAGED, or the module's .managed marker), Hermes
refuses to save config.yaml at all, so /model --global and hermes model
couldn't keep a change; only session-only /model worked. Set
HERMES_MANAGED=false, which wins over the marker, for the gateway, the
tmux and hermes' shells, and make config.yaml writable for hermes. The
settings here still replace their keys in config.yaml at every boot.
|
| |
|
|
|
|
|
|
| |
The gateway serves the Webapp, Hermes Desktop in a browser, on port
9120. Bound to 0.0.0.0, so the host can reach it at the guest's
address, which needs the dashboard's sign-in: username, password (or
its hash) and a token-signing secret, as HERMES_DASHBOARD_BASIC_AUTH_*
in hermes.env in the host's xchg, merged into ~/.hermes/.env at boot.
|
| |
|
|
|
| |
The classic CLI takes every Enter on the console as a newline, so there
was no way to send; the TUI (hermes --tui) sends.
|
| |
|
|
|
|
|
| |
2.1.329 isn't in nixpkgs master's manifest yet. npm's platform package
@anthropic-ai/claude-code-linux-x64 has the release's plain binary, and
the registry gives its integrity hash, so take it from there: no zstd,
and no checksum to copy from elsewhere.
|
| |
|
|
|
|
|
|
|
| |
The plugin's requests failed: "Claude Code 2.1.223 does not support this
model; version 2.1.280 or newer is required". nixos-26.05 has 2.1.223.
Override its claude-code with 2.1.328, version and checksum from
nixpkgs master's manifest. Release binaries are zstd-compressed now,
which 26.05's installPhase doesn't expect, so decompress them first.
x86_64-linux only, like the checksum.
|
| |
|
|
|
|
| |
The sources of hermes-agent, its flake inputs and the provider plugin
now come from fixed-output derivations. Their store paths are the same
as before, as name and hash are.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Hermes knew the plugin (hermes plugins list) but not its provider.
Hermes imports a provider plugin from a snapshot: it copies the plugin
with shutil.copytree, modes included, and renames the copy from a
temporary directory into its place. Moving a directory to another
parent needs write permission on the directory itself, for its "..", so
with extraPlugins' symlink into the store, the copy is read-only, the
rename fails with EACCES for hermes (root could), and Hermes only logs
"Could not stage provider plugin".
Install a writable copy in hermes-agent-setup instead. extraPlugins'
old symlink goes away there, too, as the module removes nix-managed-*
links on each run.
|