Skip to content

Commit 49d4934

Browse files
committed
Improve error message when icon is not found
1 parent c7d3674 commit 49d4934

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

appimagetool.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -605,7 +605,11 @@ main (int argc, char *argv[])
605605
} else if(g_file_test(icon_file_xpm, G_FILE_TEST_IS_REGULAR)) {
606606
icon_file_path = icon_file_xpm;
607607
} else {
608-
fprintf (stderr, "%s{.png,.svg,.svgz,.xpm} not present but defined in desktop file\n", icon_name);
608+
fprintf (stderr, "%s{.png,.svg,.svgz,.xpm} defined in desktop file but not found\n", icon_name);
609+
fprintf (stderr, "For example, you could put a 256x256 pixel png into\n");
610+
gchar *icon_name_with_png = g_strconcat(icon_name, ".png", NULL);
611+
gchar *example_path = g_build_filename(source, "/usr/share/icons/hicolor/256x256/apps/", icon_name_with_png, NULL);
612+
fprintf (stderr, "%s\n", example_path);
609613
exit(1);
610614
}
611615

0 commit comments

Comments
 (0)