npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

renflow-runner

v0.1.5

Published

RenFlow runner

Readme

Ren Flow Runner

OneBot-RenFlow 的独立工作流执行引擎,支持 OneBot 协议连接。

特性

  • 🚀 独立运行,无需 Tauri 桌面应用
  • 🔌 支持 OneBot 11 协议(WebSocket)
  • 🔄 工作流自动化执行
  • 📝 完整的日志系统
  • 🛠️ TypeScript 开发,类型安全

项目结构

renflow.runner/
├── src/
│   ├── index.ts          # 主入口
│   ├── onebot/           # OneBot 协议实现
│   ├── workflow/         # 工作流引擎
│   ├── types/            # TypeScript 类型定义
│   └── utils/            # 工具函数
├── dist/                 # 构建输出
├── package.json
└── tsconfig.json

使用示例

基础使用

import { nodeManager, LogLevel } from 'renflow-runner'

// 使用默认的单例实例
const nodes = nodeManager.getNodeList()
console.log('可用节点:', nodes)

安装(优先使用 Yarn)

推荐使用 yarn 安装与运行(支持全局安装或作为项目依赖)。以下示例分别展示 yarnnpm 两种用法。

# 使用 Yarn 全局安装(可作为 CLI 使用,传统 yarn v1)
yarn global add renflow.runner

# 或在项目中作为依赖
yarn add renflow.runner

# 等价的 npm 命令(保留参考)
# npm install -g renflow.runner
# npm install --save renflow.runner

CLI 使用(安装后)

安装后会提供 renflow-runner 可执行器,示例:

# 使用本地 JSON 工作流文件直接执行并退出
renflow-runner ./examples/my-workflow.json

# 运行一个工作集包(.renflow/.rfw/.zip),并在触发后持续运行
renflow-runner ./my-bots-package.renflow

# 使用环境变量开启调试日志
RENFLOW_LOG=debug renflow-runner ./my-bots-package.renflow

自定义日志级别

import { createNodeManager, LogLevel } from 'renflow-runner'

// 创建自定义实例并设置日志级别
const manager = createNodeManager(LogLevel.DEBUG)

// 或者在运行时修改日志级别
nodeManager.setLogLevel(LogLevel.WARN)

日志级别说明

  • LogLevel.DEBUG (0) - 输出所有日志,包括调试信息
  • LogLevel.INFO (1) - 输出信息、警告和错误(默认级别)
  • LogLevel.WARN (2) - 仅输出警告和错误
  • LogLevel.ERROR (3) - 仅输出错误

开发

# 安装依赖
npm install

# 开发模式(带热重载)
npm run dev

# 构建
npm run build

# 运行构建后的代码
npm start

环境要求

  • Node.js >= 18.0.0
  • TypeScript

许可

MIT License - Copyright © Stapx Steve