🌤️ Weather Checker — 命令行天气查询工具
v1.0.0一个功能完整的命令行天气查询工具,使用 Open-Meteo API 获取实时天气数据,支持全球城市查询、7 天预报、温度、降水量、降水概率显示,具有多种输出格式。
0· 473·0 当前·0 累计
安全扫描
OpenClaw
安全
high confidence该技能与其声明的目的保持一致:一个使用 Open-Meteo API 的 Python 命令行天气工具,仅依赖 python3/requests,不要求凭据或访问无关资源。
评估建议
这似乎是一个直接、连贯的 CLI 天气工具。安装前:(1)检查包含的 weather_checker.py 而非盲目运行 curl;(2)验证 GitHub 主页/原始 URL 指向预期仓库;(3)避免使用 sudo 运行下载的脚本或将其管道到 shell;(4)了解它需要向 Open-Meteo 发出出站网络访问(无需 API 密钥)。如果任何检查失败或上游存储库与打包文件不同,请勿安装。...详细分析 ▾
✓ 用途与能力
Name/description match the implementation: the code is a Python CLI that geocodes city names and requests forecast data from Open‑Meteo. Declared required binary (python3) and the pip dependency (requests) are appropriate and proportional.
ℹ 指令范围
SKILL.md/README only instructs installing requests, downloading the script from the project's raw GitHub URL, and optionally linking it into /usr/local/bin. Runtime behavior in the included Python file matches the documented behavior (calls Open‑Meteo geocoding and forecast endpoints). Minor inconsistencies: README mentions a setup.sh that is not included, and the download URL and homepage use a placeholder username (yourusername) — you should verify the upstream repo before running the curl command.
ℹ 安装机制
There is no formal install spec in the registry (instruction-only). SKILL.md suggests curl to download the raw script from raw.githubusercontent.com and optionally creating a sudo symlink — these are common but carry the usual risk of executing code you downloaded. Because the skill bundle already contains weather_checker.py, you can inspect the shipped file instead of fetching from the raw URL.
✓ 凭证需求
The skill requests no environment variables, no credentials, and no config paths. Network access to Open‑Meteo endpoints is required and is consistent with the stated purpose.
✓ 持久化与权限
always:false and no special privileges requested. The only persistence the docs suggest is an optional user action to create a symlink (may require sudo) — this is a user-installed convenience and not performed automatically by the skill.
安全有层次,运行前请审查代码。
运行时依赖
无特殊依赖
版本
latestv1.0.02026/2/25
["发布 weather-checker 命令行工具的初始版本。","支持全球城市的天气查询,显示温度、降水量和概率。","具有漂亮、简单和 JSON 输出格式,带有 emoji 和颜色突出显示。","使用 Open-Meteo API 提供 7 天预报,无需 API 密钥。","包含网络和输入问题的错误处理。"]
● 可疑
安装命令 点击复制
官方npx clawhub@latest install weather-checker
镜像加速npx clawhub@latest install weather-checker --registry https://cn.clawhub-mirror.com
技能文档
一个功能完整的命令行天气查询工具,使用 Open-Meteo API 获取实时天气数据。## 功能特性
- 🌍 支持全球城市查询
- 📅 支持今天到未来7天的天气预报
- 🌡️ 显示最高/最低温度
- 💧 显示降水量和降水概率
- 🎨 三种输出格式:漂亮格式、简单格式、JSON格式
- 🎯 智能emoji匹配和颜色显示
安装方法
1. 安装Python依赖
pip3 install requests --user
2. 下载脚本
curl -O https://raw.githubusercontent.com/yourusername/weather-checker/main/weather_checker.py
chmod +x weather_checker.py
3. 创建全局命令(可选)
sudo ln -sf $(pwd)/weather_checker.py /usr/local/bin/weather-checker
使用方法
基本查询
# 查询北京明天的天气(默认)
weather-checker
# 查询上海明天的天气
weather-checker -c shanghai
# 查询广州后天的天气
weather-checker -c guangzhou -d 2
输出格式
# 漂亮格式(默认)
weather-checker
# 简单格式
weather-checker -f simple
# JSON格式
weather-checker -f json
其他选项
# 查询今天天气
weather-checker -d 0
# 列出预定义城市
weather-checker -l
# 查询国际城市
weather-checker -c "new york"
weather-checker -c "london"
输出示例
漂亮格式: ``
🌤️ 天气查询结果 🌤️
地点: 北京
日期: 2026-02-26
天气: 🌦️ 小雨
温度: 3.8°C ~ 8.3°C
降水量: 💧 0.8mm
降水概率: 🌤️ 20%
简单格式:
『北京 2026-02-26 🌦️小雨 3.8°C~8.3°C 💧0.8mm 🌤️20%』
技术细节
- API: 使用 Open-Meteo 免费API,无需API密钥
- 数据: 温度、降水量、降水概率、天气描述
- 城市: 内置中国主要城市,支持全球城市地理编码
- 错误处理: 完善的网络超时和错误提示
开发说明
如需修改或扩展功能,请编辑weather_checker.py 文件。主要可扩展功能包括:
- 添加更多天气参数(风速、湿度等)
- 支持历史天气查询
- 添加图表输出
- 多城市批量查询
许可证
MIT License贡献
欢迎提交Issue和Pull Request!数据来源:ClawHub ↗ · 中文优化:龙虾技能库
OpenClaw 技能定制 / 插件定制 / 私有工作流定制
免费技能或插件可能存在安全风险,如需更匹配、更安全的方案,建议联系付费定制