11 lines
273 B
Bash
Executable File
11 lines
273 B
Bash
Executable File
#!/bin/sh
|
|
input=$(cat -)
|
|
input="${input#v run src/}"
|
|
style="<style>$(cat styles.css)</style>"
|
|
start="<html><head><title>TypoML Preview</title>$style</head><body>"
|
|
end="</body></html>"
|
|
output="$start$input$end"
|
|
echo "$output" > /tmp/preview.html
|
|
xdg-open /tmp/preview.html
|
|
|