annotate compile-ui.sh @ 16:d211d01efa44

Re #242: Create Qt# UI for WarFoundry * Fix MonoDevelop's annoying auto-formatting * Remove debugging "true" from IF condition
author IBBoard <dev@ibboard.co.uk>
date Sat, 13 Feb 2010 19:45:08 +0000
parents 4ff09911ef64
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
1 #! /bin/bash
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
2
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
3 echo "Compiling .ui files to C#"
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
4
1
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
5 for uiFile in qt-gui/*.ui
0
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
6 do
1
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
7 csFile=${uiFile/.ui/.cs}
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
8
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
9 # Only update if file has changed
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
10 if test $uiFile -nt $csFile
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
11 then
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
12 echo -ne " * Compiling $uiFile..."
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
13 uics -o $csFile $uiFile
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
14 echo "...compiled."
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
15 else
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
16 echo " * Skipping $uiFile - no update needed"
4ff09911ef64 Re #242: Create Qt# UI for WarFoundry
IBBoard <dev@ibboard.co.uk>
parents: 0
diff changeset
17 fi
0
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
18 done
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
19
620c62ba4d07 Re #242: Qt# GUI
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
20 echo