<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Clawhub on OHTLY Blog</title>
    <link>https://blog.ohtly.com/tags/clawhub/</link>
    <description>Recent content in Clawhub on OHTLY Blog</description>
    <generator>Hugo</generator>
    <language>zh-cn</language>
    <lastBuildDate>Thu, 25 Jun 2026 21:03:57 +0800</lastBuildDate>
    <atom:link href="https://blog.ohtly.com/tags/clawhub/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>OpenClaw 插件开发与 ClawHub 发布</title>
      <link>https://blog.ohtly.com/posts/2026-06-25-openclaw-plugin-publish/</link>
      <pubDate>Thu, 25 Jun 2026 21:03:57 +0800</pubDate>
      <guid>https://blog.ohtly.com/posts/2026-06-25-openclaw-plugin-publish/</guid>
      <description>&lt;p&gt;OpenClaw 的插件系统允许在 gateway 进程中挂载自定义逻辑，与 AI agent 共享运行时。插件可以做很多事情：监听 agent 事件、提供自定义 tool、定时任务，或者像我们这次一样——跑一个独立的同步守护进程。&lt;/p&gt;&#xA;&lt;p&gt;这篇记录从零创建一个插件、验证、发布到 ClawHub，再到远程节点安装的全过程。&lt;/p&gt;&#xA;&lt;h2 id=&#34;背景&#34;&gt;&#xA;  背景&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#%e8%83%8c%e6%99%af&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h2&gt;&#xA;&lt;p&gt;OpenClaw 插件和 Skill 的区别：Skill 是一组 instructions 文件，通过注入到 agent prompt 来改变行为；插件则是编译后的 JavaScript 代码，运行在 gateway 进程内，能调用 SDK 提供的 API（config、storage、http 等）。两者互补，技能负责&amp;quot;教 agent 怎么做&amp;quot;，插件负责&amp;quot;替 agent 做&amp;quot;。&lt;/p&gt;&#xA;&lt;h2 id=&#34;环境要求&#34;&gt;&#xA;  环境要求&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#%e7%8e%af%e5%a2%83%e8%a6%81%e6%b1%82&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Node.js ≥ 22.19&lt;/strong&gt;（OpenClaw 的要求）&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;TypeScript + ESM 模块&lt;/strong&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;clawhub CLI&lt;/strong&gt; — 用于验证和发布&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;一个 GitHub 仓库&lt;/strong&gt;（公开或私有均可）&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;安装 clawhub CLI：&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm install -g @openclaw/clawhub&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id=&#34;创建插件项目&#34;&gt;&#xA;  创建插件项目&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#%e5%88%9b%e5%bb%ba%e6%8f%92%e4%bb%b6%e9%a1%b9%e7%9b%ae&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h2&gt;&#xA;&lt;p&gt;推荐项目结构：&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
