summaryrefslogtreecommitdiff
path: root/themes/build-themes.sh
diff options
context:
space:
mode:
authormsquare <msquare@notrademark.de>2017-05-24 14:06:38 +0200
committerGitHub <noreply@github.com>2017-05-24 14:06:38 +0200
commit868780239f7a416017f1b31fab62032050a01681 (patch)
treee26c4aa3d72e710a2eebb308a72fed3a04e8b2ea /themes/build-themes.sh
parentff4d176341c52da4ea74364de153a20352c6a145 (diff)
parentbc91daedca5646bbc2786bd5c24152b4f723436e (diff)
Merge pull request #308 from MyIgel/themes
Themes: Moved bootstrap and improved generate script
Diffstat (limited to 'themes/build-themes.sh')
-rwxr-xr-xthemes/build-themes.sh20
1 files changed, 14 insertions, 6 deletions
diff --git a/themes/build-themes.sh b/themes/build-themes.sh
index 404b6890..8657b691 100755
--- a/themes/build-themes.sh
+++ b/themes/build-themes.sh
@@ -1,7 +1,15 @@
-#!/bin/sh
+#!/bin/bash
-lessc theme0.less > ../public/css/theme0.css
-lessc theme1.less > ../public/css/theme1.css
-lessc theme2.less > ../public/css/theme2.css
-lessc theme3.less > ../public/css/theme3.css
-lessc theme4.less > ../public/css/theme4.css
+FILE_PATH="$(dirname "$0")"
+
+for file in $(ls "${FILE_PATH}/"*.less); do
+ filename="${file##*/}"
+ themeName="${filename%.less}"
+
+ if [[ "$filename" == "base.less" ]]; then
+ continue;
+ fi
+
+ echo "Building ${themeName}"
+ lessc "${file}" > "${FILE_PATH}/../public/css/${themeName}.css"
+done