From e815b19b08ec4bc9133cde789a83b71ab972b9f6 Mon Sep 17 00:00:00 2001 From: Matijs van Zuijlen Date: Sun, 13 Sep 2020 14:29:44 +0200 Subject: [PATCH] WIP --- alexandria.desktop.in | 6 +++--- po/LINGUAS | 22 ++++++++++++++++++++++ po/nl.po | 10 +++++++--- util/rake/gettextgenerate.rb | 8 ++------ 4 files changed, 34 insertions(+), 12 deletions(-) create mode 100644 po/LINGUAS diff --git a/alexandria.desktop.in b/alexandria.desktop.in index e1820288..204e7b1f 100644 --- a/alexandria.desktop.in +++ b/alexandria.desktop.in @@ -1,9 +1,9 @@ [Desktop Entry] Version=1.0 Type=Application -_Name=Alexandria Book Collection Manager -_GenericName=Book Collection Manager -_Comment=Manage your book collection +Name=Alexandria Book Collection Manager +GenericName=Book Collection Manager +Comment=Manage your book collection Exec=/usr/bin/alexandria Terminal=false Categories=GNOME;GTK;Office;Database; diff --git a/po/LINGUAS b/po/LINGUAS new file mode 100644 index 00000000..48405818 --- /dev/null +++ b/po/LINGUAS @@ -0,0 +1,22 @@ +# Set of available languages. +cs +cy +de +el +es +fr +ga +gl +it +ja +mk +nb +nl +pl +pt +pt_BR +ru +sk +sv +uk +zh_TW diff --git a/po/nl.po b/po/nl.po index 307a68b5..a8dcba98 100644 --- a/po/nl.po +++ b/po/nl.po @@ -1354,18 +1354,22 @@ msgstr "_Sinds:" msgid "Loaning" msgstr "Uitlenen" -#: ../alexandria.desktop.in.h:1 +#: ../alexandria.desktop:5 msgid "Alexandria Book Collection Manager" msgstr "Alexandria Boekcollectiebeheerder" -#: ../alexandria.desktop.in.h:2 +#: ../alexandria.desktop:6 msgid "Book Collection Manager" msgstr "Boekcollectiebeheerder" -#: ../alexandria.desktop.in.h:3 +#: ../alexandria.desktop:7 msgid "Manage your book collection" msgstr "Beheer uw boekcollectie" +#: ../alexandria.desktop:11 +msgid "alexandria" +msgstr "" + #~ msgid "Locale" #~ msgstr "Taal" diff --git a/util/rake/gettextgenerate.rb b/util/rake/gettextgenerate.rb index 0dbb3aa9..b266cf95 100644 --- a/util/rake/gettextgenerate.rb +++ b/util/rake/gettextgenerate.rb @@ -69,12 +69,8 @@ def po_files def generate_desktop(infile, outfile) @generated_files << outfile file outfile => [infile, *po_files] do |_f| - begin - `intltool-merge --version` - rescue Errno::ENOENT - raise "Need to install intltool" - end - system("intltool-merge -d #{@po_dir} #{infile} #{outfile}") + result = system("msgfmt --desktop --template #{infile} -d #{@po_dir} -o #{outfile}") + raise "msgfmt failed for #{infile}" unless result end end