Skip to content

Instantly share code, notes, and snippets.

@ford-prefect
Created January 16, 2023 14:41
Show Gist options
  • Save ford-prefect/bf2c06cd3b8b3ddd9b0c5585afc9670f to your computer and use it in GitHub Desktop.
Save ford-prefect/bf2c06cd3b8b3ddd9b0c5585afc9670f to your computer and use it in GitHub Desktop.
gstreamer dot file viewer
#!/bin/sh
set -e
if [ $# -ne 1 ]; then
echo "Require one argument (the dot file)"
exit 255
fi
tmpfile=$(mktemp "${1}.XXX")
tmpfilesvg="${tmpfile}.svg"
dot -T svg "${1}" > "${tmpfile}"
mv "${tmpfile}" "${tmpfilesvg}"
eog ${tmpfilesvg}
rm ${tmpfilesvg}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment