@hasna/skills 0.10.47 → 0.10.49
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 +34 -0
- package/bin/index.js +1091 -649
- package/bin/maintenance.js +18 -0
- package/bin/mcp.js +65 -2
- package/bin/migrate.js +19 -1
- package/bin/server.js +19 -1
- package/bin/worker.js +19 -1
- package/dist/cli/commands/runtime-launcher.d.ts +102 -0
- package/dist/cli/commands/runtime.d.ts +7 -0
- package/dist/cli/index.d.ts +1 -1
- package/dist/index.js +414 -262
- package/dist/lib/launch-cwd-apply.d.ts +1 -0
- package/dist/lib/launch-cwd.d.ts +5 -0
- package/dist/lib/self-spawn.d.ts +21 -0
- package/dist/mcp/index.d.ts +1 -0
- package/dist/sdk/index.js +397 -245
- package/dist/server/index.d.ts +1 -1
- package/dist/server/maintenance.d.ts +1 -1
- package/dist/server/migrate.d.ts +17 -0
- package/dist/server/worker.d.ts +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1270,6 +1270,40 @@ reinstall or change your PATH.
|
|
|
1270
1270
|
copyfile runtime, preserves configuration and launcher preimages, and keeps the
|
|
1271
1271
|
previous runtime available for receipt-bound rollback.
|
|
1272
1272
|
|
|
1273
|
+
Every launcher the updater switches (`skills`, `skills-mcp`, `skills-serve`,
|
|
1274
|
+
`skills-server`, `skills-worker`, `skills-maintenance` and `skills-migrate`, in each
|
|
1275
|
+
PATH directory it manages, and every alias `--adopt-aliases` switches) is written as a
|
|
1276
|
+
pinned launcher, not a bare symlink. It is a `#!/bin/sh -p` file: the shell ignores
|
|
1277
|
+
exported functions and `SHELLOPTS`-style settings from your environment, and the
|
|
1278
|
+
updater refuses with `LAUNCHER_SHELL_UNSUPPORTED` before writing anything when
|
|
1279
|
+
`/bin/sh` does not accept `-p` (for example dash older than 0.5.11). The launcher
|
|
1280
|
+
execs the exact Bun binary that ran the update with
|
|
1281
|
+
`--config=/dev/null --no-env-file --no-macros --no-install --cwd=<runtime version root>`
|
|
1282
|
+
on the exact entry, through `env -i` with an explicit environment allowlist:
|
|
1283
|
+
`HOME`, `PATH`, `TMPDIR`, `USER`, `LOGNAME`, `SHELL`, `TZ`, `LANG`, terminal names
|
|
1284
|
+
(`TERM`, `TERM_PROGRAM`, `TERM_PROGRAM_VERSION`, `COLORTERM`, `COLUMNS`, `LINES`),
|
|
1285
|
+
`NO_COLOR`, `FORCE_COLOR`, `CI`, `EDITOR`, `VISUAL`, `PAGER`, `SSH_AUTH_SOCK`,
|
|
1286
|
+
`DATABASE_URL`, the server settings `HOST`, `PORT`, `NODE_ENV`, `AGENT_ID` and
|
|
1287
|
+
`ECS_CONTAINER_METADATA_URI_V4`, the agent names `TERMINAL_CWD`, `CODEX_HOME`,
|
|
1288
|
+
`HERMES_HOME` and `HERMES_ENABLE_PROJECT_PLUGINS`, and every name starting with
|
|
1289
|
+
`HASNA_`, `SKILLS_`, `SKILL_`, `MCP_`, `XDG_`, `LC_` or `AWS_`. Your `LC_ALL` passes
|
|
1290
|
+
through unchanged. Everything else never reaches the runtime, including `BUN_*`,
|
|
1291
|
+
`NODE_OPTIONS`, `DYLD_*`, `LD_*`, `NODE_EXTRA_CA_CERTS` and the proxy variables
|
|
1292
|
+
(`HTTP_PROXY`, `HTTPS_PROXY`, `NO_PROXY`). A `bunfig.toml`, `.env` or `tsconfig.json`
|
|
1293
|
+
in the directory you run a command from is never read.
|
|
1294
|
+
|
|
1295
|
+
Each of those entries (the CLI, the MCP server, the API server, the worker,
|
|
1296
|
+
maintenance and migrate) returns to your directory before anything else runs, so
|
|
1297
|
+
relative paths keep working, including a relative `HASNA_SKILLS_DATABASE_URL`. When
|
|
1298
|
+
the CLI starts another copy of itself (the hook's context lookup and its
|
|
1299
|
+
`SessionStart` sync), the child gets the same Bun flags, the runtime version root as
|
|
1300
|
+
its working directory and the same environment allowlist, and also returns to your
|
|
1301
|
+
directory first. The receipt records the old and new launcher shape of every path,
|
|
1302
|
+
the backup keeps the exact previous launcher (symlink text or pinned bytes), and
|
|
1303
|
+
`--rollback` restores it byte for byte. Codex hook trust, the Claude settings
|
|
1304
|
+
projection and `skills self-update` read a managed pinned launcher as the exact
|
|
1305
|
+
entry it runs and bind the launcher's own bytes as well.
|
|
1306
|
+
|
|
1273
1307
|
To require a minimum dependency age, pass a positive integer number of days and
|
|
1274
1308
|
repeat the exclusion option for package names or package globs:
|
|
1275
1309
|
|