A fork of the Materia GTK theme.

Important information: Google announced that, from September 2026, Android devices will require ALL apps to be signed by Google, effectively leading to an iOS situation. Value your right to a computer that does what you want; do not tolerate this monopolistic practice! Contact me if you don't understand why it is bad. Click to learn more.

 install.sh

View raw Download
text/x-shellscript • 4.48 kiB
Bourne-Again shell script, ASCII text executable
        
            
1
#!/bin/bash
2
3
repodir=$(cd $(dirname $0) && pwd)
4
srcdir=${repodir}/src
5
6
if test -z "$gnomever" ; then
7
if type -p gnome-shell > /dev/null ; then
8
gnomever=$(gnome-shell --version | cut -d ' ' -f 3 | cut -d . -f -2)
9
else
10
gnomever=3.18
11
fi
12
fi
13
14
echo
15
16
for color in '' '-dark' '-light' ; do
17
for size in '' '-compact' ; do
18
echo Installing Flat-Plat${color}${size} ...
19
20
themedir=${destdir}/usr/share/themes/Flat-Plat${color}${size}
21
install -d ${themedir}
22
23
# Copy COPYING
24
cd ${repodir}
25
cp -ur \
26
COPYING \
27
${themedir}
28
29
# Install index.theme
30
cd ${srcdir}
31
cp -ur \
32
index${color}${size}.theme \
33
${themedir}/index.theme
34
35
# Install Chrome Theme/Extention
36
install -d ${themedir}/chrome
37
cd ${srcdir}/chrome
38
cp -ur \
39
"Flat-Plat${color} Theme.crx" \
40
${themedir}/chrome
41
if [ "$color" != '-dark' ] ; then
42
cp -ur \
43
"Flat-Plat Scrollbars.crx" \
44
${themedir}/chrome
45
else
46
cp -ur \
47
"Flat-Plat${color} Scrollbars.crx" \
48
${themedir}/chrome
49
fi
50
51
# Install GNOME Shell Theme
52
install -d ${themedir}/gnome-shell
53
cd ${srcdir}/gnome-shell/${gnomever}
54
cp -ur \
55
no-events.svg \
56
no-notifications.svg \
57
process-working.svg \
58
${themedir}/gnome-shell
59
cp -urL \
60
extensions \
61
pad-osd.css \
62
${themedir}/gnome-shell
63
if [ "$color" != '-dark' ] ; then
64
cp -urL \
65
assets \
66
${themedir}/gnome-shell
67
else
68
cp -urL \
69
assets${color} \
70
${themedir}/gnome-shell/assets
71
fi
72
cp -ur \
73
gnome-shell${color}${size}.css \
74
${themedir}/gnome-shell/gnome-shell.css
75
glib-compile-resources \
76
--sourcedir=${themedir}/gnome-shell \
77
--target=${themedir}/gnome-shell/gnome-shell-theme.gresource \
78
gnome-shell-theme.gresource.xml
79
80
# Install GTK+ 2 Theme
81
install -d ${themedir}/gtk-2.0
82
cd ${srcdir}/gtk-2.0
83
cp -ur \
84
apps.rc \
85
hacks.rc \
86
main.rc \
87
${themedir}/gtk-2.0
88
if [ "$color" != '-dark' ] ; then
89
cp -ur \
90
assets \
91
${themedir}/gtk-2.0
92
else
93
cp -ur \
94
assets${color} \
95
${themedir}/gtk-2.0/assets
96
fi
97
cp -ur \
98
gtkrc${color} \
99
${themedir}/gtk-2.0/gtkrc
100
101
# Install GTK+ 3 Theme
102
install -d ${themedir}/gtk-common
103
cd ${srcdir}/gtk-3.0/gtk-common
104
cp -ur \
105
assets \
106
${themedir}/gtk-common
107
108
for version in '3.18' '3.20' '3.22' ; do
109
if [ "$version" == '3.18' ] ; then
110
install -d ${themedir}/gtk-3.0
111
cd ${srcdir}/gtk-3.0/${version}
112
cp -ur \
113
assets \
114
${themedir}/gtk-3.0
115
cp -ur \
116
gtk${color}.css \
117
${themedir}/gtk-3.0/gtk.css
118
if [ "$color" != '-dark' ] ; then
119
cp -ur \
120
gtk-dark.css \
121
${themedir}/gtk-3.0
122
fi
123
else
124
install -d ${themedir}/gtk-${version}
125
cd ${srcdir}/gtk-3.0/${version}
126
cp -ur \
127
assets \
128
${themedir}/gtk-${version}
129
cp -ur \
130
gtk${color}${size}.css \
131
${themedir}/gtk-${version}/gtk.css
132
if [ "$color" != '-dark' ] ; then
133
cp -ur \
134
gtk-dark${size}.css \
135
${themedir}/gtk-${version}/gtk-dark.css
136
fi
137
fi
138
done
139
140
# Install Metacity Theme
141
install -d ${themedir}/metacity-1
142
cd ${srcdir}/metacity-1
143
cp -ur \
144
*.svg \
145
${themedir}/metacity-1
146
if [ "$color" != '-light' ] ; then
147
cp -ur \
148
metacity-theme-2.xml \
149
metacity-theme-3.xml \
150
${themedir}/metacity-1
151
else
152
cp -ur \
153
metacity-theme-2${color}.xml \
154
${themedir}/metacity-1/metacity-theme-2.xml
155
cp -ur \
156
metacity-theme-3${color}.xml \
157
${themedir}/metacity-1/metacity-theme-3.xml
158
fi
159
160
# Install Unity Theme
161
install -d ${themedir}/unity
162
cd ${srcdir}/unity
163
cp -ur \
164
*.svg \
165
*.png \
166
*.json \
167
${themedir}/unity
168
if [ "$color" != '-light' ] ; then
169
cp -ur \
170
buttons \
171
${themedir}/unity
172
else
173
cp -urT \
174
buttons${color} \
175
${themedir}/unity/buttons
176
fi
177
178
# Install Xfwm Theme
179
install -d ${themedir}/xfwm4
180
cd ${srcdir}/xfwm4
181
cp -ur \
182
*.svg \
183
themerc \
184
${themedir}/xfwm4
185
if [ "$color" != '-light' ] ; then
186
cp -ur \
187
assets \
188
${themedir}/xfwm4
189
else
190
cp -urT \
191
assets${color} \
192
${themedir}/xfwm4/assets
193
fi
194
done
195
done
196
197
echo
198
echo Done.
199