← 返回
未分类 中文

google-search-wsl

Perform Google searches and retrieve web or news results via Chrome browser running in WSL using remote debugging with OpenClaw tool.
使用 OpenClaw工具在 WSL 中通过 Chrome 浏览器进行远程调试,执行 Google 搜索并获取网页或新闻结果。
jesson-hh jesson-hh 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 1
Stars
📥 350
下载
💾 0
安装
1
版本
#latest

概述

Google Search (WSL Chrome)

Perform Google searches through Chrome browser in WSL.

Prerequisites

  • google-chrome-stable or google-chrome installed in WSL
  • WSLg available (or X11 forwarding configured)
  • OpenClaw browser tool enabled

Quick Start

1. Launch Chrome

Run the startup script:

bash ~/.openclaw/scripts/google-search-chrome.sh

Or start manually:

export DISPLAY=:0
google-chrome-stable --remote-debugging-port=9222 \
  --remote-allow-origins='*' \
  --user-data-dir="$HOME/.openclaw/chrome-debug-profile" \
  --lang=zh-CN \
  --disable-gpu \
  --disable-dev-shm-usage &

2. Verify Chrome is Running

curl -s http://127.0.0.1:9222/json/version

Should return Chrome version information.

3. Search Using Browser Tool

browser action=open url="https://www.google.com/search?q=your+search+term" profile=user
browser action=snapshot targetId=<returned-targetId>

Troubleshooting

Chrome Won't Start (Missing X server)

Ensure WSLg is available, or set the DISPLAY environment variable:

export DISPLAY=:0
# Or check WSLg
ls /mnt/wslg/.X11-unix/

Port 9222 Already in Use

Check and kill the occupying process:

lsof -i :9222
kill <PID>

Empty Search Results

  • Check network connection
  • Try using a proxy (if HTTP_PROXY is configured)
  • Wait for the page to fully load before taking a snapshot

Tips

  • Chinese keywords in search URLs will be automatically encoded
  • Use snapshot to get page content, then extract the needed information
  • For news search, use the tbm=nws parameter: /search?q=keyword&tbm=nws

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-07 06:36 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

data-analysis

Tavily 搜索

jacky1n7
通过 Tavily API 进行网页搜索(Brave 替代方案)。当用户要求搜索网页、查找来源或链接,且 Brave 网页搜索不可用时使用。
★ 279 📥 102,050
data-analysis

Stock Analysis

udiedrichsen
利用Yahoo Finance数据深度分析股票和加密货币。支持投资组合管理、关注列表与提醒、股息分析、八维度股票评分、热门趋势扫描(热点扫描器)及谣言/早期信号检测。适用于股票分析、投资组合追踪、财报反应、加密货币监控、热门股票发现及在主流
★ 284 📥 58,531
data-analysis

Data Analysis

ivangdavila
{"answer":"数据分析与可视化。查询数据库、生成报告、自动化电子表格,将原始数据转化为清晰可行的见解。适用于:(1) 您……"}
★ 219 📥 72,861