Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions plugins/notion-cli/install-guidance.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
"binary": "notion",
"check": "which notion",
"install_steps": [
"brew install 4ier/tap/notion-cli",
"go install github.com/4ier/notion-cli@latest",
"GOBIN=$(go env GOBIN); GOPATH=$(go env GOPATH); ln -sf \"${GOBIN:-$GOPATH/bin}/notion-cli\" \"${GOBIN:-$GOPATH/bin}/notion\"",
Comment on lines +6 to +7

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Files:\n'
for f in \
  plugins/notion-cli/install-guidance.json \
  plugins/notion-cli/plugin.json \
  plugins/notion-cli/skills/quickstart/SKILL.md
do
  if [ -f "$f" ]; then
    printf '%s: %s bytes, %s lines\n' "$f" "$(wc -c < "$f")" "$(wc -l < "$f")"
  else
    printf '%s: MISSING\n' "$f"
  fi
done

printf '\nRelevant install guidance/plugin references:\n'
for f in plugins/notion-cli/install-guidance.json plugins/notion-cli/plugin.json plugins/notion-cli/skills/quickstart/SKILL.md; do
  if [ -f "$f" ]; then
    printf '\n--- %s ---\n' "$f"
    rg -n 'notion|^PATH|GOBIN|GOPATH|command|missingDependencyHelp' "$f" -C 2 || true
  fi
done

printf '\nSearch for notion command declaration:\n'
rg -n '"command"[[:space:]]*:[[:space:]]*"notion"|notion-cli|notion' plugins/notion-cli -C 2 || true

printf '\nCheck sc-zig availability:\n'
command -v sc-zig || true
if command -v sc-zig >/dev/null 2>&1; then
  sc-zig --json 2>&1 | python3 - <<'PY'
import json, sys
data=json.load(sys.stdin)
print(type(data).__name__, bool(data) if isinstance(data, (dict,list)) else repr(data))
PY
fi

Repository: javimosch/supercli

Length of output: 31679


🌐 Web query:

Go command go install default GOBIN GO111MODULE documentation GOPATH/bin

💡 Result:

The go install command compiles and installs Go programs (executables) [1][2]. Its installation behavior is governed by environment variables and Go's module-aware mode [1][3]. Installation Directory and GOBIN The location where go install places compiled binaries is determined by the GOBIN environment variable [3][4]. 1. If GOBIN is set, binaries are installed to that absolute path [5][6]. 2. If GOBIN is not set, binaries are installed to the bin subdirectory of the default GOPATH [1][3]. The default GOPATH is $HOME/go on Unix-like systems and %USERPROFILE%\go on Windows [3][4]. 3. Executables in GOROOT are installed to GOROOT/bin or GOTOOLDIR, rather than GOBIN [1][2]. GO111MODULE and Module-Aware Mode The GO111MODULE environment variable controls whether the go command runs in module-aware mode or GOPATH mode [7][8]. - When GO111MODULE=on (or unset in modern Go versions), the go command runs in module-aware mode [7]. - When GO111MODULE=off, the go command runs in GOPATH mode, relying on the GOPATH structure [7]. - When arguments to go install include version suffixes (e.g., @latest), the command automatically runs in module-aware mode and ignores any go.mod file in the current directory [1][9]. In summary, for most modern Go development, module-aware mode is the standard [7]. When you execute go install, the resulting binary is placed in $GOBIN if set, or $GOPATH/bin by default [1][4]. Adding this directory to your PATH environment variable allows you to run the installed commands directly [3][5].

Citations:


Ensure the Go install path creates a discoverable notion command.

go install writes notion-cli to $GOBIN or $GOPATH/bin, and the manifest/checks expect notion, but the Go install steps only link the binary and do not make that directory searchable. Add a persistent PATH addition after creating the notion symlink/link, and keep the inline guidance and recovery messages consistent with the dedicated install guidance.

  • plugins/notion-cli/install-guidance.json#L6-L7
  • plugins/notion-cli/plugin.json#L13-L15
  • plugins/notion-cli/plugin.json#L34
  • plugins/notion-cli/plugin.json#L234
  • plugins/notion-cli/skills/quickstart/SKILL.md#L61-L66
📍 Affects 3 files
  • plugins/notion-cli/install-guidance.json#L6-L7 (this comment)
  • plugins/notion-cli/plugin.json#L13-L15
  • plugins/notion-cli/plugin.json#L34-L34
  • plugins/notion-cli/plugin.json#L234-L234
  • plugins/notion-cli/skills/quickstart/SKILL.md#L61-L66
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/notion-cli/install-guidance.json` around lines 6 - 7, Update the Go
installation guidance to persistently add the resolved GOBIN/GOPATH bin
directory to PATH after creating the notion symlink, ensuring the notion command
is discoverable. Apply the same install and recovery guidance consistently in
plugins/notion-cli/install-guidance.json lines 6-7,
plugins/notion-cli/plugin.json lines 13-15, 34, and 234, and
plugins/notion-cli/skills/quickstart/SKILL.md lines 61-66; preserve the existing
inline guidance while aligning its PATH instructions with the dedicated install
guidance.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== candidate files =="
git ls-files | rg '(^|/)plugins/notion-cli/(plugin\.json|install-guidance\.json)$|meta\.json|schema' || true

echo
echo "== notion-cli files =="
for f in plugins/notion-cli/plugin.json plugins/notion-cli/install-guidance.json; do
  if [ -f "$f" ]; then
    echo "--- $f ($(wc -l < "$f") lines) ---"
    cat -n "$f"
  fi
done

echo
echo "== search for platform-conditioned guidance fields =="
rg -n '"installGuidance"|"instructions"|"install_guidance"|"platform|windows|powershell|scoop|ln -sf' plugins/notion-cli .github . -g 'plugins/*/**' || true

Repository: javimosch/supercli

Length of output: 50375


🏁 Script executed:

#!/bin/bash
set -euo pipefail

python3 - <<'PY'
import json
from pathlib import Path

for fp in ["plugins/notion-cli/plugin.json", "plugins/notion-cli/install-guidance.json"]:
    p = Path(fp)
    print(f"== {fp} ==")
    data = json.loads(p.read_text())
    def walk(x, path=""):
        if isinstance(x, dict):
            for k, v in x.items():
                walk(v, f"{path}.{k}" if path else k)
    walk(data)
    print(json.dumps(data, indent=2))
PY

echo
echo "== schema references for install guidance keys =="
git ls-files | rg '(^|/)(meta|plugin|install-guidance).*\.json$|install' || true

Repository: javimosch/supercli

Length of output: 50374


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== focused notion-cli files =="
for f in plugins/notion-cli/plugin.json plugins/notion-cli/install-guidance.json; do
  echo "--- $f ---"
  cat -n "$f"
done

echo
echo "== focused search in notion-cli =="
rg -n '"install_guidance"|"installGuidance"|"ln -sf"|platform|windows|powershell|scoop|note' plugins/notion-cli || true

echo
echo "== focused search for platform keys in plugin install guidance =="
python3 - <<'PY'
import json, pathlib
for p in pathlib.Path("plugins").glob("*"):
    if not p.is_dir() or p.name.startswith("."):
        continue
    for f in p.glob("plugin.json"):
        try:
            data = json.loads(f.read_text())
        except Exception:
            continue
        ig = data.get("install_guidance", {})
        meta = data.get("meta", {})
        if isinstance(ig, dict) and any(k in ig for k in ["platforms","platform","windows","powershell","scoop","command","install_steps","windows_steps","pwsh","note"]):
            print(f)
            print(json.dumps({"install_guidance": ig, "meta": meta}, indent=2))
PY

Repository: javimosch/supercli

Length of output: 50374


Separate Unix and Windows installation instructions.

Both guidance entries expose only POSIX install steps, including ln -sf, so Windows users can run instructions that fail. Add Windows PowerShell/Scoop steps, or scope these install steps as Unix-only in both plugins/notion-cli/install-guidance.json and the inline plugin.json guidance.

📍 Affects 2 files
  • plugins/notion-cli/install-guidance.json#L7-L7 (this comment)
  • plugins/notion-cli/plugin.json#L15-L15
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/notion-cli/install-guidance.json` at line 7, Separate the POSIX-only
install guidance from Windows instructions in both
plugins/notion-cli/install-guidance.json (line 7) and
plugins/notion-cli/plugin.json (line 15). Either add Windows PowerShell/Scoop
installation steps or explicitly label the existing ln -sf commands as Unix-only
in both guidance entries.

"Verify: notion --version",
"Authenticate: echo 'ntn_xxxxx' | notion auth login --with-token",
"Alternative auth: export NOTION_TOKEN=ntn_xxxxx",
"supercli plugins install ./plugins/notion-cli --on-conflict replace --json"
],
"note": "Also available as Go binary from GitHub Releases: https://github.com/4ier/notion-cli/releases. npm: npm install -g @4ier/notion-cli. Token stored in ~/.config/notion-cli/config.json (mode 0600). Auto-detects JSON output when piped to another command."
"note": "Primary install is `go install github.com/4ier/notion-cli@latest`, which builds a binary named `notion-cli`. Link or rename it to `notion` before the `Verify` step. Also available via Homebrew (`brew install 4ier/tap/notion-cli`), npm (`npm install -g @4ier/notion-cli`), GitHub Releases (https://github.com/4ier/notion-cli/releases), or Scoop on Windows. Token stored in ~/.config/notion-cli/config.json (mode 0600). Auto-detects JSON output when piped to another command."
}
7 changes: 4 additions & 3 deletions plugins/notion-cli/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"binary": "notion",
"check": "which notion",
"install_steps": [
"brew install 4ier/tap/notion-cli",
"go install github.com/4ier/notion-cli@latest",
"GOBIN=$(go env GOBIN); GOPATH=$(go env GOPATH); ln -sf \"${GOBIN:-$GOPATH/bin}/notion-cli\" \"${GOBIN:-$GOPATH/bin}/notion\"",
"Verify: notion --version",
"Authenticate: echo 'ntn_xxxxx' | notion auth login --with-token",
"supercli plugins install ./plugins/notion-cli --on-conflict replace --json"
Expand All @@ -30,7 +31,7 @@
"adapterConfig": {
"command": "notion",
"baseArgs": ["--version"],
"missingDependencyHelp": "Install notion-cli: brew install 4ier/tap/notion-cli"
"missingDependencyHelp": "Install notion-cli: go install github.com/4ier/notion-cli@latest (the binary will be named notion-cli; symlink or rename it to notion) or brew install 4ier/tap/notion-cli"
},
"args": []
},
Expand Down Expand Up @@ -230,7 +231,7 @@
"adapterConfig": {
"command": "notion",
"passthrough": true,
"missingDependencyHelp": "Install notion-cli: brew install 4ier/tap/notion-cli. Authenticate: echo 'ntn_xxxx' | notion auth login --with-token"
"missingDependencyHelp": "Install notion-cli: go install github.com/4ier/notion-cli@latest (the binary will be named notion-cli; symlink or rename it to notion) or brew install 4ier/tap/notion-cli. Authenticate: echo 'ntn_xxxx' | notion auth login --with-token"
},
"args": []
}
Expand Down
17 changes: 16 additions & 1 deletion plugins/notion-cli/skills/quickstart/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,26 @@ export NOTION_TOKEN=ntn_xxxxx

## Installation

`go install` builds the binary as `notion-cli`; symlink it as `notion` so the plugin commands work:

```bash
go install github.com/4ier/notion-cli@latest
GOBIN=$(go env GOBIN); GOPATH=$(go env GOPATH); ln -sf "${GOBIN:-$GOPATH/bin}/notion-cli" "${GOBIN:-$GOPATH/bin}/notion"
```

Or install with Homebrew:

```bash
brew install 4ier/tap/notion-cli
```

Or download binary from [GitHub Releases](https://github.com/4ier/notion-cli/releases).
Or install with npm:

```bash
npm install -g @4ier/notion-cli
```

Or download a binary from [GitHub Releases](https://github.com/4ier/notion-cli/releases).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Tracked file:"
git ls-files | rg '(^|/)plugins/notion-cli/skills/quickstart/SKILL\.md$' || true

echo
echo "Relevant SKILL.md excerpt:"
if [ -f plugins/notion-cli/skills/quickstart/SKILL.md ]; then
  nl -ba plugins/notion-cli/skills/quickstart/SKILL.md | sed -n '1,130p'
fi

echo
echo "Search for 'GitHub Releases' and installation guidance in notion-cli:"
rg -n "Release|releases|DOWNLOAD|download|make \\+a|chmod \\+x|notion|PATH|brew|Linux|macOS|Windows" plugins/notion-cli || true

Repository: javimosch/supercli

Length of output: 285


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "File:"
printf '%s\n' plugins/notion-cli/skills/quickstart/SKILL.md > /tmp/skill_markdown.txt
wc -l /tmp/skill_markdown.txt

echo
echo "Lines 1-140:"
python3 - <<'PY'
from pathlib import Path
p=Path('plugins/notion-cli/skills/quickstart/SKILL.md')
for i,line in enumerate(p.read_text().splitlines(),1):
    if i <= 140:
        print(f'{i:4d}\t{line}')
PY

echo
echo "Installation-related terms:"
python3 - <<'PY'
from pathlib import Path
p=Path('plugins/notion-cli/skills/quickstart/SKILL.md')
terms=['Release','release','DOWNLOAD','download','chmod','notion','PATH','brew','Linux','macOS','Windows']
for i,line in enumerate(p.read_text().splitlines(),1):
    if any(t in line for t in terms):
        print(f'{i}\t{line}')
PY

echo
echo "Related files under plugins/notion-cli:"
python3 - <<'PY'
from pathlib import Path
root=Path('plugins/notion-cli')
for p in sorted(root.rglob('*')):
    if p.is_file() and not ('node_modules' in str(p) or '.git' in str(p)):
        print(p)
PY

Repository: javimosch/supercli

Length of output: 5134


Complete the GitHub Releases installation path.

Line 80 gives a release list link but does not say which platform asset to download, make executable, name notion, or install to PATH. Add those binary installation steps or link to platform-specific instructions.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/notion-cli/skills/quickstart/SKILL.md` at line 80, Complete the
GitHub Releases installation guidance in SKILL.md by updating the GitHub
Releases link text to point users to the correct platform-specific binary asset
and the required follow-up steps. Add the missing install flow for the
quickstart path: download the appropriate binary, make it executable, name it
notion, and place it on PATH, or replace this line with a clear pointer to
platform-specific installation instructions. Keep the existing quickstart
structure intact and anchor the change to the GitHub Releases download step.


## Key Features
- **Agent-friendly**: JSON output auto-detected when piped, schema-aware, URL or ID support
Expand Down
Loading