[gnome-calendar] project: Renamed the names of the icons' files



commit 4cb0b1434347bd585f64d696f2a90061acf8ea70
Author: Iñigo Martínez <inigomartinez gmail com>
Date:   Tue Jul 18 18:15:14 2017 +0200

    project: Renamed the names of the icons' files
    
    The names of icons' files, besides containing the final names, they
    also contained the path in which they were going to be installed.
    This implies that they have to be renamed on the installation
    process.
    
    This patch creates the proper directory tree needed on the
    installation process and renames all files' names to their final
    names.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=782843

 .../16x16/apps/org.gnome.Calendar.png}             |  Bin 769 -> 769 bytes
 .../22x22/apps/org.gnome.Calendar.png}             |  Bin 1168 -> 1168 bytes
 .../24x24/apps/org.gnome.Calendar.png}             |  Bin 1260 -> 1260 bytes
 .../256x256/apps/org.gnome.Calendar.png}           |  Bin 50400 -> 50400 bytes
 .../32x32/apps/org.gnome.Calendar.png}             |  Bin 1834 -> 1834 bytes
 .../48x48/apps/org.gnome.Calendar.png}             |  Bin 3557 -> 3557 bytes
 .../512x512/apps/org.gnome.Calendar.png}           |  Bin 197273 -> 197273 bytes
 .../symbolic/apps/org.gnome.Calendar-symbolic.svg} |    0
 data/icons/meson.build                             |   23 ++-----------------
 meson_post_install.py                              |    9 -------
 10 files changed, 3 insertions(+), 29 deletions(-)
---
diff --git a/data/icons/hicolor_apps_symbolic_org.gnome.Calendar-symbolic.svg 
b/data/icons/hicolor/symbolic/apps/org.gnome.Calendar-symbolic.svg
similarity index 100%
rename from data/icons/hicolor_apps_symbolic_org.gnome.Calendar-symbolic.svg
rename to data/icons/hicolor/symbolic/apps/org.gnome.Calendar-symbolic.svg
diff --git a/data/icons/meson.build b/data/icons/meson.build
index 7bfd37a..5e2d102 100644
--- a/data/icons/meson.build
+++ b/data/icons/meson.build
@@ -1,21 +1,4 @@
-icon_sizes = [
-  '16x16',
-  '22x22',
-  '24x24',
-  '32x32',
-  '48x48',
-  '256x256',
-  '512x512'
-]
-
-foreach icon_size: icon_sizes
-  install_data(
-    '_'.join(['hicolor', 'apps', icon_size, 'org.gnome.Calendar.png']),
-    install_dir: join_paths(calendar_datadir, 'icons', 'hicolor', icon_size, 'apps')
-  )
-endforeach
-
-install_data(
-  '_'.join(['hicolor', 'apps', 'symbolic', 'org.gnome.Calendar-symbolic.svg']),
-  install_dir: join_paths(calendar_datadir, 'icons', 'hicolor', 'symbolic', 'apps')
+install_subdir(
+  'hicolor',
+  install_dir: join_paths(calendar_datadir, 'icons')
 )
diff --git a/meson_post_install.py b/meson_post_install.py
index e1ea68c..bf320a9 100644
--- a/meson_post_install.py
+++ b/meson_post_install.py
@@ -1,19 +1,10 @@
 #!/usr/bin/env python3
 
-import glob
 import os
-import re
 import subprocess
 
 install_prefix = os.environ['MESON_INSTALL_PREFIX']
-
-name_pattern = re.compile('hicolor_apps_(?:\d+x\d+|symbolic)_(.*)')
-search_pattern = '/**/hicolor_*'
-
 icondir = os.path.join(install_prefix, 'share', 'icons', 'hicolor')
-[os.rename(file, os.path.join(os.path.dirname(file), name_pattern.search(file).group(1)))
- for file in glob.glob(icondir + search_pattern, recursive=True)]
-
 schemadir = os.path.join(install_prefix, 'share', 'glib-2.0', 'schemas')
 
 if not os.environ.get('DESTDIR'):


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]