summaryrefslogtreecommitdiff
path: root/syntax.sh
blob: 2e0db5d33f05f4793f71bfa89e55e2641a1f3eab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/sh

# https://xyproto.github.io/splash/docs/all.html

LIGHT=trac
DARK=modus-vivendi
CSS=assets/css/syntax.css

cat << EOF > $CSS
.cmd-root .cl::before {
  color: #669900;
  font-weight: bold;
  user-select: none;
  content: "user $ ";
}
.cmd-root .cl::before {
  color: #ff3333;
  font-weight: bold;
  user-select: none;
  content: "root # ";
}
EOF

printf "\n/* Chroma style: %s */\n" $LIGHT >> $CSS
hugo gen chromastyles --style=$LIGHT >> $CSS
printf "\n\n/* Chroma style: %s */\n" $DARK >> $CSS
printf "@media (prefers-color-scheme: dark) {\n" >> $CSS
hugo gen chromastyles --style=$DARK >> $CSS
printf "}\n" >> $CSS