Skip to content

Commit c442bc1

Browse files
authored
Merge pull request #13 from ellie-commons/feat/metainfo
2 parents a1fd023 + 6bc98c7 commit c442bc1

File tree

4 files changed

+9
-5
lines changed

4 files changed

+9
-5
lines changed
File renamed without changes.

data/meson.build

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ i18n.merge_file(
2929
)
3030

3131
i18n.merge_file(
32-
input: 'app-generator.appdata.xml.in',
33-
output: meson.project_name() + '.appdata.xml',
32+
input: 'app-generator.metainfo.xml.in',
33+
output: meson.project_name() + '.metainfo.xml',
3434
po_dir: meson.project_source_root() / 'po' / 'extra',
3535
install: true,
3636
install_dir: get_option('datadir') / 'metainfo'

po/extra/POTFILES

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
data/app-generator.appdata.xml.in
1+
data/app-generator.metainfo.xml.in
22
data/app-generator.desktop.in

src/Views/Form.vala

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,8 +213,8 @@ public class Views.Form : Adw.Bin {
213213
set_file_content (new_flatpak_file, "{{PROJECT_NAME}}", project_name);
214214

215215
// AppData Files
216-
string appdata_file = GLib.Path.build_filename (project_folder, "data", "{{PROJECT_NAME}}.appdata.xml.in");
217-
string new_appdata_file = GLib.Path.build_filename (project_folder, "data", project_name + ".appdata.xml.in");
216+
string appdata_file = GLib.Path.build_filename (project_folder, "data", "{{PROJECT_NAME}}.metainfo.xml.in");
217+
string new_appdata_file = GLib.Path.build_filename (project_folder, "data", project_name + ".metainfo.xml.in");
218218
rename_file (appdata_file, new_appdata_file);
219219
set_file_content (new_appdata_file, "{{APPLICATION_ID}}", application_id);
220220
set_file_content (new_appdata_file, "{{PROJECT_NAME}}", project_name);
@@ -259,6 +259,10 @@ public class Views.Form : Adw.Bin {
259259
set_file_content (new_appdata_file, "{{DEVELOPER_NAME}}", developer_name);
260260
set_file_content (new_appdata_file, "{{DEVELOPER_EMAIL}}", developer_email);
261261

262+
// Set Po files
263+
string po_extra_window_file = GLib.Path.build_filename (project_folder, "po", "extra", "POTFILES");
264+
set_file_content (po_extra_window_file, "{{PROJECT_NAME}}", project_name);
265+
262266
created (project_name_entry.text, location_entry.text);
263267
}
264268

0 commit comments

Comments
 (0)