typescript-virtual-container 1.4.7 → 1.4.9
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 +1 -2
- package/benchmark-results.txt +21 -21
- package/builds/self-standalone.js +979 -168
- package/builds/standalone-wo-sftp.js +982 -173
- package/builds/standalone.cjs +989 -179
- package/builds/web-full-api.min.js +0 -1
- package/builds/web.min.js +0 -1
- package/dist/Honeypot/index.d.ts +6 -0
- package/dist/Honeypot/index.d.ts.map +1 -1
- package/dist/Honeypot/index.js +20 -0
- package/dist/Honeypot/index.js.map +1 -1
- package/dist/SSHMimic/index.d.ts +6 -5
- package/dist/SSHMimic/index.d.ts.map +1 -1
- package/dist/SSHMimic/index.js +8 -5
- package/dist/SSHMimic/index.js.map +1 -1
- package/dist/SSHMimic/sftp.d.ts +1 -0
- package/dist/SSHMimic/sftp.d.ts.map +1 -1
- package/dist/SSHMimic/sftp.js.map +1 -1
- package/dist/VirtualFileSystem/binaryPack.d.ts.map +1 -1
- package/dist/VirtualFileSystem/binaryPack.js +21 -9
- package/dist/VirtualFileSystem/binaryPack.js.map +1 -1
- package/dist/VirtualFileSystem/index.d.ts +25 -0
- package/dist/VirtualFileSystem/index.d.ts.map +1 -1
- package/dist/VirtualFileSystem/index.js +152 -47
- package/dist/VirtualFileSystem/index.js.map +1 -1
- package/dist/VirtualFileSystem/internalTypes.d.ts +23 -4
- package/dist/VirtualFileSystem/internalTypes.d.ts.map +1 -1
- package/dist/VirtualFileSystem/journal.d.ts +1 -0
- package/dist/VirtualFileSystem/journal.d.ts.map +1 -1
- package/dist/VirtualFileSystem/journal.js.map +1 -1
- package/dist/VirtualFileSystem/path.js +1 -1
- package/dist/VirtualFileSystem/path.js.map +1 -1
- package/dist/VirtualShell/idleManager.d.ts +69 -0
- package/dist/VirtualShell/idleManager.d.ts.map +1 -0
- package/dist/VirtualShell/idleManager.js +110 -0
- package/dist/VirtualShell/idleManager.js.map +1 -0
- package/dist/VirtualShell/index.d.ts +41 -1
- package/dist/VirtualShell/index.d.ts.map +1 -1
- package/dist/VirtualShell/index.js +54 -1
- package/dist/VirtualShell/index.js.map +1 -1
- package/dist/VirtualUserManager/index.d.ts +4 -2
- package/dist/VirtualUserManager/index.d.ts.map +1 -1
- package/dist/VirtualUserManager/index.js +0 -1
- package/dist/VirtualUserManager/index.js.map +1 -1
- package/dist/commands/command-helpers.d.ts +5 -2
- package/dist/commands/command-helpers.d.ts.map +1 -1
- package/dist/commands/command-helpers.js.map +1 -1
- package/dist/commands/man.d.ts.map +1 -1
- package/dist/commands/man.js +5 -28
- package/dist/commands/man.js.map +1 -1
- package/dist/commands/manuals-bundle.d.ts +11 -0
- package/dist/commands/manuals-bundle.d.ts.map +1 -0
- package/dist/commands/manuals-bundle.js +898 -0
- package/dist/commands/manuals-bundle.js.map +1 -0
- package/dist/index.d.ts +7 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/modules/linuxRootfs.d.ts +8 -1
- package/dist/modules/linuxRootfs.d.ts.map +1 -1
- package/dist/modules/linuxRootfs.js +47 -14
- package/dist/modules/linuxRootfs.js.map +1 -1
- package/dist/self-standalone.js +15 -0
- package/dist/self-standalone.js.map +1 -1
- package/dist/standalone.js +22 -0
- package/dist/standalone.js.map +1 -1
- package/docs/assets/hierarchy.js +1 -1
- package/docs/assets/navigation.js +1 -1
- package/docs/assets/search.js +1 -1
- package/docs/classes/HoneyPot.html +9 -9
- package/docs/classes/IdleManager.html +162 -0
- package/docs/classes/SshClient.html +18 -18
- package/docs/classes/VirtualFileSystem.html +50 -33
- package/docs/classes/VirtualPackageManager.html +13 -13
- package/docs/classes/VirtualSftpServer.html +3 -3
- package/docs/classes/VirtualShell.html +47 -28
- package/docs/classes/VirtualSshServer.html +12 -7
- package/docs/classes/VirtualUserManager.html +30 -30
- package/docs/functions/assertDiff.html +2 -2
- package/docs/functions/diffSnapshots.html +2 -2
- package/docs/functions/formatDiff.html +2 -2
- package/docs/functions/getArg.html +3 -3
- package/docs/functions/getFlag.html +2 -2
- package/docs/functions/ifFlag.html +2 -2
- package/docs/hierarchy.html +1 -1
- package/docs/index.html +4 -5
- package/docs/interfaces/AuditLogEntry.html +3 -3
- package/docs/interfaces/CommandContext.html +13 -13
- package/docs/interfaces/CommandResult.html +13 -13
- package/docs/interfaces/ExecStream.html +6 -6
- package/docs/interfaces/HoneyPotStats.html +5 -3
- package/docs/interfaces/IdleManagerOptions.html +7 -0
- package/docs/interfaces/InstalledPackage.html +11 -11
- package/docs/interfaces/NanoEditorSession.html +5 -5
- package/docs/interfaces/PackageDefinition.html +14 -14
- package/docs/interfaces/PackageFile.html +5 -5
- package/docs/interfaces/PasswordChallenge.html +16 -0
- package/docs/interfaces/RemoveOptions.html +3 -3
- package/docs/interfaces/ShellEnv.html +4 -4
- package/docs/interfaces/ShellModule.html +8 -8
- package/docs/interfaces/ShellProperties.html +5 -5
- package/docs/interfaces/ShellStream.html +7 -7
- package/docs/interfaces/SudoChallenge.html +9 -9
- package/docs/interfaces/VfsBaseNode.html +7 -7
- package/docs/interfaces/VfsDiff.html +6 -6
- package/docs/interfaces/VfsDiffEntry.html +4 -4
- package/docs/interfaces/VfsDiffModified.html +6 -6
- package/docs/interfaces/VfsDirectoryNode.html +8 -8
- package/docs/interfaces/VfsFileNode.html +9 -9
- package/docs/interfaces/VfsOptions.html +18 -4
- package/docs/interfaces/VfsSnapshot.html +3 -3
- package/docs/interfaces/VfsSnapshotBaseNode.html +4 -4
- package/docs/interfaces/VfsSnapshotDirectoryNode.html +5 -5
- package/docs/interfaces/VfsSnapshotFileNode.html +6 -6
- package/docs/interfaces/VirtualActiveSession.html +12 -0
- package/docs/interfaces/VirtualSftpServerOptions.html +7 -0
- package/docs/interfaces/VirtualShellVfsLike.html +15 -0
- package/docs/interfaces/VirtualShellVfsOptions.html +3 -0
- package/docs/interfaces/WriteFileOptions.html +4 -4
- package/docs/modules.html +1 -1
- package/docs/types/ArgParseOptions.html +4 -0
- package/docs/types/CommandMode.html +2 -2
- package/docs/types/CommandOutcome.html +2 -2
- package/docs/types/IdleState.html +1 -0
- package/docs/types/VfsNodeStats.html +2 -2
- package/docs/types/VfsNodeType.html +2 -2
- package/docs/types/VfsPersistenceMode.html +2 -2
- package/docs/types/VfsSnapshotNode.html +2 -2
- package/examples/web.min.js +0 -1
- package/package.json +13 -12
- package/scripts/generate-manuals-bundle.mjs +49 -0
- package/scripts/publish-package.sh +1 -1
- package/src/Honeypot/index.ts +24 -0
- package/src/SSHMimic/index.ts +9 -5
- package/src/SSHMimic/sftp.ts +6 -0
- package/src/VirtualFileSystem/binaryPack.ts +21 -9
- package/src/VirtualFileSystem/index.ts +151 -53
- package/src/VirtualFileSystem/internalTypes.ts +24 -4
- package/src/VirtualFileSystem/journal.ts +1 -0
- package/src/VirtualFileSystem/path.ts +1 -1
- package/src/VirtualShell/idleManager.ts +137 -0
- package/src/VirtualShell/index.ts +64 -1
- package/src/VirtualUserManager/index.ts +4 -2
- package/src/commands/command-helpers.ts +5 -1
- package/src/commands/man.ts +5 -37
- package/src/commands/manuals-bundle.ts +898 -0
- package/src/index.ts +7 -1
- package/src/modules/linuxRootfs.ts +58 -14
- package/src/self-standalone.ts +13 -0
- package/src/standalone.ts +23 -0
- package/typedoc.json +45 -0
- package/builds/self-standalone.js.map +0 -7
- package/builds/standalone-wo-sftp.js.map +0 -7
- package/builds/standalone.cjs.map +0 -7
- package/builds/web-full-api.min.js.map +0 -7
- package/builds/web.min.js.map +0 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"command-helpers.js","sourceRoot":"","sources":["../../src/commands/command-helpers.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"command-helpers.js","sourceRoot":"","sources":["../../src/commands/command-helpers.ts"],"names":[],"mappings":"AASA,SAAS,UAAU,CAAC,KAAwB;IAC3C,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,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M,IAAI,GAAG,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC;YAC7B,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;gBACnC,eAAe,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;gBAC/B,KAAK,IAAI,CAAC,CAAC;YACZ,CAAC;iBAAM,CAAC;gBACP,eAAe,CAAC,GAAG,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;YAC9B,CAAC;YACD,SAAS;QACV,CAAC;QAED,MAAM,UAAU,GAAG,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CACvD,GAAG,CAAC,UAAU,CAAC,GAAG,IAAI,GAAG,CAAC,CAC1B,CAAC;QACF,IAAI,UAAU,EAAE,CAAC;YAChB,eAAe,CAAC,GAAG,CAAC,UAAU,EAAE,GAAG,CAAC,KAAK,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC;YAClE,SAAS;QACV,CAAC;QAED,WAAW,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IACvB,CAAC;IAED,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,WAAW,EAAE,CAAC;AAChD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"man.d.ts","sourceRoot":"","sources":["../../src/commands/man.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"man.d.ts","sourceRoot":"","sources":["../../src/commands/man.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAOrD,eAAO,MAAM,UAAU,EAAE,WAuBxB,CAAC"}
|
package/dist/commands/man.js
CHANGED
|
@@ -1,33 +1,7 @@
|
|
|
1
|
+
import { MANUALS } from "./manuals-bundle";
|
|
1
2
|
const MANUAL_ALIASES = {
|
|
2
3
|
gunzip: "gzip",
|
|
3
4
|
};
|
|
4
|
-
const __dirname = import.meta.dirname;
|
|
5
|
-
const manualCache = new Map();
|
|
6
|
-
const manualsBaseUrl = new URL("./manuals/", import.meta.url);
|
|
7
|
-
async function dynamicImport(specifier) {
|
|
8
|
-
const importer = new Function("moduleName", "return import(moduleName)");
|
|
9
|
-
return importer(specifier);
|
|
10
|
-
}
|
|
11
|
-
async function loadBundledManual(commandName) {
|
|
12
|
-
const normalized = commandName.toLowerCase();
|
|
13
|
-
const lookupName = MANUAL_ALIASES[normalized] ?? normalized;
|
|
14
|
-
const cacheKey = `builtin:${lookupName}`;
|
|
15
|
-
if (manualCache.has(cacheKey)) {
|
|
16
|
-
return manualCache.get(cacheKey) ?? null;
|
|
17
|
-
}
|
|
18
|
-
try {
|
|
19
|
-
const fsModule = (await dynamicImport("node:fs/promises"));
|
|
20
|
-
const manualUrl = new URL(`${lookupName}.txt`, manualsBaseUrl);
|
|
21
|
-
const content = await fsModule.readFile(manualUrl, "utf8");
|
|
22
|
-
const page = content.replace(/\n$/, "");
|
|
23
|
-
manualCache.set(cacheKey, page);
|
|
24
|
-
return page;
|
|
25
|
-
}
|
|
26
|
-
catch {
|
|
27
|
-
manualCache.set(cacheKey, null);
|
|
28
|
-
return null;
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
5
|
export const manCommand = {
|
|
32
6
|
name: "man",
|
|
33
7
|
description: "Interface to the system reference manuals",
|
|
@@ -42,7 +16,10 @@ export const manCommand = {
|
|
|
42
16
|
if (shell.vfs.exists(manPath)) {
|
|
43
17
|
return { stdout: shell.vfs.readFile(manPath), exitCode: 0 };
|
|
44
18
|
}
|
|
45
|
-
|
|
19
|
+
// Bundled manuals — available in all build modes (standalone, web, dev)
|
|
20
|
+
const normalized = name.toLowerCase();
|
|
21
|
+
const lookupName = MANUAL_ALIASES[normalized] ?? normalized;
|
|
22
|
+
const page = MANUALS[lookupName] ?? null;
|
|
46
23
|
if (page)
|
|
47
24
|
return { stdout: page, exitCode: 0 };
|
|
48
25
|
return { stderr: `No manual entry for ${name}`, exitCode: 16 };
|
package/dist/commands/man.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"man.js","sourceRoot":"","sources":["../../src/commands/man.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"man.js","sourceRoot":"","sources":["../../src/commands/man.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAE3C,MAAM,cAAc,GAA2B;IAC9C,MAAM,EAAE,MAAM;CACd,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAgB;IACtC,IAAI,EAAE,KAAK;IACX,WAAW,EAAE,2CAA2C;IACxD,QAAQ,EAAE,OAAO;IACjB,MAAM,EAAE,CAAC,WAAW,CAAC;IACrB,GAAG,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,EAAE;QAC9B,MAAM,IAAI,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;QACrB,IAAI,CAAC,IAAI;YAAE,OAAO,EAAE,MAAM,EAAE,+BAA+B,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;QAE3E,wCAAwC;QACxC,MAAM,OAAO,GAAG,uBAAuB,IAAI,IAAI,CAAC;QAChD,IAAI,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC;YAC/B,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;QAC7D,CAAC;QAED,wEAAwE;QACxE,MAAM,UAAU,GAAG,IAAI,CAAC,WAAW,EAAE,CAAC;QACtC,MAAM,UAAU,GAAG,cAAc,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC;QAC5D,MAAM,IAAI,GAAG,OAAO,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC;QACzC,IAAI,IAAI;YAAE,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;QAE/C,OAAO,EAAE,MAAM,EAAE,uBAAuB,IAAI,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,CAAC;IAChE,CAAC;CACD,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Auto-generated by scripts/generate-manuals-bundle.mjs
|
|
3
|
+
* DO NOT EDIT — run `node scripts/generate-manuals-bundle.mjs` to regenerate.
|
|
4
|
+
*
|
|
5
|
+
* Inlines all src/commands/manuals/*.txt files so that standalone and web
|
|
6
|
+
* builds have access to man pages without needing filesystem access.
|
|
7
|
+
*/
|
|
8
|
+
/** biome-ignore-all lint/style/useNamingConvention: generated keys match command names (e.g. lsb_release) */
|
|
9
|
+
/** Static map of command name → man page content. */
|
|
10
|
+
export declare const MANUALS: Readonly<Record<string, string>>;
|
|
11
|
+
//# sourceMappingURL=manuals-bundle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manuals-bundle.d.ts","sourceRoot":"","sources":["../../src/commands/manuals-bundle.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,6GAA6G;AAE7G,qDAAqD;AACrD,eAAO,MAAM,OAAO,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAu3B3C,CAAC"}
|