aboutsummaryrefslogtreecommitdiff
path: root/plugins/style/recompute_STYLE_N.sh
diff options
context:
space:
mode:
authorNunoSempere <nuno.sempere@protonmail.com>2023-02-05 03:21:30 +0100
committerNunoSempere <nuno.sempere@protonmail.com>2023-02-05 03:21:30 +0100
commit353d0ffad7c1810d2c5a87d73f6649bcbc55aad4 (patch)
tree5821596e151ae561c653a3ee5306651fbbf2c5d0 /plugins/style/recompute_STYLE_N.sh
parentbe043958f056264788cb92445890337b2674510c (diff)
feat: add plugin to customize css for individual websites...
and how to enable it. Also tweak README.mds
Diffstat (limited to 'plugins/style/recompute_STYLE_N.sh')
-rwxr-xr-xplugins/style/recompute_STYLE_N.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/plugins/style/recompute_STYLE_N.sh b/plugins/style/recompute_STYLE_N.sh
new file mode 100755
index 0000000..906aad8
--- /dev/null
+++ b/plugins/style/recompute_STYLE_N.sh
@@ -0,0 +1,8 @@
+#!/bin/bash
+function sedr(){
+ find ./ -type f -exec sed -i -e "$1" {} \;
+} ## e.g., sedr "s/target/replacement/g"
+
+STYLE_N=$(wc -c style.js | cut -d " " -f 1)
+sedr "s/^#define STYLE_N .*/#define STYLE_N $STYLE_N + 1/g"
+