@gajae-code/natives 0.11.10 → 0.11.11
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/native/index.d.ts +25 -1
- package/native/index.js +2 -1
- package/native/loader-state.d.ts +6 -0
- package/native/loader-state.js +4 -1
- package/package.json +6 -6
package/native/index.d.ts
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
/* auto-generated by NAPI-RS */
|
|
2
2
|
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* macOS computer-use controller.
|
|
5
|
+
*
|
|
6
|
+
* This declaration and the named JS export are available on every platform so
|
|
7
|
+
* consumers can import them portably; the native controller itself is built
|
|
8
|
+
* only on macOS.
|
|
9
|
+
*/
|
|
3
10
|
export declare class ComputerController {
|
|
4
11
|
constructor()
|
|
5
12
|
screenshot(): ComputerScreenshot
|
|
@@ -484,7 +491,7 @@ export declare function __piNativesPublishOutcomeV1(): void
|
|
|
484
491
|
* `packages/natives/native/index.js` (which derives the name from
|
|
485
492
|
* `package.json#version`).
|
|
486
493
|
*/
|
|
487
|
-
export declare function
|
|
494
|
+
export declare function __piNativesV0_11_11(): void
|
|
488
495
|
|
|
489
496
|
/**
|
|
490
497
|
* Apply conservative pre-execution rewrites to a bash command.
|
|
@@ -1891,6 +1898,8 @@ export interface PresentationLease {
|
|
|
1891
1898
|
registrationEpoch: number
|
|
1892
1899
|
}
|
|
1893
1900
|
|
|
1901
|
+
export declare function probeWindowsJobMemory(): WindowsJobMemoryProbeResult
|
|
1902
|
+
|
|
1894
1903
|
/** Current state of a process reference. */
|
|
1895
1904
|
export declare enum ProcessStatus {
|
|
1896
1905
|
/** The referenced process is still running. */
|
|
@@ -2282,6 +2291,21 @@ export declare function visibleWidth(text: string, tabWidth: number): number
|
|
|
2282
2291
|
/** Calculate visible widths of many strings, excluding ANSI escape sequences. */
|
|
2283
2292
|
export declare function visibleWidths(lines: Array<string>, tabWidth: number): Array<number>
|
|
2284
2293
|
|
|
2294
|
+
export interface WindowsJobMemoryProbeResult {
|
|
2295
|
+
kind: string
|
|
2296
|
+
platform: string
|
|
2297
|
+
isInJob?: boolean
|
|
2298
|
+
jobMemoryLimitBytes?: string
|
|
2299
|
+
jobMemoryUsedBytes?: string
|
|
2300
|
+
peakJobMemoryUsedBytes?: string
|
|
2301
|
+
processMemoryLimitBytes?: string
|
|
2302
|
+
processPrivateUsageBytes?: string
|
|
2303
|
+
processWorkingSetBytes?: string
|
|
2304
|
+
peakProcessWorkingSetBytes?: string
|
|
2305
|
+
call?: string
|
|
2306
|
+
code?: string
|
|
2307
|
+
}
|
|
2308
|
+
|
|
2285
2309
|
/** Profiling results returned to JavaScript. */
|
|
2286
2310
|
export interface WorkProfile {
|
|
2287
2311
|
/** Folded stack format for flamegraph tools. */
|
package/native/index.js
CHANGED
|
@@ -30,7 +30,7 @@ export const Shell = nativeBindings.Shell;
|
|
|
30
30
|
|
|
31
31
|
// functions
|
|
32
32
|
export const __piNativesPublishOutcomeV1 = nativeBindings.__piNativesPublishOutcomeV1;
|
|
33
|
-
export const
|
|
33
|
+
export const __piNativesV0_11_11 = nativeBindings.__piNativesV0_11_11;
|
|
34
34
|
export const applyBashFixups = nativeBindings.applyBashFixups;
|
|
35
35
|
export const applyOwnerOnlyFdSecurity = nativeBindings.applyOwnerOnlyFdSecurity;
|
|
36
36
|
export const applyOwnerOnlyPathSecurity = nativeBindings.applyOwnerOnlyPathSecurity;
|
|
@@ -75,6 +75,7 @@ export const nativeBuildInfo = nativeBindings.nativeBuildInfo;
|
|
|
75
75
|
export const openRecoveryFsRoot = nativeBindings.openRecoveryFsRoot;
|
|
76
76
|
export const parseKey = nativeBindings.parseKey;
|
|
77
77
|
export const parseKittySequence = nativeBindings.parseKittySequence;
|
|
78
|
+
export const probeWindowsJobMemory = nativeBindings.probeWindowsJobMemory;
|
|
78
79
|
export const ptyTimeoutCount = nativeBindings.ptyTimeoutCount;
|
|
79
80
|
export const readImageFromClipboard = nativeBindings.readImageFromClipboard;
|
|
80
81
|
export const renameNoReplacePath = nativeBindings.renameNoReplacePath;
|
package/native/loader-state.d.ts
CHANGED
|
@@ -79,6 +79,12 @@ export interface CachedEmbeddedExtractionIsFreshInput {
|
|
|
79
79
|
|
|
80
80
|
export function cachedEmbeddedExtractionIsFresh(input: CachedEmbeddedExtractionIsFreshInput): boolean;
|
|
81
81
|
|
|
82
|
+
export function validateLoadedBindings(
|
|
83
|
+
ctx: { versionSentinelExport: string; packageVersion: string },
|
|
84
|
+
bindings: Record<string, unknown>,
|
|
85
|
+
candidate: string,
|
|
86
|
+
): void;
|
|
87
|
+
|
|
82
88
|
export interface LoaderContext {
|
|
83
89
|
isCompiledBinary: boolean;
|
|
84
90
|
platformTag: string;
|
package/native/loader-state.js
CHANGED
|
@@ -401,7 +401,7 @@ function maybeStageNodeModulesAddon(ctx, errors) {
|
|
|
401
401
|
return stagedPath;
|
|
402
402
|
}
|
|
403
403
|
|
|
404
|
-
function validateLoadedBindings(ctx, bindings, candidate) {
|
|
404
|
+
export function validateLoadedBindings(ctx, bindings, candidate) {
|
|
405
405
|
if (typeof bindings[ctx.versionSentinelExport] !== "function") {
|
|
406
406
|
throw new Error(
|
|
407
407
|
`Loaded ${candidate} but it does not expose the @gajae-code/natives@${ctx.packageVersion} ` +
|
|
@@ -418,6 +418,9 @@ function validateLoadedBindings(ctx, bindings, candidate) {
|
|
|
418
418
|
if (typeof bindings.renameNoReplacePath !== "function") {
|
|
419
419
|
throw new Error(`Loaded ${candidate} but it lacks required atomic publish capability \`renameNoReplacePath\`.`);
|
|
420
420
|
}
|
|
421
|
+
if (typeof bindings.probeWindowsJobMemory !== "function") {
|
|
422
|
+
throw new Error(`Loaded ${candidate} but it lacks required memory probe capability \`probeWindowsJobMemory\`.`);
|
|
423
|
+
}
|
|
421
424
|
}
|
|
422
425
|
|
|
423
426
|
function buildHelpMessage(ctx) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gajae-code/natives",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.11",
|
|
4
4
|
"description": "Native Rust bindings for grep, clipboard, image processing, syntax highlighting, PTY, and shell operations via N-API",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"homepage": "https://gajae-code.com",
|
|
@@ -61,11 +61,11 @@
|
|
|
61
61
|
"README.md"
|
|
62
62
|
],
|
|
63
63
|
"optionalDependencies": {
|
|
64
|
-
"@gajae-code/natives-darwin-arm64": "0.11.
|
|
65
|
-
"@gajae-code/natives-darwin-x64": "0.11.
|
|
66
|
-
"@gajae-code/natives-linux-arm64": "0.11.
|
|
67
|
-
"@gajae-code/natives-linux-x64": "0.11.
|
|
68
|
-
"@gajae-code/natives-win32-x64": "0.11.
|
|
64
|
+
"@gajae-code/natives-darwin-arm64": "0.11.11",
|
|
65
|
+
"@gajae-code/natives-darwin-x64": "0.11.11",
|
|
66
|
+
"@gajae-code/natives-linux-arm64": "0.11.11",
|
|
67
|
+
"@gajae-code/natives-linux-x64": "0.11.11",
|
|
68
|
+
"@gajae-code/natives-win32-x64": "0.11.11"
|
|
69
69
|
},
|
|
70
70
|
"exports": {
|
|
71
71
|
".": {
|