aboutsummaryrefslogtreecommitdiffstats
path: root/desktop/assistant/README.md
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-10-16 16:20:01 +0200
committerDanilo M. <danix@danix.xyz>2026-10-16 16:20:01 +0200
commit12d6830424d24f5a2ed8056b53a12cc4b978ece2 (patch)
treea52a30ab446acd718aa67e1c8dc2887a472954cb /desktop/assistant/README.md
parentf6ceae477979b32869c0c17e2b1fc05477d6eb81 (diff)
downloadquickshell-12d6830424d24f5a2ed8056b53a12cc4b978ece2.tar.gz
quickshell-12d6830424d24f5a2ed8056b53a12cc4b978ece2.zip
feat(assistant): tell a nameless file's kind from its content
A script with no suffix staged as 'other' and was refused. A staged file the name says nothing about is now handed to file(1) once, and its mime type gives the kind, so a shell script is code and gets Explain and Review. The daemon makes its own call on the content. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'desktop/assistant/README.md')
-rw-r--r--desktop/assistant/README.md6
1 files changed, 4 insertions, 2 deletions
diff --git a/desktop/assistant/README.md b/desktop/assistant/README.md
index 4715b12..8c74343 100644
--- a/desktop/assistant/README.md
+++ b/desktop/assistant/README.md
@@ -61,8 +61,10 @@ Notes:
markers literally.
- **File kinds are decided twice.** `Files.js` decides what the card
- offers; the daemon decides what chat accepts. The lists match, but the
- daemon also takes any `text/*` file, which the card may show as "other".
+ offers; the daemon decides what chat accepts. Both go by the name first
+ and by the content when the name says nothing: the card runs
+ `file -b --mime-type` on staged "other" files, the daemon reads the first
+ 4 KB. A script with no suffix is therefore code here and text there.
- **`socketPath`** is a property so a check can point the canvas at a
scratch daemon; the desktop uses the default.