Commit 4e81d976 authored by Tobias Mueller's avatar Tobias Mueller

Merge branch 'appdata'

parents d933d6df 3d4300b6
......@@ -59,7 +59,7 @@ so it should be easy for you to install it.
If your version is older than that,
this list of packages seems to make it work:
python avahi-daemon python-avahi python-gi gir1.2-glib-2.0 gir1.2-gtk-3.0 python-dbus gir1.2-gstreamer-1.0 gir1.2-gst-plugins-base-1.0 gstreamer1.0-plugins-bad gstreamer1.0-plugins-good python-gi-cairo
python python-lxml avahi-daemon python-avahi python-gi gir1.2-glib-2.0 gir1.2-gtk-3.0 python-dbus gir1.2-gstreamer-1.0 gir1.2-gst-plugins-base-1.0 gstreamer1.0-plugins-bad gstreamer1.0-plugins-good python-gi-cairo
In Ubuntu, the package
gstreamer1.0-plugins-bad provides the zbar and the gtksink element, and
......@@ -78,7 +78,7 @@ assuming that pip and git are already installed:
.. code::
sudo dnf install -y python-gobject python-avahi dbus-python gstreamer1-plugins-bad-free-gtk gstreamer1-plugins-good gnupg
sudo dnf install -y python-lxml python-gobject python-avahi dbus-python gstreamer1-plugins-bad-free-gtk gstreamer1-plugins-good gnupg
As optional:
......
# -*- coding: utf-8 -*-
# vim: sw=4 ts=4 fenc=utf-8
# =============================================================================
# $Id: __init__.py 235 2007-07-20 15:23:26Z palgarvio $
# =============================================================================
# $URL: http://svn.edgewall.org/repos/babel/contrib/GladeBabelExtractor/babelglade/__init__.py $
# $LastChangedDate: 2007-07-20 16:23:26 +0100 (Fri, 20 Jul 2007) $
# $Rev: 235 $
# $LastChangedBy: palgarvio $
# =============================================================================
# Copyright (C) 2006 Ufsoft.org - Pedro Algarvio <ufs@ufsoft.org>
#
# Please view LICENSE for additional licensing information.
# =============================================================================
from __future__ import unicode_literals
from xml.parsers import expat
from lxml import etree
class GladeParser(object):
def __init__(self, source):
self.source = source
parser = expat.ParserCreate("utf-8")
parser.buffer_text = True
parser.ordered_attributes = True
parser.StartElementHandler = self._handle_start
parser.EndElementHandler = self._handle_end
parser.CharacterDataHandler = self._handle_data
if not hasattr(parser, 'CurrentLineNumber'):
self._getpos = self._getpos_unknown
self.expat = parser
self._queue = []
self._comments = []
self._translate = False
self._data = []
def parse(self):
try:
bufsize = 4 * 1024 # 4K
done = False
while not done and len(self._queue) == 0:
data = self.source.read(bufsize)
if data == b'': # end of data
if hasattr(self, 'expat'):
self.expat.Parse('', True)
del self.expat # get rid of circular references
done = True
else:
self.expat.Parse(data, False)
for event in self._queue:
yield event
self._queue = []
if done:
break
except expat.ExpatError as e:
msg = str(e)
raise ParseError(msg, self.filename, e.lineno, e.offset)
def _handle_start(self, tag, attrib):
if 'translatable' in attrib:
if attrib[attrib.index('translatable')+1] == 'yes':
self._translate = True
if 'comments' in attrib:
self._comments.append(attrib[attrib.index('comments')+1])
def _handle_end(self, tag):
if self._translate is True:
if self._data:
self._enqueue(tag, self._data, self._comments)
self._translate = False
self._data = []
self._comments = []
def _handle_data(self, text):
if self._translate:
if not text.startswith('gtk-'):
self._data.append(text)
else:
self._translate = False
self._data = []
self._comments = []
def _enqueue(self, kind, data=None, comments=None, pos=None):
if pos is None:
pos = self._getpos()
if kind == 'property':
if '\n' in data:
lines = data.splitlines()
lineno = pos[0] - len(lines) + 1
offset = -1
else:
lineno = pos[0]
offset = pos[1] - len(data)
pos = (lineno, offset)
self._queue.append((data, comments, pos[0]))
def _getpos(self):
return (self.expat.CurrentLineNumber,
self.expat.CurrentColumnNumber)
def _getpos_unknown(self):
return (-1, -1)
def extract_glade(fileobj, keywords, comment_tags, options):
parser = GladeParser(fileobj)
def get_messages():
for message, comments, lineno in parser.parse():
if comment_tags:
yield (lineno, None, message, comments)
tree = etree.parse(fileobj)
root = tree.getroot()
to_translate = []
for elem in root.iter():
# do we need to check if the element starts with "gtk-"?
if elem.get("translatable") == "yes":
line_no = elem.sourceline
func_name = None
message = elem.text
comment = []
if elem.get("comments"):
comment = [elem.get("comments")]
to_translate.append([line_no, func_name, message, comment])
return to_translate
# All localestrings from https://specifications.freedesktop.org/desktop-entry-spec/latest/ar01s05.html
TRANSLATABLE = (
'Name',
'GenericName',
'Comment',
'Icon',
'Keywords',
)
def extract_desktop(fileobj, keywords, comment_tags, options):
for lineno, line in enumerate(fileobj, 1):
if line.startswith(b'[Desktop Entry]'):
continue
for t in TRANSLATABLE:
if not line.startswith(t.encode('utf-8')):
continue
else:
yield (lineno, None, message, [])
return get_messages()
l = line.decode('utf-8')
comments = []
key_value = l.split('=', 1)
key, value = key_value[0:2]
funcname = key # FIXME: Why can I not assign that name to funcname?
funcname = ''
message = value
comments.append(key)
yield (lineno, funcname, message.strip(), comments)
<?xml version="1.0" encoding="UTF-8"?>
<application>
<id type="desktop">gnome-keysign.desktop</id>
<licence>CC0</licence>
<description>
<_p>
GNOME-Keysign allows signing OpenPGP keys comfortably.
</_p>
<_p>
It can scan another key's barcode and transfer the key securely,
allowing for casual two-party key signing sessions.
It follows best practises by sending the encrypted signatures
to the UIDs of a key using the Email client the user configured
to use.
</_p>
</description>
<screenshots>
<screenshot type="default">https://wiki.gnome.org/GnomeKeysign?action=AttachFile&amp;do=get&amp;target=UI.png</screenshot>
</screenshots>
<url type="homepage">https://wiki.gnome.org/GnomeKeysign</url>
<updatecontact>tobiasmue@gnome.org</updatecontact>
</application>
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop">
<id>org.gnome.Keysign</id>
<metadata_license>CC0</metadata_license>
<project_license>GPL-3.0+</project_license>
<name>Keysign</name>
<summary>OpenPGP Keysigning helper</summary>
<description>
<p translatable="yes">
GNOME-Keysign allows signing OpenPGP keys comfortably and securely
via the local network or Bluetooth.
</p>
<p translatable="yes">
It can scan another key's barcode and transfer the key securely,
allowing for casual two-party key signing sessions.
It follows best practises by sending the encrypted signatures
to the UIDs of a key using the Email client the user configured
to use.
</p>
</description>
<launchable type="desktop-id">org.gnome.Keysign.desktop</launchable>
<screenshots>
<screenshot type="default">
<image width="529" height="646">https://wiki.gnome.org/Apps/Keysign?action=AttachFile&amp;do=get&amp;target=send.png</image>
</screenshot>
<screenshot>
<image width="529" height="646">https://wiki.gnome.org/Apps/Keysign?action=AttachFile&amp;do=get&amp;target=receive.png</image>
</screenshot>
</screenshots>
<kudos>
<kudo>HiDpiIcon</kudo>
<kudo>ModernToolkit</kudo>
</kudos>
<url type="homepage">https://wiki.gnome.org/GnomeKeysign</url>
<url type="bugtracker">https://github.com/gnome-keysign/gnome-keysign/issues</url>
<!-- "Metainfo files may only contain 'stock' icons, icons of kind 'remote' are not allowed"...
icon type="remote">https://gitlab.gnome.org/GNOME/gnome-keysign/raw/master/data/gnome-keysign.svg</icon -->
<project_group>GNOME</project_group>
<releases>
<release version="0.9.5" date="2017-10-03">
<description>
<p>Add Bluetooth support</p>
<p>Default to gpgme</p>
</description>
</release>
</releases>
<update_contact>tobiasmue@gnome.org</update_contact>
<translation type="gettext">gnome-keysign</translation>
<content_rating type="oars-1.0">
<content_attribute id="violence-cartoon">none</content_attribute>
<content_attribute id="violence-fantasy">none</content_attribute>
<content_attribute id="violence-realistic">none</content_attribute>
<content_attribute id="violence-bloodshed">none</content_attribute>
<content_attribute id="violence-sexual">none</content_attribute>
<content_attribute id="drugs-alcohol">none</content_attribute>
<content_attribute id="drugs-narcotics">none</content_attribute>
<content_attribute id="drugs-tobacco">none</content_attribute>
<content_attribute id="sex-nudity">none</content_attribute>
<content_attribute id="sex-themes">none</content_attribute>
<content_attribute id="language-profanity">none</content_attribute>
<content_attribute id="language-humor">none</content_attribute>
<content_attribute id="language-discrimination">none</content_attribute>
<content_attribute id="social-chat">none</content_attribute>
<content_attribute id="social-info">none</content_attribute>
<content_attribute id="social-audio">none</content_attribute>
<content_attribute id="social-location">none</content_attribute>
<content_attribute id="social-contacts">intense</content_attribute>
<content_attribute id="money-purchasing">none</content_attribute>
<content_attribute id="money-gambling">none</content_attribute>
</content_rating>
</component>
......@@ -8,43 +8,117 @@ msgid ""
msgstr ""
"Project-Id-Version: gnome-keysign 0.9\n"
"Report-Msgid-Bugs-To: tobiasmue@gnome.org\n"
"POT-Creation-Date: 2017-05-17 19:18+0200\n"
"POT-Creation-Date: 2017-12-15 13:39+0100\n"
"PO-Revision-Date: 2017-05-17 19:18+0200\n"
"Last-Translator: \n"
"Language: de\n"
"Language-Team: de <LL@li.org>\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.4.0\n"
"X-Generator: Poedit 1.8.7.1\n"
"Generated-By: Babel 2.5.1\n"
#: keysign/app.py:162
#: data/gnome-keysign.raw.appdata.xml:10
msgid ""
"\n"
" GNOME-Keysign allows signing OpenPGP keys comfortably and securely\n"
" via the local network or Bluetooth.\n"
" "
msgstr "GNOME-Keysign signiert OpenPGP-Schlüssel einfach und sicher unter Benutzung von des lokalen Netzwekes oder Bluetooth."
#: data/gnome-keysign.raw.appdata.xml:14
msgid ""
"\n"
" It can scan another key's barcode and transfer the key securely,\n"
" allowing for casual two-party key signing sessions.\n"
" It follows best practises by sending the encrypted signatures\n"
" to the UIDs of a key using the Email client the user configured\n"
" to use.\n"
" "
msgstr "Das Programm scannt den Barcode eines anderen Schlüssels und überträgt den Schlüssel sicher, was ad-hoc Keysigning-Parties ermöglicht. Es hält sich dabei an best-practices. So schickt es die generierten Signaturen als verschlüsselten Email-Anhang unter Benutzung des Email-Clients, den der Benutzer schon eingerichtet hat."
#. Name
#: data/gnome-keysign.raw.desktop:2
msgid "Keysign"
msgstr "Keysign"
#. Comment
#: data/gnome-keysign.raw.desktop:3
msgid ""
"A keysigning helper to enable you to comfortably exchange OpenPGP keys "
"with a friend"
msgstr "Ein Helferprogramm um komfortabel OpenPGP-Schlüssel mit einem Freund zu signieren"
#. Keywords
#: data/gnome-keysign.raw.desktop:4
msgid "python;gpg;gnupg;key;openpgp;"
msgstr ""
#. Icon
#: data/gnome-keysign.raw.desktop:7
msgid "gnome-keysign"
msgstr ""
#: keysign/app.py:166
msgid "Send"
msgstr "Senden"
#: keysign/app.py:164 keysign/receive.py:168
#: keysign/app.py:168 keysign/receive.py:189
msgid "Receive"
msgstr "Empfangen"
#: keysign/app.py:198 keysign/send.py:143
#: keysign/app.py:205 keysign/send.py:180
msgid "Sending {}"
msgstr "Senden {}"
#: keysign/avahioffer.py:85
#: keysign/avahioffer.py:82 keysign/bluetoothoffer.py:142
msgid "Offering key: {}"
msgstr "Biete Key {} an"
#: keysign/avahioffer.py:86
#: keysign/avahioffer.py:83 keysign/bluetoothoffer.py:143
msgid "Discovery info: {}"
msgstr ""
#: keysign/avahioffer.py:87
#: keysign/avahioffer.py:84
msgid "Press Enter to stop"
msgstr "Drücke Enter um zu Stoppen"
#: keysign/gpgmks.py:175
#: keysign/bluetoothoffer.py:125
msgid ""
"\n"
"Key successfully sent"
msgstr "Schlüssel erfolgreich gesendet"
#: keysign/bluetoothoffer.py:127
msgid ""
"\n"
"An error occurred: {}"
msgstr "Es ist ein Fehler aufgetreten: {}"
#: keysign/bluetoothoffer.py:129
#, fuzzy
#| msgid "Press Enter to stop"
msgid "Press Enter to exit"
msgstr "Drücke Enter um zu Stoppen"
#: keysign/bluetoothoffer.py:144
msgid "HMAC: {}"
msgstr ""
#: keysign/bluetoothoffer.py:145
msgid "Port: {}"
msgstr ""
#: keysign/bluetoothoffer.py:150
msgid "Bluetooth not available"
msgstr ""
#: keysign/bluetoothreceive.py:133
msgid "Trying to download the key, please wait"
msgstr ""
#: keysign/gpgmks.py:178
#, python-format
msgid "installing symlinks for sockets from %s to %s"
msgstr ""
......@@ -59,11 +133,11 @@ msgstr "<big><b>Ein Programmierfehler wurde bemerkt.</b></big>"
#: keysign/gtkexcepthook.py:178
msgid ""
"You may be able to ignore this error and carry on working, but you may get "
"unexpected results.\n"
"You may be able to ignore this error and carry on working, but you may "
"get unexpected results.\n"
"\n"
"Please tell the developers about this using the issue tracker if no-one else "
"has reported it yet."
"Please tell the developers about this using the issue tracker if no-one "
"else has reported it yet."
msgstr ""
#: keysign/gtkexcepthook.py:187
......@@ -114,58 +188,50 @@ msgid ""
" "
msgstr ""
#: keysign/i18n.py:36
#: keysign/i18n.py:39
msgid "Translated for gettext (C)"
msgstr "Übersetzt für gettext (DE)"
#: keysign/i18n.py:40
#: keysign/i18n.py:47
msgid "Translated for Python (C)"
msgstr "Übersetzt für Python (DE)"
#: keysign/keylistwidget.py:59
#: keysign/keylistwidget.py:82
msgid "Expires: "
msgstr "Ungültig ab: "
#: keysign/offer-key.py:78
msgid "Keysign - Offering Key"
msgstr "Keysign - Key Anbieten"
#: keysign/offer-key.py:113
msgid "Auxiliary helper program to present a key"
msgstr ""
#: keysign/offer-key.py:120
msgid "increases log verbosity for each occurence."
msgstr ""
#: keysign/offer-key.py:129
msgid "The fingerprint of the key to transfer"
#: keysign/receive.py:117
msgid "Sign Key"
msgstr ""
#: keysign/receive.ui:56
#: keysign/receive.ui:53
msgid ""
"No GNOME Keysign servers around :-(\n"
"Find a friend to use GNOME Keysign with.\n"
"You may also suffer from connectivity problems.\n"
"For more information click <a href=\"https://wiki.gnome.org/Apps/Keysign/Doc/"
"NoServers/1\">here</a>."
"For more information click <a "
"href=\"https://wiki.gnome.org/Apps/Keysign/Doc/NoServers/1\">here</a>."
msgstr ""
"Es konnte kein GNOME Keysign servers erkannt werden :-(\n"
"Du brauchst einen Freund um GNOME Keysign zu benutzen.\n"
"Netwerkprobleme können auch ursächlich sein.\n"
"Um mehr zu erfahren, klicke <a href=\"https://wiki.gnome.org/Apps/Keysign/Doc/"
"NoServers/1\">hier</a>."
"Um mehr zu erfahren, klicke <a "
"href=\"https://wiki.gnome.org/Apps/Keysign/Doc/NoServers/1\">hier</a>."
#: keysign/receive.ui:105
msgid "<small>To sign someone's key, scan their QR or enter security code</small>"
msgstr ""
"<small>Scanne einen Barcode oder tippe den Sicherheitscode ein um einen Key zu "
"signieren</small>"
"<small>Scanne einen Barcode oder tippe den Sicherheitscode ein um einen "
"Key zu signieren</small>"
#: keysign/receive.ui:124
msgid "<b>Camera</b>"
msgstr "<b>Kamera</b>"
#: keysign/receive.ui:139
msgid "Integrated Web Cam"
msgstr ""
#: keysign/receive.ui:176 keysign/send.ui:341
msgid "<b>Security Code</b>"
msgstr "<b>Sicherheitscode</b>"
......@@ -186,15 +252,15 @@ msgstr ""
msgid "page1"
msgstr ""
#: keysign/receive.ui:335
#: keysign/receive.ui:334
msgid ""
"To sign the key, confirm that you want to sign the following key.\n"
"This will generate an email that must be sent in order to complete the signing "
"process."
"This will generate an email that must be sent in order to complete the "
"signing process."
msgstr ""
"Bestätige das Signieren des Schlüssels.\n"
"Im Anschluss wird eine Email generiert, die verschickt werden muss um das "
"Signieren abzuschließen."
"Im Anschluss wird eine Email generiert, die verschickt werden muss um das"
" Signieren abzuschließen."
#: keysign/receive.ui:362
msgid "Key"
......@@ -224,7 +290,7 @@ msgstr "Seite 3"
msgid "Select and send key"
msgstr "Key Auswählen und Senden"
#: keysign/send.ui:59
#: keysign/send.ui:58
msgid ""
"You don't have any keys!\n"
"Please use, e.g. Seahorse to create one."
......@@ -244,8 +310,8 @@ msgstr "Schlüsselliste"
#: keysign/send.ui:202
msgid ""
"<small>To have the key signed, the other person must enter the security code, "
"or scan the QR code</small>"
"<small>To have the key signed, the other person must enter the security "
"code, or scan the QR code</small>"
msgstr ""
"<small>Um den Key signiert zu bekommen, muss eine andere Person den "
"Sicherheitscode oder den Barcode scannen </small>"
......@@ -262,10 +328,27 @@ msgstr ""
msgid "<b>QR Code</b>"
msgstr ""
#: keysign/transtest.py:5
msgid "Hallo"
msgstr "yo!1"
#: keysign/send.ui:437
#, fuzzy
#| msgid "Select and send key"
msgid "Select and Send key"
msgstr "Key Auswählen und Senden"
#~ msgid "Keysign - Offering Key"
#~ msgstr "Keysign - Key Anbieten"
#~ msgid "Auxiliary helper program to present a key"
#~ msgstr ""
#~ msgid "increases log verbosity for each occurence."
#~ msgstr ""
#~ msgid "The fingerprint of the key to transfer"
#~ msgstr ""
#~ msgid "Hallo"
#~ msgstr "yo!1"
#~ msgid "Moinsen..."
#~ msgstr "Aha. Selber moinse."
#: keysign/transtest.py:6
msgid "Moinsen..."
msgstr "Aha. Selber moinse."
......@@ -8,43 +8,117 @@ msgid ""
msgstr ""
"Project-Id-Version: gnome-keysign 0.9\n"
"Report-Msgid-Bugs-To: tobiasmue@gnome.org\n"
"POT-Creation-Date: 2017-05-17 20:42+0200\n"
"POT-Creation-Date: 2017-12-15 13:39+0100\n"
"PO-Revision-Date: 2017-05-20 21:28+0200\n"
"Last-Translator: \n"
"Language: fr\n"
"Language-Team: fr <LL@li.org>\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
"Plural-Forms: nplurals=2; plural=(n > 1)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.4.0\n"
"Last-Translator: \n"
"X-Generator: Poedit 1.8.7.1\n"
"Generated-By: Babel 2.5.1\n"
#: keysign/app.py:162
#: data/gnome-keysign.raw.appdata.xml:10
msgid ""
"\n"
" GNOME-Keysign allows signing OpenPGP keys comfortably and securely\n"
" via the local network or Bluetooth.\n"
" "
msgstr ""
#: data/gnome-keysign.raw.appdata.xml:14
msgid ""
"\n"
" It can scan another key's barcode and transfer the key securely,\n"
" allowing for casual two-party key signing sessions.\n"
" It follows best practises by sending the encrypted signatures\n"
" to the UIDs of a key using the Email client the user configured\n"
" to use.\n"
" "
msgstr ""
#. Name
#: data/gnome-keysign.raw.desktop:2
msgid "Keysign"
msgstr ""
#. Comment
#: data/gnome-keysign.raw.desktop:3
msgid ""
"A keysigning helper to enable you to comfortably exchange OpenPGP keys "
"with a friend"
msgstr ""
#. Keywords
#: data/gnome-keysign.raw.desktop:4