agent-browser 0.3.6 → 0.3.7
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/bin/agent-browser
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
#!/bin/sh
|
|
2
|
-
# agent-browser CLI wrapper
|
|
3
|
-
|
|
4
2
|
SCRIPT="$0"
|
|
5
3
|
while [ -L "$SCRIPT" ]; do
|
|
6
4
|
SCRIPT_DIR="$(cd "$(dirname "$SCRIPT")" && pwd)"
|
|
@@ -8,12 +6,10 @@ while [ -L "$SCRIPT" ]; do
|
|
|
8
6
|
case "$SCRIPT" in /*) ;; *) SCRIPT="$SCRIPT_DIR/$SCRIPT" ;; esac
|
|
9
7
|
done
|
|
10
8
|
SCRIPT_DIR="$(cd "$(dirname "$SCRIPT")" && pwd)"
|
|
11
|
-
|
|
12
9
|
OS=$(uname -s | tr '[:upper:]' '[:lower:]')
|
|
13
10
|
ARCH=$(uname -m)
|
|
14
11
|
case "$OS" in darwin) OS="darwin" ;; linux) OS="linux" ;; mingw*|msys*|cygwin*) OS="win32" ;; esac
|
|
15
12
|
case "$ARCH" in x86_64|amd64) ARCH="x64" ;; aarch64|arm64) ARCH="arm64" ;; esac
|
|
16
|
-
|
|
17
13
|
BINARY="$SCRIPT_DIR/agent-browser-${OS}-${ARCH}"
|
|
18
14
|
[ -f "$BINARY" ] && [ -x "$BINARY" ] && exec "$BINARY" "$@"
|
|
19
15
|
exec node "$SCRIPT_DIR/../dist/index.js" "$@"
|
|
Binary file
|
|
Binary file
|
package/bin/agent-browser.cmd
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
@echo off
|
|
2
2
|
setlocal
|
|
3
3
|
set "SCRIPT_DIR=%~dp0"
|
|
4
|
-
if "%PROCESSOR_ARCHITECTURE%"=="AMD64" (set "ARCH=x64") else if "%PROCESSOR_ARCHITECTURE%"=="ARM64" (set "ARCH=arm64") else (set "ARCH=x64")
|
|
5
|
-
set "BINARY=%SCRIPT_DIR%agent-browser-win32-%ARCH%.exe"
|
|
6
|
-
if exist "%BINARY%" ("%BINARY%" %* & exit /b %errorlevel%)
|
|
7
4
|
node "%SCRIPT_DIR%..\dist\index.js" %*
|
|
8
5
|
exit /b %errorlevel%
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agent-browser",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.7",
|
|
4
4
|
"description": "Headless browser automation CLI for AI agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -15,7 +15,9 @@
|
|
|
15
15
|
"scripts": {
|
|
16
16
|
"build": "tsc",
|
|
17
17
|
"build:native": "cargo build --release --manifest-path cli/Cargo.toml && node scripts/copy-native.js",
|
|
18
|
-
"build:
|
|
18
|
+
"build:linux": "docker compose -f docker/docker-compose.yml run --rm build-linux",
|
|
19
|
+
"build:macos": "cargo build --release --manifest-path cli/Cargo.toml --target aarch64-apple-darwin && cargo build --release --manifest-path cli/Cargo.toml --target x86_64-apple-darwin && cp cli/target/aarch64-apple-darwin/release/agent-browser bin/agent-browser-darwin-arm64 && cp cli/target/x86_64-apple-darwin/release/agent-browser bin/agent-browser-darwin-x64",
|
|
20
|
+
"build:all-platforms": "npm run build:linux && npm run build:macos",
|
|
19
21
|
"build:docker": "docker build -t agent-browser-builder -f docker/Dockerfile.build .",
|
|
20
22
|
"start": "node dist/index.js",
|
|
21
23
|
"dev": "tsx src/index.ts",
|