mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-07 23:17:32 -06:00
Add extra icons and fix their paths
This commit is contained in:
parent
f5b53f8065
commit
9f9e218ef4
1 changed files with 10 additions and 3 deletions
|
@ -30,15 +30,22 @@ def copy_metadata_files(dist_path, version):
|
||||||
Copy metadata files for the metadata of the AppImage.
|
Copy metadata files for the metadata of the AppImage.
|
||||||
"""
|
"""
|
||||||
copied_files = {
|
copied_files = {
|
||||||
os.path.join("..", "icons", "cura-icon_256x256.png"): "cura-icon.png",
|
os.path.join("..", "icons", "cura-icon.svg"): "usr/share/icons/hicolor/scalable/apps/cura-icon.svg",
|
||||||
|
os.path.join("..", "icons", "cura-icon_64x64.png"): "usr/share/icons/hicolor/64x64/apps/cura-icon.png",
|
||||||
|
os.path.join("..", "icons", "cura-icon_128x128.png"): "usr/share/icons/hicolor/128x128/apps/cura-icon.png",
|
||||||
|
os.path.join("..", "icons", "cura-icon_256x256.png"): "usr/share/icons/hicolor/256x256/apps/cura-icon.png",
|
||||||
"cura.appdata.xml": "cura.appdata.xml",
|
"cura.appdata.xml": "cura.appdata.xml",
|
||||||
"AppRun": "AppRun"
|
"AppRun": "AppRun"
|
||||||
}
|
}
|
||||||
|
|
||||||
packaging_dir = os.path.dirname(__file__)
|
packaging_dir = os.path.dirname(__file__)
|
||||||
for source, dest in copied_files.items():
|
for source, dest in copied_files.items():
|
||||||
print("Copying", os.path.join(packaging_dir, source), "to", os.path.join(dist_path, dest))
|
source_file_path = source
|
||||||
shutil.copyfile(os.path.join(packaging_dir, source), os.path.join(dist_path, dest))
|
dest_file_path = os.path.join(dist_path, dest)
|
||||||
|
dir_path = dest_file_path
|
||||||
|
print("Copying", source_file_path, "to", dest_file_path)
|
||||||
|
os.makedirs(os.path.dirname(dir_path), exist_ok=True)
|
||||||
|
shutil.copyfile(source_file_path, dest_file_path)
|
||||||
|
|
||||||
# Ensure that AppRun has the proper permissions: 755 (user reads, writes and executes, group reads and executes, world reads and executes).
|
# Ensure that AppRun has the proper permissions: 755 (user reads, writes and executes, group reads and executes, world reads and executes).
|
||||||
print("Changing permissions for AppRun")
|
print("Changing permissions for AppRun")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue