Last active
June 1, 2025 04:36
-
-
Save wtnabe/776d97020aab1bf696c36c6c61b0a8d0 to your computer and use it in GitHub Desktop.
plantumlコマンドを-pipeで使う際の謎のエラーを可視化するwrapper script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
set -o pipefail | |
OUTPUT=$(plantuml "$@" 2>&1) | |
printf "%s" "$OUTPUT" | |
if printf "%s" "$OUTPUT" | grep -q 'java\.lang\.'; then | |
cat <<EOD >&2 | |
Did you write multiple diagrams in single file ? | |
PlantUML with -pipe option cannot accept multiple images ... | |
Or something wrong about some diagrams with txt type ... | |
EOD | |
fi | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment