diff --git a/data/app-generator.appdata.xml.in b/data/app-generator.metainfo.xml.in similarity index 100% rename from data/app-generator.appdata.xml.in rename to data/app-generator.metainfo.xml.in diff --git a/data/meson.build b/data/meson.build index 83921ab..8c1321c 100644 --- a/data/meson.build +++ b/data/meson.build @@ -29,8 +29,8 @@ i18n.merge_file( ) i18n.merge_file( - input: 'app-generator.appdata.xml.in', - output: meson.project_name() + '.appdata.xml', + input: 'app-generator.metainfo.xml.in', + output: meson.project_name() + '.metainfo.xml', po_dir: meson.project_source_root() / 'po' / 'extra', install: true, install_dir: get_option('datadir') / 'metainfo' diff --git a/po/extra/POTFILES b/po/extra/POTFILES index fb735a4..86fb582 100644 --- a/po/extra/POTFILES +++ b/po/extra/POTFILES @@ -1,2 +1,2 @@ -data/app-generator.appdata.xml.in +data/app-generator.metainfo.xml.in data/app-generator.desktop.in \ No newline at end of file diff --git a/src/Views/Form.vala b/src/Views/Form.vala index 6b825f9..c55306e 100644 --- a/src/Views/Form.vala +++ b/src/Views/Form.vala @@ -213,8 +213,8 @@ public class Views.Form : Adw.Bin { set_file_content (new_flatpak_file, "{{PROJECT_NAME}}", project_name); // AppData Files - string appdata_file = GLib.Path.build_filename (project_folder, "data", "{{PROJECT_NAME}}.appdata.xml.in"); - string new_appdata_file = GLib.Path.build_filename (project_folder, "data", project_name + ".appdata.xml.in"); + string appdata_file = GLib.Path.build_filename (project_folder, "data", "{{PROJECT_NAME}}.metainfo.xml.in"); + string new_appdata_file = GLib.Path.build_filename (project_folder, "data", project_name + ".metainfo.xml.in"); rename_file (appdata_file, new_appdata_file); set_file_content (new_appdata_file, "{{APPLICATION_ID}}", application_id); set_file_content (new_appdata_file, "{{PROJECT_NAME}}", project_name); @@ -259,6 +259,10 @@ public class Views.Form : Adw.Bin { set_file_content (new_appdata_file, "{{DEVELOPER_NAME}}", developer_name); set_file_content (new_appdata_file, "{{DEVELOPER_EMAIL}}", developer_email); + // Set Po files + string po_extra_window_file = GLib.Path.build_filename (project_folder, "po", "extra", "POTFILES"); + set_file_content (po_extra_window_file, "{{PROJECT_NAME}}", project_name); + created (project_name_entry.text, location_entry.text); }