Commit Graph

27246 Commits

Author SHA1 Message Date
Nick Hall 1d56e7d47a Merge pull request #1120 from DavidMStraub/main 2022-02-14 21:55:49 +00:00
David Straub 1849f11e5d Add unit test for python3 -m gramps 2022-02-14 21:52:00 +00:00
David Straub c0c491cffd Add __main__.py 2022-02-14 21:51:47 +00:00
Nick Hall 2e8d22ea4a Merge pull request #1018 from prculley/no_magic 2022-02-14 21:19:53 +00:00
prculley 261f651f3b Fix Check&Repair progress meter for Duplicated Gramps_ID check 2022-02-14 21:19:19 +00:00
prculley 86c47156e6 Fix no_magic for dbapi 2022-02-14 21:19:15 +00:00
Matthias Kemmer 410a64b142 Add CopyAll functionality to Ancestor gramplet 2022-02-14 20:51:02 +00:00
Nick Hall 0ff0104a68 Fix bug introduced when simplifying looping
Partially revert commit 7248f073f0.

Deleting items during list iteration can lead to problems. In this
case an infinite loop was introduced in PR #975.
2022-02-14 19:40:39 +00:00
Nick Hall e390bb7c5b Update gramps.pot 2022-02-14 17:44:19 +00:00
Nick Hall d88bb36ba7 Fix for renamed gramps.xml.in file
The file was renamed as part of PR #1143.
2022-02-14 17:44:19 +00:00
Andika Triwidada 220633862c Translated using Weblate (Indonesian)
Currently translated at 1.8% (130 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/id/
2022-02-14 17:44:05 +00:00
RiseT a353b2889f Translated using Weblate (German)
Currently translated at 100.0% (6915 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/de/
2022-02-14 17:44:05 +00:00
cedecode e3262e2d40 Translated using Weblate (German (Austria))
Currently translated at 100.0% (6915 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/de_AT/
2022-02-14 17:44:05 +00:00
Mukli Krisztián f13c53b5f7 Translated using Weblate (Hungarian)
Currently translated at 100.0% (6915 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/hu/
2022-02-14 17:44:05 +00:00
Avi Markovitz 26999c640a Translated using Weblate (Hebrew)
Currently translated at 100.0% (6915 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/he/
2022-02-14 17:44:05 +00:00
Mirko Leonhaeuser ff6d4b2754 Translated using Weblate (German)
Currently translated at 100.0% (6915 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/de/

Translated using Weblate (German)

Currently translated at 100.0% (6915 of 6915 strings)

Translation: Gramps/gramps
Translate-URL: https://hosted.weblate.org/projects/gramps-project/gramps/de/
2022-02-14 17:44:05 +00:00
Nick Hall 0b04c8ab77 Merge pull request #975 from Baizley/simplify_loops 2022-02-13 21:00:07 +00:00
Baizley 6d1105da81 Correct enumerations unpacking. 2022-02-13 20:49:25 +00:00
Baizley a9a1b7b57e Small code improvements. 2022-02-13 20:49:25 +00:00
Baizley 7248f073f0 Simplify looping across Gramps.
Index based loops across the Gramps project
are mapped to their Pythonic equalivant.

Many of these improves radability, and a
some of them improves performance by being
lazy evaluated.
2022-02-13 20:49:19 +00:00
Nick Hall 8777c11811 Merge pull request #974 from Baizley/simplify-error-construction-in-argument-parser 2022-02-13 20:38:16 +00:00
Baizley 8ca2ff5dad Refactor error construction into a common method. 2022-02-13 19:58:09 +00:00
Baizley 8a5c8ffbc9 Expand unit test for Gramps parsing error. 2022-02-13 19:58:09 +00:00
Baizley 1b53a3948a Simplify handling of getops error. 2022-02-13 19:58:09 +00:00
Baizley 178d3ecb00 Add unit test for handling getopt error. 2022-02-13 19:58:09 +00:00
Nick Hall ba09cda0d0 Merge pull request #970 from Baizley/simplify_get_name_format 2022-02-13 19:54:51 +00:00
Baizley 89c73db352 Correct continuation line unaligned for hanging indent 2022-02-13 19:43:25 +00:00
Baizley 3b5d324b95 Remove unused imports. 2022-02-13 19:43:25 +00:00
Baizley 99d589a7a2 Add tests for methods relying on name_formats.
The NameDisplay class contains various methods
that interact with the dict holding the
name formats.
To enable further refactoring, these methods
have been brought under test for most of
their implementations.
2022-02-13 19:43:25 +00:00
Baizley 080d1d1dca Correct the assumed order of the name formats.
This commit corrects the ordering to the one in
Gramps 5.1 when run on Python 3.3.
Unlike the implementation in 5.1, this
implementation does not rely on dict ordering
and will therefore be consistent across Python
versions.

The assumed order of ascending positives followed
by negatives in reverse order, was based on tests
run on Python 3.7. However, the current ordering
in Gramps 5.1 is depended on dict ordering which
has changed between Python versions.
The expected ordering is therefore taken as the
one in Gramps 5.1 run on Python 3.3, which is
what the CI environment tests on.
This ordering is positives followed by negatives
both in ascending order.
I.e. -2, -3, -1,  0,  1,  2,  3,  4,  5
  =>  0,  1,  2,  3,  4,  5, -1, -2, -3
2022-02-13 19:43:25 +00:00
Baizley 3cb4115ae4 Use list comprehension for name format list.
Combine construction and filtering with list
comprehension.

Adjust sort method to work over tuples.
2022-02-13 19:43:25 +00:00
Baizley b66b9b3727 Simplify sorting in get_name_format.
First, the simplification uses the
built-in cmp_to_key function from functools
to remove the duplicated function in the
class.

Second, the cmp function was reduced to
two cases:
1. When x and y is positive:
Here the st
2. When x or y is negative:
Here the sign of y determines the ordering,
which can be seen from the following cases:

1. x is negative, y is negative =>
their order needs to be, so y is considered
higher, which means x is considered lower
(negative).

2. x is negative, y is positive =>
x is considered higher (positive).

3. x is positive, y is negative =>
y is considered higher, which means x is
considered lower (negative).

Third, the sorting is abstracted away
behind a function declaring the sort order.
2022-02-13 19:43:25 +00:00
Baizley 02983370bd Add test coverage for get_name_format.
The test class enumaretes all possible
values for the three boolean arguments.
Some of the results is arguably wrong,
but since other classes depend on the
current semantics, these cases have
not been corrected.
2022-02-13 19:43:25 +00:00
André Apitzsch 727139f817 Remove xdg-utils dependency 2022-02-13 19:23:00 +00:00
Nick Hall 9bb252e405 Merge pull request #1143 from a-andre/reverseDNS 2022-02-13 19:00:02 +00:00
André Apitzsch 6fdde84334 Use reverse-DNS for mime file 2022-02-13 18:31:43 +00:00
André Apitzsch 2b50f55991 Fix application id 2022-02-13 18:31:43 +00:00
André Apitzsch 7ca75ef882 Use reverse-DNS for application icon 2022-02-13 18:31:30 +00:00
André Apitzsch 11f268b981 Use reverse-DNS scheme for appdata + desktop 2022-02-13 18:17:29 +00:00
Pino Toscano 79cc1970ad Move MIME icons together with other hicolor icons
Move the icons of MIME types in the same location/structure used for
the other hicolor icons (application icon, action icons).
This way, all the hicolor icons are logically in the same place.
2022-02-12 23:12:39 +00:00
Nick Hall a59b38d443 Merge pull request #1054 from CWSchulze/cws_godparent 2022-02-10 22:12:28 +00:00
Nick Hall c2f46da34f Fix unit test for check & repair tool 2022-02-10 22:08:56 +00:00
CWSchulze dbc999669b Add Godparent as event role 2022-02-10 22:08:56 +00:00
Nick Hall 62ee9d2c7d Merge pull request #1033 from bentley/rst-manpage 2022-02-09 23:01:06 +00:00
Nick Hall 8159aca9b4 Generate gramps.1.in file 2022-02-09 22:52:24 +00:00
Anthony J. Bentley ec64335eef Various grammar improvements in the English manpage 2022-02-09 22:51:27 +00:00
Anthony J. Bentley 20ea5a1254 Use HTTPS URLs in the English manpage 2022-02-09 22:50:12 +00:00
Anthony J. Bentley b6c9d1d965 Sprinkle Unicode trademarks and arrows within the English manpage 2022-02-09 22:50:12 +00:00
Anthony J. Bentley 31175616c1 Improve syntax of English manpage 2022-02-09 22:49:49 +00:00
Nick Hall 4039427e80 Merge pull request #1019 from prculley/bug11600 2022-02-09 21:21:46 +00:00