Skip to content

Commit 074353e

Browse files
MaxMa04claude
andcommitted
feat: rebrand as independent project, add npm + curl install
- Replace all 4ier/notion-cli references with MaxMa04/notion-agent-cli - Update README badges, demo GIF URL, and install section (7 methods) - Add npm wrapper package (@vibelabsio/notion-agent-cli) - Add curl/wget install script (install.sh) - Add npm publish step to release workflow - Update LICENSE copyright (both authors) - Fix binary name in Dockerfile, .gitignore, demo.tape - Add acknowledgements section crediting original project Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 5ae811e commit 074353e

16 files changed

Lines changed: 496 additions & 111 deletions

File tree

.github/workflows/release.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,18 @@ jobs:
4545
env:
4646
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4747
HOMEBREW_TAP_TOKEN: ${{ secrets.HOMEBREW_TAP_TOKEN }}
48+
49+
- name: Set up Node.js
50+
uses: actions/setup-node@v4
51+
with:
52+
node-version: 20
53+
registry-url: https://registry.npmjs.org
54+
55+
- name: Publish to npm
56+
working-directory: npm
57+
run: |
58+
VERSION=${GITHUB_REF_NAME#v}
59+
npm version "$VERSION" --no-git-tag-version --allow-same-version
60+
npm publish --access public
61+
env:
62+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Binary
2-
notion
2+
notion-agent
33

44
# OS
55
.DS_Store

DESIGN.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
# Notion CLI — Design Document
1+
# Notion Agent CLI — Design Document
22

33
> Build something worthy of standing next to `gh`.
44
5+
> **Note:** The binary was renamed from `notion` to `notion-agent` in v0.3. Command examples below may still reference the old name.
6+
57
## Philosophy
68

79
1. **Commands map to concepts, not API endpoints.** Users think in pages, databases, blocks — not HTTP verbs.

DISTRIBUTION.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@
77
| 渠道 | 目标用户 | 实现方式 | 工作量 |
88
|------|---------|---------|--------|
99
| **GitHub Releases** | 所有平台 | goreleaser + GitHub Actions | 1h |
10-
| **go install** | Go 开发者 | 已就绪(`go install github.com/4ier/notion-cli@latest`| 0 |
11-
| **Homebrew Tap** | macOS/Linux 开发者 | goreleaser 自动生成 formula → `4ier/homebrew-tap` | 30min |
10+
| **go install** | Go 开发者 | 已就绪(`go install github.com/MaxMa04/notion-agent-cli@latest`| 0 |
11+
| **Homebrew Tap** | macOS/Linux 开发者 | goreleaser 自动生成 formula → `MaxMa04/homebrew-tap` | 30min |
1212

1313
### Tier 2 — 应该做(扩大覆盖)
1414

1515
| 渠道 | 目标用户 | 实现方式 | 工作量 |
1616
|------|---------|---------|--------|
17-
| **npm wrapper** | Node.js/agent 生态 | 轻量 npm 包 `@4ier/notion-cli`,postinstall 拉二进制 | 2h |
18-
| **Docker** | CI/CD/自动化 | `ghcr.io/4ier/notion-cli` | 30min |
17+
| **npm wrapper** | Node.js/agent 生态 | 轻量 npm 包 `@vibelabsio/notion-agent-cli`,postinstall 拉二进制 | 2h |
18+
| **Docker** | CI/CD/自动化 | `ghcr.io/MaxMa04/notion-agent-cli` | 30min |
1919
| **Scoop** | Windows | goreleaser 内置 scoop manifest | 15min |
2020

2121
### Tier 3 — 锦上添花(长尾)
@@ -37,8 +37,8 @@
3737
├── builds: linux/darwin/windows × amd64/arm64
3838
├── archives: tar.gz (unix) / zip (windows)
3939
├── checksum: SHA256
40-
├── homebrew_formulas: 4ier/homebrew-tap
41-
├── scoop: 4ier/scoop-bucket
40+
├── homebrew_formulas: MaxMa04/homebrew-tap
41+
├── scoop: MaxMa04/scoop-bucket
4242
└── changelog: auto from git
4343
4444
.github/workflows/release.yml
@@ -51,21 +51,21 @@
5151
**执行步骤:**
5252
1. 创建 `.goreleaser.yaml`
5353
2. 创建 `.github/workflows/release.yml` + `.github/workflows/test.yml`
54-
3. 创建 `4ier/homebrew-tap``4ier/scoop-bucket` 仓库
54+
3. 创建 `MaxMa04/homebrew-tap``MaxMa04/scoop-bucket` 仓库
5555
4. 打 tag `v0.2.0`,推送触发自动发布
56-
5. 验证: `brew install 4ier/tap/notion-cli`
56+
5. 验证: `brew install MaxMa04/tap/notion-agent-cli`
5757

5858
### Phase 2: npm wrapper(本周)
5959

6060
```
61-
notion-cli-npm/
62-
├── package.json # name: @4ier/notion-cli
61+
notion-agent-cli-npm/
62+
├── package.json # name: @vibelabsio/notion-agent-cli
6363
├── install.js # postinstall: 检测平台 → 下载对应 GitHub Release 二进制
6464
├── bin/notion # shell wrapper → 执行下载的二进制
6565
└── README.md
6666
```
6767

68-
用户体验: `npx @4ier/notion-cli search "meeting notes"`
68+
用户体验: `npx @vibelabsio/notion-agent-cli search "meeting notes"`
6969

7070
### Phase 3: Docker(本周)
7171

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
FROM alpine:3.21
22
RUN apk add --no-cache ca-certificates
3-
COPY notion /usr/local/bin/notion
4-
ENTRYPOINT ["notion"]
3+
COPY notion-agent /usr/local/bin/notion-agent
4+
ENTRYPOINT ["notion-agent"]

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2026 Fourier
3+
Copyright (c) 2026 Fourier, 2026 Max Mannstein
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 35 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@
77
</p>
88

99
<p align="center">
10-
<img src="https://github.com/4ier/notion-cli/releases/download/v0.2.0/demo.gif" alt="demo" width="640">
10+
<img src="https://raw.githubusercontent.com/MaxMa04/notion-agent-cli/main/demo.gif" alt="demo" width="640">
1111
</p>
1212

1313
<p align="center">
14-
<a href="https://github.com/4ier/notion-cli/releases"><img src="https://img.shields.io/github/v/release/4ier/notion-cli?style=flat-square" alt="Release"></a>
15-
<a href="https://github.com/4ier/notion-cli/actions"><img src="https://img.shields.io/github/actions/workflow/status/4ier/notion-cli/test.yml?style=flat-square&label=tests" alt="Tests"></a>
16-
<a href="https://github.com/4ier/notion-cli/blob/main/LICENSE"><img src="https://img.shields.io/github/license/4ier/notion-cli?style=flat-square" alt="License"></a>
17-
<a href="https://goreportcard.com/report/github.com/4ier/notion-cli"><img src="https://goreportcard.com/badge/github.com/4ier/notion-cli?style=flat-square" alt="Go Report Card"></a>
14+
<a href="https://github.com/MaxMa04/notion-agent-cli/releases"><img src="https://img.shields.io/github/v/release/MaxMa04/notion-agent-cli?style=flat-square" alt="Release"></a>
15+
<a href="https://github.com/MaxMa04/notion-agent-cli/actions"><img src="https://img.shields.io/github/actions/workflow/status/MaxMa04/notion-agent-cli/test.yml?style=flat-square&label=tests" alt="Tests"></a>
16+
<a href="https://github.com/MaxMa04/notion-agent-cli/blob/main/LICENSE"><img src="https://img.shields.io/github/license/MaxMa04/notion-agent-cli?style=flat-square" alt="License"></a>
17+
<a href="https://goreportcard.com/report/github.com/MaxMa04/notion-agent-cli"><img src="https://goreportcard.com/badge/github.com/MaxMa04/notion-agent-cli?style=flat-square" alt="Go Report Card"></a>
1818
</p>
1919

2020
---
@@ -23,11 +23,37 @@ A full-featured command-line interface for [Notion](https://notion.so). Manage p
2323

2424
## Install
2525

26+
### Homebrew (macOS / Linux)
27+
```sh
28+
brew install MaxMa04/tap/notion-agent-cli
29+
```
30+
31+
### npm (cross-platform)
32+
```sh
33+
npm install -g @vibelabsio/notion-agent-cli
34+
```
35+
36+
### Shell Script (Linux / macOS)
37+
```sh
38+
curl -fsSL https://raw.githubusercontent.com/MaxMa04/notion-agent-cli/main/install.sh | sh
39+
```
40+
41+
### Scoop (Windows)
42+
```sh
43+
scoop bucket add maxma04 https://github.com/MaxMa04/scoop-bucket
44+
scoop install notion-agent-cli
45+
```
46+
2647
### Go
2748
```sh
2849
go install github.com/MaxMa04/notion-agent-cli@latest
2950
```
3051

52+
### Docker
53+
```sh
54+
docker run --rm ghcr.io/maxma04/notion-agent-cli:latest search "query"
55+
```
56+
3157
### Binary
3258

3359
Download from [GitHub Releases](https://github.com/MaxMa04/notion-agent-cli/releases) — available for Linux, macOS, and Windows (amd64/arm64).
@@ -235,6 +261,10 @@ notion-agent auth switch work
235261
notion-agent auth logout work
236262
```
237263

264+
## Acknowledgements
265+
266+
This project is based on [notion-cli](https://github.com/4ier/notion-cli) by [4ier](https://github.com/4ier).
267+
238268
## Contributing
239269

240270
Issues and PRs welcome at [github.com/MaxMa04/notion-agent-cli](https://github.com/MaxMa04/notion-agent-cli).

demo.tape

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# demo.tape — notion-cli demo GIF
1+
# demo.tape — notion-agent-cli demo GIF
22
Output demo.gif
33
Set Theme "Catppuccin Mocha"
44
Set FontFamily "JetBrains Mono"
@@ -11,32 +11,32 @@ Set Shell "bash"
1111

1212
# Build first (hidden)
1313
Hide
14-
Type "cd ~/clawd/earn/notion-cli && export PATH=$PWD:$PATH"
14+
Type "export PATH=$PWD:$PATH"
1515
Enter
1616
Sleep 500ms
1717
Show
1818

1919
# Main help
20-
Type "notion"
20+
Type "notion-agent"
2121
Enter
2222
Sleep 3s
2323

2424
# Database query help — shows filter syntax
25-
Type "notion db query --help"
25+
Type "notion-agent db query --help"
2626
Enter
2727
Sleep 4s
2828

2929
# Page commands
30-
Type "notion page --help"
30+
Type "notion-agent page --help"
3131
Enter
3232
Sleep 3s
3333

3434
# Block commands
35-
Type "notion block --help"
35+
Type "notion-agent block --help"
3636
Enter
3737
Sleep 3s
3838

3939
# Version
40-
Type "notion --version"
40+
Type "notion-agent --version"
4141
Enter
4242
Sleep 2s

install.sh

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
#!/bin/sh
2+
set -e
3+
4+
REPO="MaxMa04/notion-agent-cli"
5+
BINARY="notion-agent"
6+
7+
# Detect OS
8+
OS=$(uname -s | tr '[:upper:]' '[:lower:]')
9+
case "$OS" in
10+
linux) OS="linux" ;;
11+
darwin) OS="darwin" ;;
12+
*)
13+
echo "Error: Unsupported OS: $OS"
14+
echo "Please download manually from https://github.com/${REPO}/releases"
15+
exit 1
16+
;;
17+
esac
18+
19+
# Detect architecture
20+
ARCH=$(uname -m)
21+
case "$ARCH" in
22+
x86_64|amd64) ARCH="amd64" ;;
23+
arm64|aarch64) ARCH="arm64" ;;
24+
*)
25+
echo "Error: Unsupported architecture: $ARCH"
26+
echo "Please download manually from https://github.com/${REPO}/releases"
27+
exit 1
28+
;;
29+
esac
30+
31+
# Get latest version
32+
echo "Fetching latest version..."
33+
if command -v curl > /dev/null 2>&1; then
34+
VERSION=$(curl -fsSL "https://api.github.com/repos/${REPO}/releases/latest" | grep '"tag_name"' | sed 's/.*"v\(.*\)".*/\1/')
35+
elif command -v wget > /dev/null 2>&1; then
36+
VERSION=$(wget -qO- "https://api.github.com/repos/${REPO}/releases/latest" | grep '"tag_name"' | sed 's/.*"v\(.*\)".*/\1/')
37+
else
38+
echo "Error: Neither curl nor wget found. Please install one of them."
39+
exit 1
40+
fi
41+
42+
if [ -z "$VERSION" ]; then
43+
echo "Error: Could not determine latest version."
44+
echo "Please download manually from https://github.com/${REPO}/releases"
45+
exit 1
46+
fi
47+
48+
# Construct download URL
49+
FILENAME="${BINARY}-cli_${VERSION}_${OS}_${ARCH}.tar.gz"
50+
URL="https://github.com/${REPO}/releases/download/v${VERSION}/${FILENAME}"
51+
52+
# Determine install directory
53+
INSTALL_DIR="${INSTALL_DIR:-/usr/local/bin}"
54+
55+
echo "Installing ${BINARY} v${VERSION} for ${OS}/${ARCH}..."
56+
echo " From: ${URL}"
57+
echo " To: ${INSTALL_DIR}/${BINARY}"
58+
59+
# Create temp directory
60+
TMPDIR=$(mktemp -d)
61+
trap 'rm -rf "$TMPDIR"' EXIT
62+
63+
# Download
64+
if command -v curl > /dev/null 2>&1; then
65+
curl -fsSL "$URL" -o "$TMPDIR/archive.tar.gz"
66+
else
67+
wget -qO "$TMPDIR/archive.tar.gz" "$URL"
68+
fi
69+
70+
# Extract
71+
tar xzf "$TMPDIR/archive.tar.gz" -C "$TMPDIR"
72+
73+
# Install
74+
if [ -w "$INSTALL_DIR" ]; then
75+
install -m 755 "$TMPDIR/${BINARY}" "$INSTALL_DIR/${BINARY}"
76+
else
77+
echo "Note: ${INSTALL_DIR} requires elevated permissions."
78+
sudo install -m 755 "$TMPDIR/${BINARY}" "$INSTALL_DIR/${BINARY}"
79+
fi
80+
81+
echo ""
82+
echo "${BINARY} v${VERSION} installed successfully!"
83+
"${INSTALL_DIR}/${BINARY}" --version 2>/dev/null || true

launch-materials.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ Hey r/Notion! I built **notion-cli** — a command-line tool that gives you comp
2222

2323
**Install:**
2424
```
25-
brew install 4ier/tap/notion-cli # macOS/Linux
26-
scoop bucket add 4ier https://github.com/4ier/scoop-bucket && scoop install notion-cli # Windows
27-
npm install -g @4ier/notion-cli # npm
28-
go install github.com/4ier/notion-cli@latest # Go
25+
brew install MaxMa04/tap/notion-agent-cli # macOS/Linux
26+
scoop bucket add MaxMa04 https://github.com/MaxMa04/scoop-bucket && scoop install notion-agent-cli # Windows
27+
npm install -g @vibelabsio/notion-agent-cli # npm
28+
go install github.com/MaxMa04/notion-agent-cli@latest # Go
2929
```
3030

3131
**Quick example:**
@@ -35,7 +35,7 @@ notion page create <db-id> --db "Name=Weekly Review" "Status=Todo"
3535
notion block list <page-id> --md --depth 3
3636
```
3737

38-
GitHub: https://github.com/4ier/notion-cli
38+
GitHub: https://github.com/MaxMa04/notion-agent-cli
3939

4040
Feedback welcome — what commands would you use most?
4141

@@ -58,17 +58,17 @@ Highlights for the CLI crowd:
5858

5959
Particularly useful for scripting and AI agents that need to interact with Notion workspaces.
6060

61-
`brew install 4ier/tap/notion-cli`
61+
`brew install MaxMa04/tap/notion-agent-cli`
6262

63-
GitHub: https://github.com/4ier/notion-cli
63+
GitHub: https://github.com/MaxMa04/notion-agent-cli
6464

6565
---
6666

6767
## Hacker News Post
6868

6969
**Title:** Show HN: Notion-CLI – Full Notion API from the terminal, 39 commands, one binary
7070

71-
**URL:** https://github.com/4ier/notion-cli
71+
**URL:** https://github.com/MaxMa04/notion-agent-cli
7272

7373
---
7474

@@ -83,7 +83,7 @@ Human-friendly filters, Markdown I/O, schema-aware page creation, pipe-friendly
8383

8484
Built for developers and AI agents.
8585

86-
github.com/4ier/notion-cli
86+
github.com/MaxMa04/notion-agent-cli
8787

8888
---
8989

0 commit comments

Comments
 (0)