Commit d0d973beae5c49245b2f69df472505fa3ae1e29f
1 parent
33a283aa
Exists in
master
and in
29 other branches
ActionItem421: FBES Favicon and change-theme script
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@1921 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
2 changed files
with
31 additions
and
0 deletions
Show diff stats
No preview for this file type
@@ -0,0 +1,31 @@ | @@ -0,0 +1,31 @@ | ||
1 | +#!/bin/bash | ||
2 | + | ||
3 | +cd "$( dirname $0 )/../public/designs/themes/" | ||
4 | + | ||
5 | +test -L default && rm default | ||
6 | + | ||
7 | +echo 'Select Theme:' | ||
8 | +n=0 | ||
9 | +ls -1 | while read theme; do | ||
10 | + let n++ | ||
11 | + echo " [$n] $theme" | ||
12 | +done | ||
13 | + | ||
14 | +ok=false | ||
15 | +while ! [ -L default ]; do | ||
16 | + | ||
17 | + read t | ||
18 | + n=0 | ||
19 | + ls -1 | while read theme; do | ||
20 | + let n++ | ||
21 | + if [ "$t" = "$n" ]; then | ||
22 | + echo "Theme selected: $theme" | ||
23 | + ln -s "$theme" default | ||
24 | + fi | ||
25 | + done | ||
26 | + | ||
27 | + if ! [ -L default ]; then | ||
28 | + echo "Invalid number $t" | ||
29 | + fi | ||
30 | + | ||
31 | +done |