rtk-ai/rtk

rtk git commit hides post-commit hook output

Open

#1.355 aberto em 17 de abr. de 2026

Ver no GitHub
 (1 comment) (0 reactions) (0 assignees)Rust (2.914 forks)batch import
area:clibugeffort-smallfilter-qualitygood first issueneeds-reproductionpriority:medium

Métricas do repositório

Stars
 (48.085 stars)
Métricas de merge de PR
 (Mesclagem média 11d 1h) (45 fundiu PRs em 30d)

Description

When running git commit through rtk, output produced by a Git post-commit hook is not shown.

Minimal reproduction:

tmp=$(mktemp -d)
cd "$tmp"

git init -q
git config user.email test@example.com
git config user.name Tester

mkdir -p .git/hooks
cat > .git/hooks/post-commit <<'EOF'
#!/bin/sh
echo HOOK_STDOUT_visible
echo HOOK_STDERR_visible >&2
EOF
chmod +x .git/hooks/post-commit

printf "one\n" > f.txt
git add f.txt
git commit -m native

printf "two\n" >> f.txt
git add f.txt
rtk git commit -m rtk

Expected behavior:

rtk git commit should show the output produced by the post-commit hook, similar to native git commit.

Native git commit output includes:

HOOK_STDOUT_visible
HOOK_STDERR_visible
[main ...] native

Actual behavior:

rtk git commit only prints the compact success output:

ok

The hook output is not visible. This makes hook-generated messages easy to miss, including post-commit notices, validation summaries, local workflow hints, or follow-up instructions.

Guia do colaborador