ToolboxToolbox/DataForkToRez

11 lines
200 B
Plaintext
Raw Permalink Normal View History

2018-12-07 06:01:27 +00:00
#!/bin/sh
if [[ $# -lt 4 || $# -gt 5 ]]; then
echo "Usage: $0 IN OUT TYPE ID"
exit 1
fi
echo "data '$3' ($4, \"$5\") {" >> "$2"
xxd -p "$1" | sed s/^/\$\"/ | sed s/$/\"/ >> "$2"
echo "};" >> "$2"