Add version command, bump to 0.2.2
This commit is contained in:
parent
ab890dfac0
commit
b794ad1370
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@canghe_ai/wechat-cli-darwin-arm64",
|
"name": "@canghe_ai/wechat-cli-darwin-arm64",
|
||||||
"version": "0.2.1",
|
"version": "0.2.2",
|
||||||
"description": "wechat-cli binary for macOS arm64",
|
"description": "wechat-cli binary for macOS arm64",
|
||||||
"os": ["darwin"],
|
"os": ["darwin"],
|
||||||
"cpu": ["arm64"],
|
"cpu": ["arm64"],
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@canghe_ai/wechat-cli",
|
"name": "@canghe_ai/wechat-cli",
|
||||||
"version": "0.2.1",
|
"version": "0.2.2",
|
||||||
"description": "WeChat data query CLI — chat history, contacts, sessions, favorites, and more. Designed for LLM integration.",
|
"description": "WeChat data query CLI — chat history, contacts, sessions, favorites, and more. Designed for LLM integration.",
|
||||||
"bin": {
|
"bin": {
|
||||||
"wechat-cli": "bin/wechat-cli.js"
|
"wechat-cli": "bin/wechat-cli.js"
|
||||||
@ -13,7 +13,7 @@
|
|||||||
"install.js"
|
"install.js"
|
||||||
],
|
],
|
||||||
"optionalDependencies": {
|
"optionalDependencies": {
|
||||||
"@canghe_ai/wechat-cli-darwin-arm64": "0.2.1"
|
"@canghe_ai/wechat-cli-darwin-arm64": "0.2.2"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=14"
|
"node": ">=14"
|
||||||
|
|||||||
@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "wechat-cli"
|
name = "wechat-cli"
|
||||||
version = "0.2.1"
|
version = "0.2.2"
|
||||||
description = "WeChat data query CLI for LLMs"
|
description = "WeChat data query CLI for LLMs"
|
||||||
requires-python = ">=3.10"
|
requires-python = ">=3.10"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
|||||||
@ -6,8 +6,11 @@ import click
|
|||||||
|
|
||||||
from .core.context import AppContext
|
from .core.context import AppContext
|
||||||
|
|
||||||
|
_VERSION = "0.2.2"
|
||||||
|
|
||||||
|
|
||||||
@click.group()
|
@click.group()
|
||||||
|
@click.version_option(version=_VERSION, prog_name="wechat-cli")
|
||||||
@click.option("--config", "config_path", default=None, envvar="WECHAT_CLI_CONFIG",
|
@click.option("--config", "config_path", default=None, envvar="WECHAT_CLI_CONFIG",
|
||||||
help="config.json 路径(默认自动查找)")
|
help="config.json 路径(默认自动查找)")
|
||||||
@click.pass_context
|
@click.pass_context
|
||||||
@ -26,8 +29,8 @@ def cli(ctx, config_path):
|
|||||||
wechat-cli contacts --query "李" # 搜索联系人
|
wechat-cli contacts --query "李" # 搜索联系人
|
||||||
wechat-cli new-messages # 获取增量新消息
|
wechat-cli new-messages # 获取增量新消息
|
||||||
"""
|
"""
|
||||||
# init 命令不需要 AppContext
|
# init/version 命令不需要 AppContext
|
||||||
if ctx.invoked_subcommand == "init":
|
if ctx.invoked_subcommand in ("init", "version"):
|
||||||
return
|
return
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user