Skip to content

Commit 575ca24

Browse files
committed
ci: verify tldr EXAMPLES section in man page output
1 parent bb3d8da commit 575ca24

1 file changed

Lines changed: 6 additions & 11 deletions

File tree

.github/workflows/documentation.yml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -122,15 +122,10 @@ jobs:
122122
123123
- name: Verify tldr examples integration
124124
run: |
125-
if [ ! -f "docs/src/utils/cp.md" ]; then
126-
echo "docs/src/utils/cp.md does not exist"
127-
exit 1
128-
fi
125+
grep -q "The examples are provided by" docs/src/utils/cp.md
129126
130-
if ! grep -q "The examples are provided by" docs/src/utils/cp.md; then
131-
echo "tldr examples integration missing from cp.md"
132-
echo "Expected to find 'The examples are provided by' text"
133-
echo "Content of cp.md:"
134-
tail -20 docs/src/utils/cp.md
135-
exit 1
136-
fi
127+
- name: Verify tldr examples appear in man page output
128+
run: |
129+
cargo run --bin uudoc --all-features -- manpage cp > /tmp/cp.1
130+
grep -q "\.SH EXAMPLES" /tmp/cp.1
131+
grep -q "tldr-pages" /tmp/cp.1

0 commit comments

Comments
 (0)