12 lines
301 B
Bash
12 lines
301 B
Bash
#!/bin/bash
|
|
|
|
STOPWORD="${1}"
|
|
FILE=$(mktemp)
|
|
TMPFILE=$(mktemp)
|
|
|
|
cat takeup.scad | grep -e "${STOPWORD} ==" | awk -F'== "' '{print $2}' | awk -F'"' '{print $1}' > ${TMPFILE}
|
|
cat ${TMPFILE} | sed 's/^/.\/stl\/takeup_/' | sed 's/$/.stl/' > ${FILE}
|
|
|
|
rm -f ${TMPFILE}
|
|
cat ${FILE} | tr '\n' ' '
|
|
rm -f ${FILE} |