Compare commits
762 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
003de23ded | ||
|
1b58e7cd8a | ||
|
18c3ac1bf0 | ||
|
073b302687 | ||
|
2ed14d4929 | ||
|
1454474289 | ||
|
6b42681b08 | ||
|
8716b87689 | ||
|
e87e28501e | ||
|
7d121e8963 | ||
|
3f375261f3 | ||
|
4ab32f3b10 | ||
|
326f5c80c3 | ||
|
8faa02c176 | ||
|
a741d87c2e | ||
|
5f2ab46f2a | ||
|
c826d6c0d7 | ||
|
8040ce0ebd | ||
|
6f4b479b3f | ||
|
1de1e10659 | ||
|
6c67f25eb6 | ||
|
9771ed0f34 | ||
|
a02ef0fc8e | ||
|
990ba0457e | ||
|
e40ce4c76f | ||
|
6c196cdfe6 | ||
|
64e0ed1e31 | ||
|
2899990d1b | ||
|
f97e8ef621 | ||
|
822c267e0c | ||
|
5f70dd3af6 | ||
|
3dad5a32b4 | ||
|
4b69296158 | ||
|
e577b1569d | ||
|
18cbf82142 | ||
|
15cb5c8565 | ||
|
f1a0a703bc | ||
|
b3237e146b | ||
|
f524528cdc | ||
|
cf8341a8a6 | ||
|
57411ab25e | ||
|
ccad231d43 | ||
|
5d6a47be90 | ||
|
c7071bd9dd | ||
|
77ea97d533 | ||
|
1d2232bf47 | ||
|
c6ce33c35a | ||
|
4349a4d675 | ||
|
45a5a85963 | ||
|
a6e318a53a | ||
|
d3b706d1ff | ||
|
b3b6899424 | ||
|
39af1b9f6c | ||
|
22fc9958e6 | ||
|
991740e333 | ||
|
2cca179793 | ||
|
892eccf251 | ||
|
2e60dae5db | ||
|
219ca05113 | ||
|
90687fed1b | ||
|
f3acd4808c | ||
|
c5703feb8d | ||
|
91ca39af06 | ||
|
6ce41cb21a | ||
|
5bf3a88dd6 | ||
|
25047a6918 | ||
|
04e7df5425 | ||
|
1d63127e5c | ||
|
516ce38a54 | ||
|
fa41eaf6a3 | ||
|
53512286d8 | ||
|
b9ebcb13d5 | ||
|
3d23affc8a | ||
|
83ebd2658b | ||
|
670c47d9d9 | ||
|
1ac29c6e76 | ||
|
457d1b38a8 | ||
|
7611cacc13 | ||
|
26b785b3e8 | ||
|
fca6091ebd | ||
|
1118476e38 | ||
|
91a30eaaed | ||
|
4abb1fb142 | ||
|
1e03f28138 | ||
|
ff01477003 | ||
|
e795d5e7f8 | ||
|
2f0788f709 | ||
|
58bb9dd6d4 | ||
|
0ead3ea145 | ||
|
0bb8426e64 | ||
|
086732a6b4 | ||
|
0fb88fb531 | ||
|
4a299d79a7 | ||
|
fc8f750338 | ||
|
454180dcec | ||
|
f31c22cdaa | ||
|
865d32e042 | ||
|
87306fcf57 | ||
|
ded3b12080 | ||
|
d551e2b5e4 | ||
|
58f59a5d67 | ||
|
757a6a721b | ||
|
fb22b83f14 | ||
|
88c7dfd37d | ||
|
a87b221292 | ||
|
6f4b3cef8d | ||
|
b470d75c13 | ||
|
3c7a9ec14b | ||
|
a360db221f | ||
|
1fb9773e16 | ||
|
8afb1e4c29 | ||
|
98d3606aff | ||
|
2b3c2190d8 | ||
|
ce7181a96d | ||
|
7c205bf7fc | ||
|
9b109884ad | ||
|
2d75b21b9e | ||
|
09306a357c | ||
|
022ff28d94 | ||
|
2cec980066 | ||
|
8b452f95cb | ||
|
a6f464592a | ||
|
45849a93a6 | ||
|
1d470340cc | ||
|
9bbecacd9f | ||
|
c6cdfe827f | ||
|
8c9acb6ef3 | ||
|
18b34eea90 | ||
|
1b0c7815da | ||
|
6ea9a5ad70 | ||
|
70ee3d822f | ||
|
f60212f191 | ||
|
6ed2aa9a0d | ||
|
f5bae80cf3 | ||
|
9246af61a3 | ||
|
a0cae8afcf | ||
|
de88bb34c0 | ||
|
221020cca0 | ||
|
bc7abbd85a | ||
|
caa75a3b2c | ||
|
5d180993be | ||
|
f2de23047c | ||
|
fc1a5d453b | ||
|
d18e001324 | ||
|
e2c726831a | ||
|
7399bc73d1 | ||
|
530e561537 | ||
|
26ebc3bda7 | ||
|
570d0e1ac1 | ||
|
f6c39ffe17 | ||
|
da36417690 | ||
|
b30869c6a4 | ||
|
3dcc029dbd | ||
|
dc1d12947e | ||
|
89b6d05fd4 | ||
|
4dd28d5532 | ||
|
5c13786ac4 | ||
|
e2be8e2875 | ||
|
42f014efeb | ||
|
59ed4f8a8f | ||
|
07db07eb87 | ||
|
f9e8c90b7d | ||
|
f405ef9f3a | ||
|
7a012c2790 | ||
|
bc1b99a85e | ||
|
34bb0b7769 | ||
|
391155d14b | ||
|
1436945239 | ||
|
f657238034 | ||
|
821bf3b740 | ||
|
8ce27e1be6 | ||
|
c338c75953 | ||
|
001b520199 | ||
|
c6f926188a | ||
|
badaa407f6 | ||
|
14575a3bc8 | ||
|
edd40cafa3 | ||
|
50e43f51c9 | ||
|
ea0a839ab1 | ||
|
9284223d4b | ||
|
7c2469a3ca | ||
|
7005b63a43 | ||
|
70345ef4b8 | ||
|
f2d7e62fc0 | ||
|
c032fc8dae | ||
|
15f7b45d3f | ||
|
9c44e4500f | ||
|
8aa2a6aa24 | ||
|
fa35769714 | ||
|
53b67443f2 | ||
|
feb36c5ce4 | ||
|
b0a159ee2f | ||
|
6d57f08ac0 | ||
|
9fc255371d | ||
|
706e92be77 | ||
|
16cfc2af23 | ||
|
77adb230c5 | ||
|
9503faed70 | ||
|
1e1e57c576 | ||
|
fecaba830e | ||
|
5d13d706b6 | ||
|
7ec9f36fe2 | ||
|
d8b04d281d | ||
|
dcb84fd166 | ||
|
3127dc08e2 | ||
|
58c2b11013 | ||
|
d674eed2d4 | ||
|
751ac2aef0 | ||
|
eb63ae3d8e | ||
|
6f7c65a038 | ||
|
1e598e846a | ||
|
9f1ec6daf6 | ||
|
044452805b | ||
|
5d3735123e | ||
|
89847f1df3 | ||
|
f7a0036a41 | ||
|
b1b5b1dbfb | ||
|
24414d6285 | ||
|
86f069e05a | ||
|
40219c0b83 | ||
|
84c9e42d96 | ||
|
1cf906be39 | ||
|
e0ed05653d | ||
|
b7b2ba690a | ||
|
8725f2e236 | ||
|
ca4c231eaa | ||
|
cb6a42364b | ||
|
f6b043da6f | ||
|
f4aecf48c1 | ||
|
e4af48c0f3 | ||
|
bca4e0852f | ||
|
4862a5e072 | ||
|
516cc588c6 | ||
|
ad8908fe96 | ||
|
7b98d528f1 | ||
|
342ea53dae | ||
|
396de3564b | ||
|
9e5922d13c | ||
|
35f6cba4f4 | ||
|
72014d89e3 | ||
|
1b1a0e5e92 | ||
|
5cfbeda670 | ||
|
4c8b259002 | ||
|
df537dee58 | ||
|
5d29b90dcc | ||
|
a131ed20e4 | ||
|
b240d979de | ||
|
1e5ae4aa4d | ||
|
d167d8db03 | ||
|
a182a68b9f | ||
|
0ba9247e64 | ||
|
2105312fdf | ||
|
b1b1308343 | ||
|
5dc89962ba | ||
|
2eafc3ca08 | ||
|
3aae88f9c2 | ||
|
d4ed73da0e | ||
|
bc26b54d3e | ||
|
3edf31ebbc | ||
|
b0e80e74b5 | ||
|
9979fd8792 | ||
|
5fc65f68ea | ||
|
496cf30d6b | ||
|
2eeba5a9ae | ||
|
78ada9190c | ||
|
434d45ffd1 | ||
|
028c832153 | ||
|
2cb36a7fb4 | ||
|
4526da77ce | ||
|
40db10e378 | ||
|
7a7e95410a | ||
|
c7b6e840f0 | ||
|
576dcb30d6 | ||
|
b204a48b42 | ||
|
8fe756f5e4 | ||
|
0303212d49 | ||
|
a67b7b7d11 | ||
|
019ad16239 | ||
|
d62b34125c | ||
|
52b7276c7d | ||
|
75a02b10d7 | ||
|
3f2d9f6219 | ||
|
efdaa1fd14 | ||
|
7ee109ea98 | ||
|
cd4585b100 | ||
|
444a3f4c12 | ||
|
d3d80b443e | ||
|
9d8d1576b4 | ||
|
ba12b62810 | ||
|
49ed4e0f53 | ||
|
85300edd61 | ||
|
bc6c23bc65 | ||
|
2e7e0d7666 | ||
|
cb2b4a1514 | ||
|
07edb59c83 | ||
|
684fd1b6df | ||
|
f9a872ad67 | ||
|
cfd162ec85 | ||
|
c5982a4514 | ||
|
1975ca92b7 | ||
|
75e3385777 | ||
|
10eb31e708 | ||
|
e0ccf7e330 | ||
|
8ef935804e | ||
|
594f273260 | ||
|
a421439a76 | ||
|
7ac463b03b | ||
|
38a68f4fd2 | ||
|
9fecd1aa53 | ||
|
5fca8311f5 | ||
|
4260777605 | ||
|
b4c225fc35 | ||
|
da8cb286cd | ||
|
2f0cf7d5b6 | ||
|
4c8d6a3215 | ||
|
4ca275e5b2 | ||
|
a581dda843 | ||
|
7da053e88e | ||
|
9cad62547e | ||
|
0cacbc4c16 | ||
|
f2f148b7ba | ||
|
67b6abb3df | ||
|
1f94813e59 | ||
|
7d90a49fba | ||
|
c73cb0e70a | ||
|
49cf845b53 | ||
|
f3859a2fb9 | ||
|
40076dd093 | ||
|
8a290a14a4 | ||
|
cbb8d063df | ||
|
47be9a4e02 | ||
|
b84ad06523 | ||
|
5a9686bad7 | ||
|
4064b9917f | ||
|
0c791b2d14 | ||
|
42d8a95512 | ||
|
d5e63a30d5 | ||
|
70f4ed3b32 | ||
|
8bbc216d17 | ||
|
d135d2f55b | ||
|
8835e3f133 | ||
|
93e95ad7da | ||
|
a0016381c4 | ||
|
6e8435baab | ||
|
d72ef5e5dc | ||
|
01f6e3e79e | ||
|
3eed3217f4 | ||
|
a4314abb61 | ||
|
393323a670 | ||
|
764f17b935 | ||
|
1f38fd43f5 | ||
|
38cc711bde | ||
|
bdcc43b911 | ||
|
b8f2f13e33 | ||
|
738c95dedc | ||
|
820816f409 | ||
|
a713d5c388 | ||
|
8af82fae08 | ||
|
da39d249de | ||
|
56136e1083 | ||
|
063efad45f | ||
|
b885391182 | ||
|
0e195c04c8 | ||
|
6e525893bd | ||
|
e4202098b7 | ||
|
2629bf3dee | ||
|
0fda971b4c | ||
|
651b3776f0 | ||
|
cfea1e98dc | ||
|
901ec7dc5c | ||
|
06df52881e | ||
|
13bb98be10 | ||
|
9c0f85b3c2 | ||
|
5d1a7e3b4e | ||
|
553d82ba34 | ||
|
bd61f08873 | ||
|
13a49a63ff | ||
|
3a73837dc9 | ||
|
3490ebc684 | ||
|
2ebec70e21 | ||
|
87d91cdc20 | ||
|
6a23860df2 | ||
|
af3e34fef5 | ||
|
1a5ad3b6f7 | ||
|
a323c33c30 | ||
|
5ecdde56f4 | ||
|
aa21c636b2 | ||
|
f84cc66c58 | ||
|
61046f3b75 | ||
|
2dab9b146e | ||
|
54320efc45 | ||
|
113fbcfc7f | ||
|
7e8cc02568 | ||
|
cd7b83086d | ||
|
fab25576db | ||
|
d7b4bab8a9 | ||
|
c861968fd3 | ||
|
3cba0f2089 | ||
|
3e3f5c0baf | ||
|
80db60b332 | ||
|
c06e8d3b64 | ||
|
c19c5e2569 | ||
|
992b161798 | ||
|
2dee2c4d77 | ||
|
96440156bd | ||
|
588089954a | ||
|
7e749a9e25 | ||
|
3e0fd433b5 | ||
|
8a4732a5d2 | ||
|
8371684a98 | ||
|
2828211c6a | ||
|
bf67b3e114 | ||
|
d01f7bf7df | ||
|
1d2b143be9 | ||
|
debf8b601a | ||
|
bcef9fc868 | ||
|
fae194d1a0 | ||
|
7aa1c2bbde | ||
|
2528da2f2d | ||
|
8ea29ede81 | ||
|
4ca0c9f8c9 | ||
|
5a8a7479dd | ||
|
c3f39e7d40 | ||
|
5235a6a6ac | ||
|
62475bbc87 | ||
|
a33eb1d799 | ||
|
6e73fc8924 | ||
|
06b8b291f8 | ||
|
98fa69b717 | ||
|
7c9ec32d22 | ||
|
e1fb1c5b14 | ||
|
7541dd5b2e | ||
|
e8bad4d4c8 | ||
|
d704d9ac4b | ||
|
d334e0043f | ||
|
dede164e69 | ||
|
f309f210d1 | ||
|
ebe1d0139c | ||
|
ebcd0bb119 | ||
|
fc8eb4f445 | ||
|
3ae8e5cc1e | ||
|
a03877e8c9 | ||
|
357eb8af19 | ||
|
c91eec3d5f | ||
|
870f80fc83 | ||
|
3ee5b1dec4 | ||
|
c37bfc9dbe | ||
|
bb494a56ca | ||
|
4a512c7347 | ||
|
e6034cde4b | ||
|
5e9837d484 | ||
|
57fcc67498 | ||
|
3872899ebc | ||
|
ad20c91b4f | ||
|
5df0c7d3ee | ||
|
daae9242bf | ||
|
114a71c13c | ||
|
7d7cc6f789 | ||
|
b99e2e29df | ||
|
44f065eabf | ||
|
b126aa1fc3 | ||
|
e2860c99f6 | ||
|
6cd609941f | ||
|
4a23da9500 | ||
|
73cdf3d86f | ||
|
d24586eb34 | ||
|
158a5f93fb | ||
|
7ff24aa9d1 | ||
|
bb2bcc4185 | ||
|
c8254b1c68 | ||
|
8d06298921 | ||
|
4621970783 | ||
|
123a6e0ecf | ||
|
3d0fa7a00a | ||
|
400523c7f3 | ||
|
0bbbc76852 | ||
|
252d2932df | ||
|
bffb6767aa | ||
|
0c07855f37 | ||
|
088c97106f | ||
|
bfa28faf55 | ||
|
8222d4c04c | ||
|
879c48f57d | ||
|
7127f8f2da | ||
|
db9daced3c | ||
|
c42cb6beee | ||
|
efa53a0537 | ||
|
bbf16cb40c | ||
|
d62ff6059e | ||
|
f3361500c0 | ||
|
df1157e9d4 | ||
|
11ad512f2d | ||
|
fd559d0d80 | ||
|
7a894d9a41 | ||
|
b6b3fb8680 | ||
|
755b653925 | ||
|
592f68ab6e | ||
|
0986d69429 | ||
|
98898ddb71 | ||
|
8cbba85cf1 | ||
|
c01846fb84 | ||
|
fccfdecd03 | ||
|
3f408af0fa | ||
|
8cea2e239a | ||
|
221c30976f | ||
|
e28e114c95 | ||
|
3788d52107 | ||
|
740c7036d7 | ||
|
eeaf8697f0 | ||
|
3fabbe1ecb | ||
|
d10d572002 | ||
|
3d0fa69bd0 | ||
|
a84d51d6b7 | ||
|
88831f8398 | ||
|
945bec0d6c | ||
|
dfb6be488d | ||
|
22bcc94ec0 | ||
|
d02f6a3fb1 | ||
|
76eae75da2 | ||
|
657d8e233f | ||
|
5bb9581b15 | ||
|
d6c4298ff4 | ||
|
260170ce36 | ||
|
801f1b77aa | ||
|
d5dfa05ff9 | ||
|
808002d419 | ||
|
4dc0f01137 | ||
|
aa7e0b49e4 | ||
|
3c103143a6 | ||
|
ef65c893ea | ||
|
566c3fb32b | ||
|
db1bd1e114 | ||
|
866796f5dc | ||
|
fdf740b35c | ||
|
1500556d99 | ||
|
5e4b2d3bdc | ||
|
880e6c44e7 | ||
|
4068bebb3e | ||
|
0465b9cf37 | ||
|
fed5cc6a71 | ||
|
69800680a3 | ||
|
a3a758fd13 | ||
|
eadae6dbc9 | ||
|
3ee843917e | ||
|
43c49238f5 | ||
|
641155478f | ||
|
6ca692e33a | ||
|
41fdca39dd | ||
|
bb3ac61359 | ||
|
a00a5ba32d | ||
|
efdb6e9fd5 | ||
|
ff12fdc4a3 | ||
|
3ef8a88a11 | ||
|
117b5b6594 | ||
|
6a5a78eee0 | ||
|
ba28adea94 | ||
|
17f938c978 | ||
|
54034d4811 | ||
|
45fc795964 | ||
|
0d9884186a | ||
|
e593d753ee | ||
|
2cd6aa43e4 | ||
|
7c82a5df48 | ||
|
23baca2f09 | ||
|
02fd2409c5 | ||
|
3b4496a808 | ||
|
235a1e72fd | ||
|
1af985dbc7 | ||
|
378f24272c | ||
|
6bc5bcf644 | ||
|
efbd0e95dd | ||
|
45a6524247 | ||
|
13c58292e3 | ||
|
5d8e37807c | ||
|
5feda5f56c | ||
|
5d46ae352d | ||
|
4c622a7b0f | ||
|
7e7ae7c42b | ||
|
0e172acd4c | ||
|
c221c1076a | ||
|
b2ae97c544 | ||
|
38f29ece86 | ||
|
383bd9548a | ||
|
97a37439d2 | ||
|
3ba99eb0b0 | ||
|
1e02a60f14 | ||
|
a5ffbb5e08 | ||
|
c36181d024 | ||
|
d91be2fd0b | ||
|
b23699d9ce | ||
|
313dcb77c2 | ||
|
348fa98341 | ||
|
7ac6856b60 | ||
|
e60ffbf83b | ||
|
5735799057 | ||
|
0446b7405d | ||
|
7be387e8fd | ||
|
f0cc7f35d6 | ||
|
b7d5bed60a | ||
|
c56fb05d1c | ||
|
64a8895df9 | ||
|
afefbeedf8 | ||
|
64ca5d105f | ||
|
1d3a687c0c | ||
|
fb56547589 | ||
|
e91a06dc1b | ||
|
096e57e36a | ||
|
44ea1b0fa8 | ||
|
3c75de2327 | ||
|
ca287ac12e | ||
|
bb392985f0 | ||
|
0625ed8109 | ||
|
5824a674d6 | ||
|
ee7ef78f6d | ||
|
6a287a6018 | ||
|
92ba36c349 | ||
|
54fd78c12a | ||
|
adb8a084a4 | ||
|
c133edec8e | ||
|
d3f8f73180 | ||
|
c081c5f6f5 | ||
|
41b4634d52 | ||
|
26ac4a6856 | ||
|
d4cd826b6f | ||
|
bd65cfcbea | ||
|
8bf43ccabb | ||
|
faac8fef8a | ||
|
1f825771b5 | ||
|
e677f40cab | ||
|
f9305d9e7f | ||
|
80625063a0 | ||
|
5923610e80 | ||
|
904dd024c6 | ||
|
a4abc9f26a | ||
|
f4e6ffb4be | ||
|
385641f092 | ||
|
e292eb0400 | ||
|
af953dec7c | ||
|
9a6f472ffd | ||
|
c572259d25 | ||
|
e613f02469 | ||
|
722f0f7589 | ||
|
2255acaa62 | ||
|
cac68a4110 | ||
|
599fe33470 | ||
|
222525e035 | ||
|
94d452d63c | ||
|
b30220b72b | ||
|
1604af190d | ||
|
711aba5272 | ||
|
2aa9aa1f48 | ||
|
d62e751285 | ||
|
2553cdc642 | ||
|
15e44633cf | ||
|
e5194e1462 | ||
|
af9f421d3f | ||
|
a3a8444fbe | ||
|
3401e86c60 | ||
|
4b6a95f211 | ||
|
d1765efa49 | ||
|
0bd44eeb84 | ||
|
32b6b27dca | ||
|
7dd022bddf | ||
|
642f837658 | ||
|
5f24c8834c | ||
|
d60bbe812b | ||
|
eee79d223b | ||
|
ddd1aae5c3 | ||
|
17824534cb | ||
|
a8c1530436 | ||
|
47fd0cf00f | ||
|
5105b4fd44 | ||
|
5b8d5b739a | ||
|
bb9601a2a0 | ||
|
81e1237b3c | ||
|
236da6da81 | ||
|
ca9f5de077 | ||
|
36008d3abe | ||
|
80d73f058c | ||
|
8d19b0198f | ||
|
9c69c3523e | ||
|
cae2814c97 | ||
|
421882c0e8 | ||
|
49585e1e96 | ||
|
904397ff11 | ||
|
5aa70b08a6 | ||
|
d080d15352 | ||
|
f3c4314a89 | ||
|
2284694530 | ||
|
15edee3a26 | ||
|
d0e698ffac | ||
|
addfaa933f | ||
|
e2fc32c4c0 | ||
|
46e8d865b1 | ||
|
c208b91184 | ||
|
ab6342af70 | ||
|
715ddbbab3 | ||
|
cc936c589b | ||
|
f554ffd57d | ||
|
46e9edaf59 | ||
|
29620a31ef | ||
|
ca2fd738d0 | ||
|
821caa8a5f | ||
|
3a45e70f54 | ||
|
89f6c7d83e | ||
|
ca73e01512 | ||
|
bfcecc646d | ||
|
77f9760504 | ||
|
3a93d03a4a | ||
|
03851db458 | ||
|
9f87dfd54b | ||
|
711e25e5bb | ||
|
f1eecb349d | ||
|
04baa6b50f | ||
|
c18d73ea8f | ||
|
671f64c08c | ||
|
b9cd27550f | ||
|
8b26f688cb | ||
|
e41c6db70d | ||
|
fdcc02d1bd | ||
|
f4f5104b72 | ||
|
0caf61b805 | ||
|
c46a66ecd1 | ||
|
35d553b4eb | ||
|
8bc6d475d9 | ||
|
b5fec9d1a3 | ||
|
1a5c516179 | ||
|
054d29612c | ||
|
ad066ba200 | ||
|
ffb3b1e232 | ||
|
76c896f977 | ||
|
5e00312139 | ||
|
c7ad3f3295 | ||
|
11723ffd8c | ||
|
cb9bebee1e | ||
|
a9ac56b33c | ||
|
19038fab93 | ||
|
fd13311aa0 | ||
|
ec0b9fb54b | ||
|
8b94955772 | ||
|
9a229466fd | ||
|
647c9cfef5 | ||
|
29443339cb | ||
|
f4f2747c65 | ||
|
ba7913fe3c | ||
|
5526f64e1f | ||
|
0a17eab461 | ||
|
fcce312e0a | ||
|
4ed2b0bace | ||
|
759075b3e4 | ||
|
7f4956dd00 | ||
|
e1ab03348e | ||
|
2033fd6567 | ||
|
7c6872c11a | ||
|
71f87a31b3 | ||
|
eb2ca43ff6 | ||
|
71b951f31d | ||
|
a542081e25 | ||
|
5b8da49bae | ||
|
4d7e1043ef | ||
|
2040716b9c | ||
|
8a3a477ea4 |
.gitignoreGramps.pyINSTALLMANIFEST.inNEWSREADMERELEASE_NOTES
data
authors.xmllds.xml
man
papersize.xmltemplates
404.html500.html
tips.xml.inadmin
browse_page.htmldetail_breadcrumb.htmlgramps-base.htmlmain_page.htmlpaginator.htmlpick.htmlreference.htmlregistration
table_header.htmluser_page.htmlview_citation_detail.htmlview_citations.htmlview_event_detail.htmlview_events.htmlview_families.htmlview_family_detail.htmlview_media.htmlview_media_detail.htmlview_name_detail.htmlview_note_detail.htmlview_notes.htmlview_page.htmlview_page_detail.htmlview_people.htmlview_person_detail.htmlview_place_detail.htmlview_places.htmlview_report.htmlview_report_detail.htmlview_repositories.htmlview_repository.htmlview_repository_detail.htmlview_source_detail.htmlview_sources.htmlview_surname_detail.htmlview_tag.htmlview_tag_detail.htmlview_tags.htmldebian
docs
example/gramps
gramps
cli
data
gen
config.pyconst.pyconstfunc.py
grampsapp.pydatehandler
db
display
filters
_filterlist.py_filterparser.py
ggettext.pyrules
_changedsincebase.py_everything.py_hasattributebase.py_hascitationbase.py_haseventbase.py_hasgallerybase.py_hasgrampsid.py_hasldsbase.py_hasnotebase.py_hasnoteregexbase.py_hasnotesubstrbase.py_hasreferencecountbase.py_hassourcebase.py_hassourcecountbase.py_hassourceofbase.py_hastagbase.py_hastextmatchingregexpof.py_hastextmatchingsubstringof.py_isprivate.py_ispublic.py_matcheseventfilterbase.py_matchesfilterbase.py_matchessourceconfidencebase.py_matchessourcefilterbase.py_regexpidbase.py_rule.py
citation
_allcitations.py_changedsince.py_citationprivate.py_hascitation.py_hasgallery.py_hasidof.py_hasnote.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasreferencecountof.py_hassource.py_matchesfilter.py_matchespagesubstringof.py_matchesrepositoryfilter.py_matchessourcefilter.py_regexpidof.py
event
_allevents.py_changedsince.py_eventprivate.py_hasattribute.py_hascitation.py_hasdata.py_hasgallery.py_hasidof.py_hasnote.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasreferencecountof.py_hassourcecount.py_hastype.py_matchesfilter.py_matchespersonfilter.py_matchessourceconfidence.py_matchessourcefilter.py_regexpidof.py
family
__init__.py_allfamilies.py_changedsince.py_childhasidof.py_childhasnameof.py_familyprivate.py_fatherhasidof.py_fatherhasnameof.py_hasattribute.py_hascitation.py_hasevent.py_hasgallery.py_hasidof.py_haslds.py_hasnote.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasreferencecountof.py_hasreltype.py_hassourcecount.py_hassourceof.py_hastag.py_hastwins.py_isbookmarked.py_matchesfilter.py_matchessourceconfidence.py_motherhasidof.py_motherhasnameof.py_regexpchildname.py_regexpfathername.py_regexpidof.py_regexpmothername.py_searchchildname.py_searchfathername.py_searchmothername.py
media
_allmedia.py_changedsince.py_hasattribute.py_hascitation.py_hasidof.py_hasmedia.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasreferencecountof.py_hassourcecount.py_hassourceof.py_hastag.py_matchesfilter.py_matchessourceconfidence.py_mediaprivate.py_regexpidof.py
note
__init__.py_allnotes.py_changedsince.py_hasidof.py_hasnote.py_hasreferencecountof.py_hastag.py_hastype.py_matchesfilter.py_matchesregexpof.py_matchessubstringof.py_noteprivate.py_regexpidof.py
person
_changedsince.py_deeprelationshippathbetween.py_disconnected.py_everyone.py_familywithincompleteevent.py_hasaddress.py_hasalternatename.py_hasassociation.py_hasattribute.py_hasbirth.py_hascitation.py_hascommonancestorwith.py_hascommonancestorwithfiltermatch.py_hasdeath.py_hasevent.py_hasfamilyattribute.py_hasfamilyevent.py_hasgallery.py_hasidof.py_haslds.py_hasnameof.py_hasnameorigintype.py_hasnametype.py_hasnickname.py_hasnote.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasrelationship.py_hassourcecount.py_hassourceof.py_hastag.py_hastextmatchingregexpof.py_hastextmatchingsubstringof.py_hasunknowngender.py_havealtfamilies.py_havechildren.py_incompletenames.py_isancestorof.py_isancestoroffiltermatch.py_isbookmarked.py_ischildoffiltermatch.py_isdefaultperson.py_isdescendantfamilyof.py_isdescendantfamilyoffiltermatch.py_isdescendantof.py_isdescendantoffiltermatch.py_isduplicatedancestorof.py_isfemale.py_islessthannthgenerationancestorof.py_islessthannthgenerationancestorofbookmarked.py_islessthannthgenerationancestorofdefaultperson.py_islessthannthgenerationdescendantof.py_ismale.py_ismorethannthgenerationancestorof.py_ismorethannthgenerationdescendantof.py_isparentoffiltermatch.py_isrelatedwith.py_issiblingoffiltermatch.py_isspouseoffiltermatch.py_iswitness.py_matcheseventfilter.py_matchesfilter.py_matchessourceconfidence.py_matchidof.py_missingparent.py_multiplemarriages.py_nevermarried.py_nobirthdate.py_nodeathdate.py_peopleprivate.py_peoplepublic.py_personwithincompleteevent.py_probablyalive.py_regexpidof.py_regexpname.py_relationshippathbetween.py_relationshippathbetweenbookmarks.py_searchname.py
place
_allplaces.py_changedsince.py_hascitation.py_hasgallery.py_hasidof.py_hasnolatorlon.py_hasnote.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasplace.py_hasreferencecountof.py_hassourcecount.py_hassourceof.py_inlatlonneighborhood.py_matcheseventfilter.py_matchesfilter.py_matchessourceconfidence.py_placeprivate.py_regexpidof.py
repository
_allrepos.py_changedsince.py_hasidof.py_hasnotematchingsubstringof.py_hasnoteregexp.py_hasreferencecountof.py_hasrepo.py_matchesfilter.py_matchesnamesubstringof.py_regexpidof.py_repoprivate.py
source
lib
attrtype.pychildreftype.pydate.pyeventroletype.pyeventtype.pyfamilyreltype.pygrampstype.pyldsord.pymarkertype.pymediaobj.pynameorigintype.pynametype.pynotetype.pyperson.pyrepotype.pysrcmediatype.pystyledtexttagtype.pysurnamebase.pytableobj.pyurltype.py
merge
diff.pymergecitationquery.pymergeeventquery.pymergefamilyquery.pymergemediaquery.pymergenotequery.pymergepersonquery.pymergeplacequery.pymergerepositoryquery.pymergesourcequery.py
test
mime
plug
proxy
recentfiles.pyrelationship.pysimple
sort.pysoundex.pysvn_revision.pyupdatecallback.pyutils
gui
aboutdialog.pyautocomp.pybasesidebar.pyclipboard.pycolumnorder.pyconfigure.pydbloader.pydbman.pydialog.pydisplay.pydisplaystate.py
editors
addmedia.py
displaytabs
addrembedlist.pyattrembedlist.pybackreflist.pybackrefmodel.pybuttontab.pycitationembedlist.pydataembedlist.pyembeddedlist.pyeventembedlist.pyeventrefmodel.pyfamilyldsembedlist.pygallerytab.pygroupembeddedlist.pyldsembedlist.pylocationembedlist.pynameembedlist.pynamemodel.pynotetab.pypersoneventembedlist.pypersonrefembedlist.pyrepoembedlist.pysurnametab.pywebembedlist.py
editaddress.pyeditattribute.pyeditchildref.pyeditcitation.pyeditdate.pyeditevent.pyediteventref.pyeditfamily.pyeditldsord.pyeditlink.pyeditlocation.pyeditmedia.pyeditmediaref.pyeditname.pyeditnote.pyeditperson.pyeditpersonref.pyeditplace.pyeditprimary.pyeditreporef.pyeditrepository.pyeditsource.pyedittaglist.pyediturl.pyfiltereditor.pyobjectentries.pyfilters
glade.pyglade
grampsgui.pylistmodel.pylogger
makefilter.pymerge
mergecitation.pymergeevent.pymergefamily.pymergemedia.pymergenote.pymergeperson.pymergeplace.pymergerepository.pymergesource.py
navigator.pyplug
_dialogs.py_guioptions.py_windows.py
export
quick
report
_bookdialog.py_docreportdialog.py_graphvizreportdialog.py_papermenu.py_reportdialog.py_stylecombobox.py_styleeditor.py
tool.pyselectors
baseselector.pyselectcitation.pyselectevent.pyselectfamily.pyselectnote.pyselectobject.pyselectperson.pyselectplace.pyselectrepository.pyselectsource.py
spell.pythumbnails.pytipofday.pyundohistory.pyutils.pyviewmanager.pyviews
widgets
guiQML
plugins
docgen
drawreport
export
exportcsv.pyexportftree.pyexportgedcom.pyexportgeneweb.pyexportpkg.pyexportvcalendar.pyexportvcard.pyexportxml.py
test
gramplet
ageondategramplet.pyagestats.pyattributes.pyattributesgramplet.pybacklinks.pycalendargramplet.pychildren.pycitations.pydescendgramplet.pyeditexifmetadata.pyevents.pyfanchartdescgramplet.pyfanchartgramplet.pyfaqgramplet.pygivennamegramplet.pygramplet.gpr.pynotes.pypedigreegramplet.pypersondetails.pypersonresidence.pyplacedetails.pyquickviewgramplet.pyrecordsgramplet.pyrelativegramplet.pyrepositorydetails.pysessionloggramplet.pystatsgramplet.pysurnamecloudgramplet.pytodo.pytodogramplet.pytopsurnamesgramplet.pywelcomegramplet.pywhatsnext.py
graph
importer
import.gpr.pyimportcsv.pyimportgedcom.pyimportgeneweb.pyimportgpkg.pyimportgrdb.pyimportprogen.pyimportvcard.pyimportxml.py
test
lib
holidays.xml.inlibcairodoc.pylibgedcom.pylibgrdb.pylibholiday.pylibhtml.pylibhtmlconst.pylibmetadata.pylibnarrate.pylibpersonview.pylibplaceview.pylibplugins.gpr.pylibrecords.pylibtranslate.pylibtreebase.py
maps
mapservices
quickview
ageondate.pyall_events.pyall_relations.pyattributematch.pyfilterbyname.pylineage.pylinkreferences.pyonthisday.pyreferences.pyreporef.pysamesurnames.pysiblings.py
rel
sidebar
textreport
alphabeticalindex.pyancestorreport.pybirthdayreport.pycustombooktext.pydescendreport.pydetancestralreport.pydetdescendantreport.pyendoflinereport.pyfamilygroup.pyindivcomplete.pykinshipreport.pynumberofancestorsreport.pyplacereport.pyrecordsreport.pysimplebooktitle.pysummary.pytableofcontents.pytagreport.pytextplugins.gpr.py
tool
changenames.pychangetypes.pycheck.pydateparserdisplaytest.pydesbrowser.pydumpgenderstats.pyeval.pyeventcmp.pyeventnames.pyextractcity.pyfinddupes.pyleak.pymediamanager.pymergecitations.pynotrelated.pyownereditor.pypatchnames.gladepatchnames.pyphpgedviewconnector.pyrebuild.pyrebuildgenderstat.pyrebuildrefmap.pyrelcalc.pyremoveunused.gladeremoveunused.pyreorderids.pysortevents.pysoundgen.pytestcasegenerator.pyverify.py
view
citationlistview.pycitationtreeview.pydashboardview.pyeventview.pyfamilyview.pyfanchartdescview.pyfanchartview.pygeoclose.pygeoevents.pygeofamclose.pygeofamily.pygeography.gpr.pygeomoves.pygeoperson.pygeoplaces.pyhtmlrenderer.gpr.pyhtmlrenderer.pymediaview.pynoteview.pypedigreeview.pypersonlistview.pypersontreeview.pyplacelistview.pyplacetreeview.pyrelview.pyrepoview.pysourceview.pyview.gpr.py
webreport
webstuff
test
version.pywebapp
images
16x16
geo-fixed-zoom.pnggeo-free-zoom.pnggeo-place-add.pnggeo-place-link.pnggeo-show-event.pnggeo-show-family.pnggeo-show-person.pnggeo-show-place.pnggramps-address.pnggramps-attribute.pnggramps-bookmark-delete.pnggramps-bookmark-edit.pnggramps-bookmark-new.pnggramps-bookmark.pnggramps-citation.pnggramps-config.pnggramps-date-edit.pnggramps-date.pnggramps-event.pnggramps-family.pnggramps-fanchart.pnggramps-fanchartdesc.pnggramps-font-bgcolor.pnggramps-font-color.pnggramps-font.pnggramps-geo.pnggramps-gramplet.pnggramps-lock.pnggramps-media.pnggramps-merge.pnggramps-notes.pnggramps-parents-add.pnggramps-parents-open.pnggramps-parents.pnggramps-pedigree.pnggramps-person.pnggramps-place.pnggramps-relation.pnggramps-reports.pnggramps-repository.pnggramps-source.pnggramps-spouse.pnggramps-tag-new.pnggramps-tag.pnggramps-tools.pnggramps-tree-group.pnggramps-tree-list.pnggramps-tree-select.pnggramps-unlock.pnggramps-view.pnggramps-viewmedia.pnggramps-zoom-best-fit.pnggramps-zoom-fit-width.pnggramps-zoom-in.pnggramps-zoom-out.pnggramps.png
source
22x22
geo-fixed-zoom.pnggeo-free-zoom.pnggeo-place-add.pnggeo-place-link.pnggeo-show-event.pnggeo-show-family.pnggeo-show-person.pnggeo-show-place.pnggramps-address.pnggramps-attribute.pnggramps-bookmark-delete.pnggramps-bookmark-edit.pnggramps-bookmark-new.pnggramps-bookmark.pnggramps-citation.pnggramps-config.pnggramps-date-edit.pnggramps-date.pnggramps-event.pnggramps-family.pnggramps-fanchart.pnggramps-fanchartdesc.pnggramps-font-bgcolor.pnggramps-font-color.pnggramps-font.pnggramps-geo-altmap.pnggramps-geo-birth.pnggramps-geo-death.pnggramps-geo-mainmap.pnggramps-geo-marriage.pnggramps-geo.pnggramps-gramplet.pnggramps-lock.pnggramps-media.pnggramps-merge.pnggramps-notes.pnggramps-parents-add.pnggramps-parents-open.pnggramps-parents.pnggramps-pedigree.pnggramps-person.pnggramps-place.pnggramps-relation.pnggramps-reports.pnggramps-repository.pnggramps-source.pnggramps-spouse.pnggramps-tag-new.pnggramps-tag.pnggramps-tools.pnggramps-tree-group.pnggramps-tree-list.pnggramps-tree-select.pnggramps-unlock.pnggramps-view.pnggramps-viewmedia.pnggramps-zoom-best-fit.pnggramps-zoom-fit-width.pnggramps-zoom-in.pnggramps-zoom-out.pnggramps.png
48x48
geo-fixed-zoom.pnggeo-free-zoom.pnggeo-place-add.pnggeo-place-link.pnggeo-show-event.pnggeo-show-family.pnggeo-show-person.pnggeo-show-place.pnggramps-address.pnggramps-attribute.pnggramps-bookmark-delete.pnggramps-bookmark-edit.pnggramps-bookmark-new.pnggramps-bookmark.pnggramps-citation.pnggramps-config.pnggramps-date-edit.pnggramps-date.pnggramps-event.pnggramps-family.pnggramps-fanchart.pnggramps-fanchartdesc.pnggramps-font-bgcolor.pnggramps-font-color.pnggramps-font.pnggramps-geo-altmap.pnggramps-geo-birth.pnggramps-geo-death.pnggramps-geo-mainmap.pnggramps-geo-marriage.pnggramps-geo.pnggramps-gramplet.pnggramps-lock.pnggramps-media.pnggramps-merge.pnggramps-notes.pnggramps-parents-add.pnggramps-parents-open.pnggramps-parents.pnggramps-pedigree.pnggramps-person.pnggramps-place.pnggramps-relation.pnggramps-reports.pnggramps-repository.pnggramps-source.pnggramps-spouse.pnggramps-tag-new.pnggramps-tag.pnggramps-tools.pnggramps-tree-group.pnggramps-tree-list.pnggramps-tree-select.pnggramps-unlock.pnggramps-view.pnggramps-viewmedia.pnggramps-zoom-best-fit.pnggramps-zoom-fit-width.pnggramps-zoom-in.pnggramps-zoom-out.pnggramps.png
add.pngbad.pngcaution.pngdocument.pngdown.pnggood.pnggramps-export.pnggramps-import.pnggramps-undo-history.pnggramps-url.pnggramps.pnggramps.svggtk-remove.pngimage-missing.pnglogo.pngnext.pngped24.icoprevious.pngscalable
add-parent-existing-family.svggeo-fixed-zoom.svggeo-free-zoom.svggeo-place-add.svggeo-place-link.svggeo-show-event.svggeo-show-family.svggeo-show-person.svggeo-show-place.svggramps-address.svggramps-attribute.svggramps-bookmark-delete.svggramps-bookmark-edit.svggramps-bookmark-new.svggramps-bookmark.svggramps-citation.svggramps-config.svggramps-date-edit.svggramps-date.svggramps-event.svggramps-family.svggramps-fanchart.svggramps-fanchartdesc.svggramps-font-bgcolor.svggramps-font-color.svggramps-font.svggramps-geo-altmap.svggramps-geo-birth.svggramps-geo-death.svggramps-geo-mainmap.svggramps-geo-marriage.svggramps-geo.svggramps-gramplet.svggramps-lock.svggramps-media.svggramps-merge.svggramps-notes.svggramps-parents-add.svggramps-parents-open.svggramps-parents.svggramps-pedigree.svggramps-person.svggramps-place.svggramps-relation.svggramps-reports.svggramps-repository.svggramps-source.svggramps-spouse.svggramps-tag-new.svggramps-tag.svggramps-tools.svggramps-tree-group.svggramps-tree-list.svggramps-tree-select.svggramps-unlock.svggramps-view.svggramps-viewmedia.svggramps-zoom-best-fit.svggramps-zoom-fit-width.svggramps-zoom-in.svggramps-zoom-out.svggramps.svg
splash.jpgstock_index_24.pngstock_link.pngstock_new-html.pngstock_notes.pngtext-editor.pngup.pngmac
po
POTFILES.inPOTFILES.skipar.pobg.pobr.poca.pocheck_pocs.poda.pode.poel.poen_GB.poeo.poes.pofi.pofr.poga.pogenpot.shgramps.pothe.pohr.pohu.poit.poja.polt.pomk.ponb.ponl.ponn.popl.popt_BR.popt_PT.poro.poru.posk.posl.posq.posr.posv.potr.pouk.poupdate_po.pyvi.pozh_CN.po
scripts
setup.py
6
.gitignore
vendored
6
.gitignore
vendored
@@ -2,11 +2,11 @@
|
||||
*.py[cod]
|
||||
|
||||
# Distutils
|
||||
MANIFEST
|
||||
build/
|
||||
sdist/
|
||||
dist/
|
||||
|
||||
# Gramps
|
||||
gramps/data/tips.xml
|
||||
gramps/gen/const.py
|
||||
data/tips.xml
|
||||
gramps/plugins/lib/holidays.xml
|
||||
po/.intltool-merge-cache
|
||||
|
@@ -26,5 +26,7 @@ able to run gramps from the source directory without setting PYTHONPATH
|
||||
|
||||
From this position, import gramps works great
|
||||
"""
|
||||
import os
|
||||
os.environ['GRAMPS_RESOURCES'] = os.path.dirname(os.path.abspath(__file__))
|
||||
import gramps.grampsapp as app
|
||||
app.main()
|
||||
|
9
INSTALL
9
INSTALL
@@ -15,11 +15,12 @@ version by deleting the installed directories (for example,
|
||||
/usr/lib/pythonx.x/site-packages/gramps
|
||||
/usr/lib/pythonx.x/dist-packages/gramps
|
||||
where pythonx.x is python2.7 or whatever version you installed gramps with.
|
||||
Also remove the gramps .egg files that are installed along the gramps directory.
|
||||
Also remove the gramps .egg files that are installed along with the gramps
|
||||
directory.
|
||||
|
||||
If you don't know the list of all files that Gramps installed, you can reinstall
|
||||
it with the --record option, and take a look at the list this produces (so
|
||||
python setup.py install --record grampsfiles.txt
|
||||
If you don't know the list of all files that Gramps installed, you can
|
||||
reinstall it with the --record option, and take a look at the list this
|
||||
produces (so python setup.py install --record grampsfiles.txt
|
||||
|
||||
GRAMPS is a python application, so loading happens on reading the
|
||||
files, meaning that files of a previous version that are no longer
|
||||
|
24
MANIFEST.in
24
MANIFEST.in
@@ -11,34 +11,22 @@ include TestPlan.txt
|
||||
recursive-include data *
|
||||
recursive-include debian *
|
||||
recursive-include docs *
|
||||
recursive-include gramps *
|
||||
recursive-include help *
|
||||
recursive-include images *
|
||||
recursive-include mac *
|
||||
recursive-include po *
|
||||
recursive-include gramps *
|
||||
recursive-include test *
|
||||
recursive-include windows *
|
||||
|
||||
# Remove files created in the build
|
||||
exclude data/gramps.desktop
|
||||
exclude data/gramps.keys
|
||||
exclude data/gramps.xml
|
||||
recursive-exclude data/man *.1
|
||||
recursive-exclude data/man *.1.gz
|
||||
exclude gramps/const.py
|
||||
exclude gramps/data/tips.xml
|
||||
exclude data/tips.xml
|
||||
#exclude gramps/gen/const.py
|
||||
exclude gramps/plugins/lib/holidays.xml
|
||||
exclude po/*.gmo
|
||||
exclude po/.intltool-merge-cache
|
||||
exclude po/stamp-it
|
||||
exclude po/POTFILES
|
||||
global-exclude *.pyc
|
||||
global-exclude *.py~
|
||||
global-exclude *.pyo
|
||||
global-exclude *.bak
|
||||
|
||||
# Remove directories which should not be included in the distribution
|
||||
prune src/guiQML
|
||||
prune src/webapp
|
||||
|
||||
# Remove Makefiles used by autotools
|
||||
global-exclude Makefile*
|
||||
prune gramps/guiQML
|
||||
#prune gramps/webapp
|
||||
|
100
NEWS
100
NEWS
@@ -1,3 +1,103 @@
|
||||
2013-05-21
|
||||
Version 4.0.0, the "The Miracle of Birth", new major release.
|
||||
* GEP 8: code reorganization
|
||||
* GEP 26: Replace make
|
||||
* GEP 29: Gtk 3 support
|
||||
* GEP 31: Python 3 support
|
||||
* Completely reworked localization handling
|
||||
* The Gramplet view has been renamed Dashboard. This to avoid an overload of the word Gramplet, and to make it more clear to new users what can be expected in this view
|
||||
* GTK 3 uses new themes, so users not on Gnome must set a nice GTK 3 theme to fully appreciate Gramps 4.0. Install a GTK 3 theme and set it. If Gramps looks ugly, you made an error in this step.
|
||||
* Different sidebar navigators can be installed
|
||||
* New Ancestor Fan Chart View and Descendant Fan Chart View, which offer a lot of insight in your family tree on a small space. Direct printing is available from these views.
|
||||
* All wizards are reworked, so the exporter dialog, help and bug report dialog are different from version 3.4, but offer the same functions
|
||||
* New To Do Gramplets listing all To Do Notes
|
||||
* More reports support output in a different language than the interface language
|
||||
* Narrative Web has been reworked to make it more stable.
|
||||
|
||||
2013-05-15
|
||||
Version 3.4.4 of Gramps! "The Ministry of Silly Names", a maintenance release.
|
||||
* infinite recursion bug in narrative web generation
|
||||
* protection on family trees when using version 3.4 and 4.0 on the same PC (road to 4.0)
|
||||
* merging notes of media with citations now works
|
||||
* crash during Calculate Preview of a filtered XML export
|
||||
* fix annoying errors on navigation related to citations gramplet and tag object.
|
||||
* listing the Family Trees can corrupt them.
|
||||
* various fix around handling Gedcom file format
|
||||
* fix citations and sources import on ProGen format
|
||||
* better date handling and better alternate translation support on some textual reports according to locale under windows
|
||||
* avoid Errors when setting wrong value as markup for invalid dates (Preferences)
|
||||
* fix paragraph layout on PDF format or print output
|
||||
* New: New-Zealand holidays
|
||||
* Polish and backport code on XML import (road to 4.0)
|
||||
* Regular expression rules now use search rather than match, fix design issues on regex filter rules
|
||||
* Disable/Enable indent spouse on descendants tree
|
||||
* fix regular expressions on Place filter rule
|
||||
* consistency on cli arguments (road to 4.0)
|
||||
* fix call of non-existant process on references proxy, enhanced tests on proxy filter
|
||||
* fix NarWeb creation via cli for some non-english locales
|
||||
* Various updated translations: ca, de, fr, it, nl, pt_BR, ru, sv, uk
|
||||
|
||||
2013-03-19
|
||||
Version 3.4.3 of Gramps! "'Whenever life gets you down, Mrs. Brown'", a maintenance release.
|
||||
* Sorting (both in the main display window, and particularly in Narrative Web output) now uses PyICU (if that module is available). Inclusion of PyICU is 'strongly recommended'. This resolves a number of bugs particularly related to sorting of non-Latin characters, and sorting on MS Windows and Mac OS X. Some changes have been made in Narrative Web to support contractions for alphabetic indices.
|
||||
* The automatic Addon checking and download now works once again (the location used in Gramps 3.4.2 and before had been changed, so the the automatic process was no longer working).
|
||||
* Import from Pro-Gen has been updated (at last) to take account of the change to Citations (in 3.4.0)
|
||||
* Import and Export of address fields in GEDCOM has been improved so that the round-trip works properly.
|
||||
* GEDCOM Repositories not imported correctly from FTM for Windows and Heredis.
|
||||
* Fixes to a number of errors in filtering notes.
|
||||
* Fix some errors in determining whether someone is alive (e.g. for filtering out alive people).
|
||||
* Make availability of GraphViz settings depend on output format
|
||||
* Improve the descriptions and tooltip for GraphViz aspect ratio option
|
||||
* Fixed update problems with citation bottombar gramplet (bug #6336)
|
||||
* Fixed Open Document Text output in Book report (bug #6457)
|
||||
* A number of changes to Narrative Web:
|
||||
** Media objects attached to Marriage events and Sources are not included in Narrative Web Site
|
||||
** restructure the families index so families are indexed under both spouses, and the family name is normalised
|
||||
** separate out Families section in individual and families pages so individual page links to the family page and family page links to both people
|
||||
** normalise links to families so the link is only displayed if the family page is present, and the gid is included when appropriate
|
||||
** remove highlighting of media subregions except in the media pages (it was confusing and not very well implemented)
|
||||
** include people whose surname is absent in the individual, surname and families indexes
|
||||
** html_escape names and surnames
|
||||
** always display media thumbnails for first image in Gallery list (in some cases they were suppressed if they had been displayed at the top of the page)
|
||||
** change partner and parent columns in families index to improve the layout of the HTML and put the comma between multiple partners in the right place
|
||||
** use event description (where present) instead of just event type in back references
|
||||
** fix bug in the way obj_dict and bkref_dict were initialised
|
||||
** fix missing document.png for missing media
|
||||
** fixed problems that bibliography ignores media attached to citations, so if that is the only 'interesting' thing about the citation, the citation media is not output
|
||||
** Replaced person link routine with one that takes into account whether there is a page for the person.
|
||||
** Included repository reference media type and call number in the 'Repositories' section of the relevant source instead of the Repository page.
|
||||
** Implemented a generalised back reference function to display the 'References' section of all pages. This recursively displays references till one is found for which a page exists.
|
||||
** Removed list of people and families from heading of the event pages as these are now in the 'References' section.
|
||||
** Fixed bug "0005968: Narrated Web Site not copying Source Citations files such as jpg or pdf docs to web site
|
||||
** Fixed bug "0005946 GRAMPS failed to insert jpeg image into proper place for an event" by displaying a thumbnail for citation media in the 'Source References' section (with a link to the media page)
|
||||
** Tidy up media pages - remove unused parameters, use list of media items generated in first pass. Should fix bugs 2365, 5905 and 6009.
|
||||
** Tidy up sources pages - fix numbering of repositories, remove unused parameters, fix title of individual source pages
|
||||
** Bug: reset NarrWeb navigation menu layout when style sheet doesn't support it
|
||||
** Change Source Pages to use the list of sources generated by the first pass that finds objects to be output, and simplify references section on the Source page to use the references passed to it.
|
||||
** Fix option to suppress Gramps ID (bug #6237)
|
||||
* a number of technical changes to Narrative Web
|
||||
** Removed a lot of redundant code and parameters (mainly connected with the old way of determining the objects to be included in the report).
|
||||
** Movement of some large chunks of code within the source file and some initial work towards GEPS 022: Narrative Website Refactor. Functionality should be unchanged.
|
||||
** Moved routines for calculating objects to be output so they can be part of default list building classes.
|
||||
* Various updated translations: da, de, es, fr, it, nb, nl, pt_BR, pt_PT, sv, uk
|
||||
|
||||
2012-10-28
|
||||
Version 3.4.2 -- the "We're all individuals!" bug fix release.
|
||||
* Some fixes on NarrativeWeb report
|
||||
* Some fixes on book report
|
||||
* Improvement on database path interface and user's preferences
|
||||
* Consistency on Name display and regex support
|
||||
* Some platform-specific fixes for Windows system environment
|
||||
* Better support for media links on Gedcom file format
|
||||
* Fix possible incorrect family relations on Gedcom file format
|
||||
* Various fixes on citation records
|
||||
* Fix and improve places handling on Geography views
|
||||
* Fix on command line arguments
|
||||
* Consistency on PDF file format
|
||||
* New language: Greek
|
||||
* Various updated translations
|
||||
* Changelog: http://www.gramps-project.org/bugs/changelog_page.php?version_id=32
|
||||
|
||||
2012-08-23
|
||||
Version 3.4.1 -- The "A tiger? In Africa?!" bug fix release.
|
||||
Mention in the release that upgrading is advised for two critical issues:
|
||||
|
73
README
73
README
@@ -1,49 +1,87 @@
|
||||
$Id$
|
||||
|
||||
Please read the COPYING file first.
|
||||
|
||||
If building from source, also read the INSTALL file (at least through the
|
||||
"SUPER-SHORT VERSION") before going further.
|
||||
|
||||
Requirements
|
||||
--------------------------------
|
||||
The following packages *MUST* be installed in order for Gramps to work:
|
||||
Python 2.7 or greater, Python 3.2 or greater (python version cannot be mixed)
|
||||
Python 2.7 or greater, Python 3.2 or greater (or both python versions)
|
||||
GTK 3.0 or greater
|
||||
pygobject 3.3.2 or greater
|
||||
cairo, pango, pangocairo with introspection bindings (the gi packages)
|
||||
librsvg2 (svg icon view)
|
||||
xdg-utils
|
||||
bsddb3 is required for Python 3.2 (not python 2.7)
|
||||
|
||||
The following package is needed for full translation of the interface
|
||||
to your language:
|
||||
language-pack-gnome-xx
|
||||
Translation of GTK elements to your language, with
|
||||
xx your language code eg for Dutch you need
|
||||
Translation of GTK elements to your language, with
|
||||
xx your language code; e.g. for Dutch you need
|
||||
language-pack-gnome-nl. The translation of the
|
||||
Gramps strings is included with the source code.
|
||||
Gramps strings is included with the gramps source.
|
||||
|
||||
|
||||
The following packages are *STRONGLY RECOMMENDED* to be installed:
|
||||
|
||||
osmgpsmap Used to show maps in the geography view.
|
||||
It may be osmgpsmap, osm-gps-map, or python-osmgpsmap,
|
||||
but the Python bindings for this must also be present.
|
||||
Without this the GeoView will not be active, see
|
||||
http://gramps-project.org/wiki/index.php?title=Gramps_3.3_Wiki_Manual_-_Main_Window#Geography_Category
|
||||
The package is named osmgpsmap, osm-gps-map
|
||||
or python-osmgpsmap. Or obtain it from: http://nzjrs.github.com/osm-gps-map/
|
||||
http://gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_Main_Window#Geography_Category
|
||||
!! PACKAGERS: unfortunately, at the moment (March 2013),
|
||||
the patches which gramps 4.0 needs osm-gps-map to have
|
||||
are not yet released (as a new osm-gps-map version). The
|
||||
osm-gps-map sources must be dated 6 February 2013 (or
|
||||
later) to have the necessary patches. You may obtain
|
||||
it from: http://nzjrs.github.com/osm-gps-map/ or else
|
||||
http://sourceforge.net/projects/gramps/files/Dependencies
|
||||
(The necessary version seems to be 0.8 -- or later.)
|
||||
|
||||
GraphViz Enable creation of graphs using GraphViz engine.
|
||||
Without this no beautiful graphs can be created.
|
||||
Without this, three reports cannot be run.
|
||||
Obtain it from: http://www.graphviz.org
|
||||
pyexiv2 Enables Gramps to manage Exif metadata embedded in your
|
||||
media. Gramps needs version 0.1.3 or greater.
|
||||
Obtain it from: http://tilloy.net/dev/pyexiv2/download.html
|
||||
|
||||
PyICU Improves localised sorting in Gramps. In particular, this
|
||||
applies to sorting in the various views and in the
|
||||
Narrative Web output. It is particularly helpful for
|
||||
non-Latin characters, for non-English locales and on MS
|
||||
Windows and Mac OS X platforms. If it is not available,
|
||||
sorting is done through built-in libraries. PyICU is
|
||||
fairly widely available through the package managers of
|
||||
distributions. See http://pyicu.osafoundation.org/
|
||||
(These are Python bindings for the ICU package.)
|
||||
|
||||
The following packages are optional
|
||||
|
||||
gtkspell Enable spell checking in the notes. Gtkspell depends on
|
||||
enchant. A version of gtkspell with gobject introspection
|
||||
is needed, so minimally version 3.0.0
|
||||
|
||||
rcs The GNU Revision Control System (RCS) can be used to manage
|
||||
multiple revisions of your family trees. See info at
|
||||
http://www.gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_Manage_Family_Trees#Archiving_a_Family_Tree
|
||||
Only rcs is needed, NO python bindings are required
|
||||
|
||||
PIL Python Image Library is needed to crop
|
||||
images and also to convert non-JPG images to
|
||||
JPG so as to include them in LaTeX output.
|
||||
(For Python3 a different source may be needed.)
|
||||
|
||||
GExiv2 Enables Gramps to manage Exif metadata embedded in your
|
||||
media. Gramps needs version 0.5 or greater.
|
||||
See http://www.gramps-project.org/wiki/index.php?title=GEPS_029:_GTK3-GObject_introspection_Conversion#GExiv2_for_Image_metadata
|
||||
|
||||
ttf-freefont More font support in the reports
|
||||
|
||||
gir-webkit GObject introspection data of WebKit is required for the
|
||||
hidden view 'Htmlview', which allows websites to be opened in
|
||||
Gramps. Users can unhide the view in the plugin manager.
|
||||
A html renderer must be installed to use the view.
|
||||
hidden view 'Htmlview', which allows websites to be
|
||||
opened in Gramps. Users can unhide the view in the
|
||||
plugin manager. A html renderer must be installed to
|
||||
use the view.
|
||||
!! PACKAGERS, Test if on your distribution
|
||||
webkit and Gramps is stable. If you obtain crashes, patch
|
||||
src/plugins/view/htmlrenderer.py and
|
||||
@@ -51,10 +89,10 @@ The following packages are optional
|
||||
from gi.repository import WebKit as webkit
|
||||
|
||||
goocanvas2:
|
||||
Required for the Graphview plugin
|
||||
Required for the (user-downloadable) Graphview plugin
|
||||
|
||||
No longer needed in 4.0:
|
||||
pygoocanvas, pygtk
|
||||
pygoocanvas, pygtk, pyexiv2
|
||||
No longer needed in 3.3:
|
||||
python-enchant Enchant
|
||||
No longer needed in 3.2:
|
||||
@@ -62,9 +100,6 @@ No longer needed in 3.2:
|
||||
No longer needed in 3.1:
|
||||
yelp Gnome help browser. At the moment no help is shipped
|
||||
|
||||
Remark: There is a conflict when using python-gnome2 in Ubuntu. This is evident
|
||||
with the error: TypeError: Error when calling the metaclass bases
|
||||
metaclass conflict
|
||||
|
||||
Documentation
|
||||
---------------------------------
|
||||
|
@@ -1,24 +1,69 @@
|
||||
Gramps 3.2 Release Notes
|
||||
$Id$
|
||||
|
||||
General Improvements
|
||||
Gramps 4.0.0, the "The Miracle of Birth", release.
|
||||
|
||||
* New Plugin System
|
||||
In the Help Menu -> Menu Status, all available plugins are visible. All plugins can be hidden, saving resources and hiding options you do not need. Eg: You don't use the Pedigree View? Hide it in the Plugin Status, and it will not be present anymore. You don't use vcard export? Hide it in the Plugin Status, and it will not be offered anymore.
|
||||
This is a major release, don't upgrade before verifying your system can run it.
|
||||
As one of the very first big ($5.4 million), multi-platform (Linux,
|
||||
Windows, Mac OS X, ...), non-Gnome GTK applications, Gramps makes the
|
||||
jump to GTK 3. At the same time python 2.7 and python 3 are supported,
|
||||
though the last must still be considered experimental. Gramps 4.0
|
||||
further uses distutils for distribution, so the install sequence is changed.
|
||||
The Gramps developers have tried to make Gramps 4.0 as identical as
|
||||
possible to 3.4, so no data changes are done, nor are there big interface
|
||||
changes. In other words, a .gramps backup file of version 4.0 will open
|
||||
without problems in Gramps 3.4, giving users the possibility to fully try Gramps 4.0.
|
||||
Don't be mistaken though, a huge amount of code is new and changed!
|
||||
In order to bring this release we thank the many developers who helped
|
||||
the GTK support on Mac, Windows and Linux forward. Note however,
|
||||
Gramps 4.0 will only work on a top of a very recent sortware stack.
|
||||
A Windows installer will probably not be available soon. In Linux current
|
||||
distro's don't contain the optional packages in the form Gramps 4.0 needs.
|
||||
All this should make clear you can safely keep using version 3.4 and wait
|
||||
for packagers to catch up. People who cannot upgrade the required components
|
||||
but want to use Gramps 4.0 should use it in Virtualbox.
|
||||
|
||||
* Faster
|
||||
Many under the hood improvements have occurred that should improve perfamance enormously. Yes, new features are present to use all your processing power, but they are all implemented as plugins that can be hidden. Eg: Insert of a person in a 30000 people family tree took 4sec on 1.4Ghz PC in 3.1, Now it is done in milliseconds.
|
||||
Major enhancements in Gramps 4.0.0:
|
||||
|
||||
*New Views
|
||||
There are new views, and some views have been greatly improved
|
||||
- People view can now be sorted on the columns
|
||||
- A Place treeview is present, nicely grouping your places under country groups
|
||||
- GeoView has left it's beta status behind and shows your data on an
|
||||
online map (Openstreetmap or google maps, fast internet connection required)
|
||||
- Help Menu -> Extra Reports/Tools open a webpage with downloadable extra views
|
||||
* GEP 8: code reorganization:
|
||||
http://www.gramps-project.org/wiki/index.php?title=GEPS_008:_File_Organization
|
||||
|
||||
* GEP 26: Replace make:
|
||||
http://www.gramps-project.org/wiki/index.php?title=GEPS_026:_Replace_%27make%27_for_Gramps_build
|
||||
|
||||
Other Improvements
|
||||
* GEP 29: Gtk 3:
|
||||
http://www.gramps-project.org/wiki/index.php?title=GEPS_029:_GTK3-GObject_introspection_Conversion
|
||||
|
||||
* Styled Notes now in most output formats that support styles, eg in the web report
|
||||
* New languages
|
||||
* Select language in which report should be created (only present now in some reports)
|
||||
* GEP 31: Python 3 support:
|
||||
http://www.gramps-project.org/wiki/index.php?title=GEPS_031:_Python_3_support
|
||||
|
||||
* Completely reworked localization handling
|
||||
|
||||
Others changes in Gramps 4.0.0:
|
||||
|
||||
* The Gramplet view has been renamed Dashboard. This to avoid an overload
|
||||
of the word Gramplet, and to make it more clear to new users what can
|
||||
be expected in this view
|
||||
|
||||
* GTK 3 uses new themes, so users not on Gnome must set a nice GTK 3
|
||||
theme to fully appreciate Gramps 4.0. Install a GTK 3 theme and set it.
|
||||
If Gramps looks ugly, you made an error in this step.
|
||||
|
||||
* Different sidebar navigators can be installed
|
||||
|
||||
* New Ancestor Fan Chart View and Descendant Fan Chart View, which offer
|
||||
a lot of insight in your family tree on a small space. Direct printing
|
||||
is available from these views.
|
||||
|
||||
* All wizards are reworked, so the exporter dialog, help and bug report
|
||||
dialog are different from version 3.4, but offer the same functions
|
||||
|
||||
* New To Do Gramplets listing all To Do Notes
|
||||
|
||||
* More reports support output in a different language than the interface language
|
||||
|
||||
* Narrative Web has been reworked to make it more stable.
|
||||
|
||||
More info in the manual
|
||||
http://www.gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_What%27s_new%3F
|
||||
|
||||
Everybody is invited to update the manual to make it current!
|
||||
|
@@ -1,14 +0,0 @@
|
||||
# This is the data/man level Makefile for Gramps
|
||||
# $Id$
|
||||
|
||||
SUBDIRS = fr sv nl pl cs pt_BR
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
@@ -50,7 +50,7 @@ copyright = u'2012, Gramps project'
|
||||
# The short X.Y version.
|
||||
version = '4.0'
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '4.0.0'
|
||||
release = '4.0.0-alpha2'
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
@@ -1,14 +0,0 @@
|
||||
# This is the data/man/sv level Makefile for Gramps
|
||||
# $Id: Makefile.am 6189 2006-03-21 19:05:46Z rshura $
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
mandir = @mandir@/cs
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/cs/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
@@ -249,7 +249,9 @@ gramps(1) 3.4.0 gramps(1)
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps*
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
English
|
||||
=======
|
||||
|
||||
gramps(1) 4.0.0 gramps(1)
|
||||
gramps(1) @VERSION@ gramps(1)
|
||||
|
||||
|
||||
|
||||
@@ -262,11 +262,14 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
**KNOWN BUGS AND LIMITATIONS**
|
||||
**FILES**
|
||||
|
||||
**FILES**
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps*
|
||||
|
||||
@@ -293,4 +296,4 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
|
||||
January 2013 4.0.0 gramps(1)
|
||||
gramps(1) @VERSION@ gramps(1)
|
||||
|
@@ -1,14 +0,0 @@
|
||||
# This is the data/man/fr level Makefile for Gramps
|
||||
# $Id$
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
mandir = @mandir@/fr
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/fr/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
@@ -50,7 +50,7 @@ copyright = u'2012, Gramps project'
|
||||
# The short X.Y version.
|
||||
version = '4.0'
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '4.0.0'
|
||||
release = '4.0.0-alpha2'
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
@@ -1,9 +1,7 @@
|
||||
French
|
||||
=======
|
||||
|
||||
|
||||
gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
gramps(1) @VERSION@ gramps(1)
|
||||
|
||||
|
||||
**NOM**
|
||||
@@ -34,33 +32,33 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
**OPTIONS**
|
||||
**gramps** *FICHIER*
|
||||
Si *FICHIER* est désigné (sans autres commandes) comme arbre
|
||||
familial ou comme répertoire d'arbre familial, alors une session
|
||||
interactive est ouverte. Si *FICHIER* est un format de fichier
|
||||
supporté par Gramps, une base vide est créée dont le nom est
|
||||
celui du *FICHIER* et les données y seront importées. Les autres
|
||||
options sont ignorées. Ce type de lancement permet d'utiliser
|
||||
gramps pour manipuler des données comme dans un navigateur web.
|
||||
Les formats natifs de gramps sont acceptés, voir ci-dessous.
|
||||
Si *FICHIER* est désigné (sans autres commandes) comme arbre
|
||||
familial ou comme répertoire d'arbre familial, alors une session
|
||||
interactive est ouverte. Si *FICHIER* est un format de fichier
|
||||
supporté par Gramps, une base vide est créée dont le nom est
|
||||
celui du *FICHIER* et les données y seront importées. Les autres
|
||||
options sont ignorées. Ce type de lancement permet d'utiliser
|
||||
gramps pour manipuler des données comme dans un navigateur web.
|
||||
Les formats natifs de gramps sont acceptés, voir ci-dessous.
|
||||
|
||||
|
||||
**-f** , **--format=** *FORMAT*
|
||||
Le format spécifique du *FICHIER* est précédé par les arguments
|
||||
**-i** , ou **-e** . Si l'option **-f** n'est pas donnée pour le *FICHIER* ,
|
||||
alors le format sera celui de l'extension ou du type-MIME.
|
||||
Le format spécifique du *FICHIER* est précédé par les arguments
|
||||
**-i** , ou **-e** . Si l'option **-f** n'est pas donnée pour le *FICHIER* ,
|
||||
alors le format sera celui de l'extension ou du type-MIME.
|
||||
|
||||
Les formats de sortie disponibles sont **gramps-xml** (deviné si
|
||||
*FICHIER* se termine par **.gramps** ), et **gedcom** (deviné si *FICHIER* se
|
||||
termine par **.ged** ), ou tout autre fichier d'exportation
|
||||
disponible dans le système de plugin Gramps.
|
||||
Les formats de sortie disponibles sont **gramps-xml** (deviné si
|
||||
*FICHIER* se termine par **.gramps** ), et **gedcom** (deviné si *FICHIER* se
|
||||
termine par **.ged** ), ou tout autre fichier d'exportation
|
||||
disponible dans le système de plugin Gramps.
|
||||
|
||||
Les formats disponibles pour l'importation sont **grdb** ,
|
||||
**gramps-xml** , **gedcom** , **gramps-pkg** (deviné si *FICHIER* se termine par
|
||||
**.gpkg** ), et **geneweb** (deviné si *FICHIER* se termine par **.gw** ).
|
||||
Les formats disponibles pour l'importation sont **grdb** ,
|
||||
**gramps-xml** , **gedcom** , **gramps-pkg** (deviné si *FICHIER* se termine par
|
||||
**.gpkg** ), et **geneweb** (deviné si *FICHIER* se termine par **.gw** ).
|
||||
|
||||
Les formats disponibles pour l'exportation sont **gramps-xml** , **ged‐
|
||||
com** , **gramps-pkg** , **wft** (deviné si *FICHIER* se termine par **.wft** ),
|
||||
**geneweb** .
|
||||
Les formats disponibles pour l'exportation sont **gramps-xml** , **ged‐
|
||||
com** , **gramps-pkg** , **wft** (deviné si *FICHIER* se termine par **.wft** ),
|
||||
**geneweb** .
|
||||
|
||||
|
||||
**-l**
|
||||
@@ -68,29 +66,29 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
**-u** , **--force-unlock**
|
||||
Débloquer une base de données verrouillée.
|
||||
Débloquer une base de données verrouillée.
|
||||
|
||||
|
||||
**-O** , **--open=** *BASE_DE_DONNEES*
|
||||
Ouvrir une *BASE_DE_DONNEES* qui doit être une base présente dans
|
||||
le répertoire des bases ou le nom d'un arbre familial existant.
|
||||
Si aucune action n'est définie, les options d'import ou d'export
|
||||
sont données par la ligne de commande puis une session interac‐
|
||||
tive est ouverte, utilisant cette base de données.
|
||||
Ouvrir une *BASE_DE_DONNEES* qui doit être une base présente dans
|
||||
le répertoire des bases ou le nom d'un arbre familial existant.
|
||||
Si aucune action n'est définie, les options d'import ou d'export
|
||||
sont données par la ligne de commande puis une session interactive
|
||||
est ouverte, utilisant cette base de données.
|
||||
|
||||
Seulement une base peut être ouverte. Si vous utilisez plusieurs
|
||||
sources, vous devez utiliser l'option d'import.
|
||||
Seulement une base peut être ouverte. Si vous utilisez plusieurs
|
||||
sources, vous devez utiliser l'option d'import.
|
||||
|
||||
|
||||
**-i** , **--import=** *FICHIER*
|
||||
Importer des données depuis un *FICHIER* . Si vous n'avez pas
|
||||
spécifié de base de données alors une base de données temporaire
|
||||
est utilisée; elle sera effacée quand vous quitterez gramps.
|
||||
Importer des données depuis un *FICHIER* . Si vous n'avez pas
|
||||
spécifié de base de données alors une base de données temporaire
|
||||
est utilisée; elle sera effacée quand vous quitterez gramps.
|
||||
|
||||
Quand plus d'un fichier doit être importé, chacun doit être
|
||||
précédé par la commande **-i** . Ces fichiers sont importés dans le
|
||||
même ordre, i.e. **-i** *FICHIER1* **-i** *FICHIER2* et **-i** *FICHIER2* **-i**
|
||||
*FICHIER1* vont tous les deux produire différents IDs gramps.
|
||||
Quand plus d'un fichier doit être importé, chacun doit être
|
||||
précédé par la commande **-i** . Ces fichiers sont importés dans le
|
||||
même ordre, **-i** *FICHIER1* **-i** *FICHIER2* et **-i** *FICHIER2* **-i**
|
||||
*FICHIER1* vont tous les deux produire différents IDs gramps.
|
||||
|
||||
|
||||
**-e** , **--export=** *FICHIER*
|
||||
@@ -104,38 +102,38 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
**-a** , **--action=** *ACTION*
|
||||
Accomplir une *ACTION* sur les données importées. C'est effectué à
|
||||
la fin de l'importation. Les actions possibles sont **summary**
|
||||
(comme le rapport -> Afficher -> Statistiques sur la base),
|
||||
**check** (comme l'outil -> Réparation de la base -> Vérifier et
|
||||
réparer), **report** (produit un rapport) et **tool** (utilise un
|
||||
outil), ces derniers ont besoin de *OPTION* précédé par la commande -p.
|
||||
Accomplir une *ACTION* sur les données importées. C'est effectué à
|
||||
la fin de l'importation. Les actions possibles sont **summary**
|
||||
(comme le rapport -> Afficher -> Statistiques sur la base),
|
||||
**check** (comme l'outil -> Réparation de la base -> Vérifier et
|
||||
réparer), **report** (produit un rapport) et **tool** (utilise un
|
||||
outil), ces derniers ont besoin de *OPTION* précédé par la commande -p.
|
||||
|
||||
L' *OPTION* doit satisfaire ces conditions:
|
||||
Il ne doit pas y avoir d'espace. Si certains arguments doivent
|
||||
utiliser des espaces, la chaîne doit être encadrée par des
|
||||
guillemets. Les options vont par paire nom et valeur. Une
|
||||
paire est séparée par un signe égal. Différentes paires sont
|
||||
séparées par une virgule.
|
||||
L' *OPTION* doit satisfaire ces conditions:
|
||||
Il ne doit pas y avoir d'espace. Si certains arguments doivent
|
||||
utiliser des espaces, la chaîne doit être encadrée par des
|
||||
guillemets. Les options vont par paire nom et valeur. Une
|
||||
paire est séparée par un signe égal. Différentes paires sont
|
||||
séparées par une virgule.
|
||||
|
||||
La plupart des options sont spécifiques à chaque rapport. Même
|
||||
s'il existe des options communes.
|
||||
La plupart des options sont spécifiques à chaque rapport. Même
|
||||
s'il existe des options communes.
|
||||
|
||||
**name=name**
|
||||
Cette option est obligatoire, elle détermine quel rapport ou
|
||||
outil sera utilisé. Si le name saisi ne correspond à aucun
|
||||
module disponible, un message d'erreur sera ajouté.
|
||||
**name=name**
|
||||
Cette option est obligatoire, elle détermine quel rapport ou
|
||||
outil sera utilisé. Si le name saisi ne correspond à aucun
|
||||
module disponible, un message d'erreur sera ajouté.
|
||||
|
||||
**show=all**
|
||||
Cette option produit une liste avec les noms des options
|
||||
disponibles pour un rapport donné.
|
||||
**show=all**
|
||||
Cette option produit une liste avec les noms des options
|
||||
disponibles pour un rapport donné.
|
||||
|
||||
**show=optionname**
|
||||
Cette option affiche une description de toutes les fonctionnalités
|
||||
proposées par optionname, aussi bien les types que les valeurs pour une option.
|
||||
|
||||
Utiliser les options ci-dessus pour trouver tout sur un rapport
|
||||
choisi.
|
||||
choisi.
|
||||
|
||||
|
||||
Quand plus d'une action doit être effectuée, chacune doit être précédée
|
||||
@@ -144,23 +142,23 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
**-d** , **--debug=** *NOM_LOGGER*
|
||||
Permet les logs de debug pour le développement et les tests.
|
||||
Regarder le code source pour les détails.
|
||||
Permet les logs de debug pour le développement et les tests.
|
||||
Regarder le code source pour les détails.
|
||||
|
||||
**--version**
|
||||
Imprime le numéro de version pour gramps puis quitte.
|
||||
Imprime le numéro de version pour gramps puis quitte.
|
||||
|
||||
|
||||
|
||||
|
||||
**Opération**
|
||||
Si le premie argument de la ligne de commande ne commence pas par un
|
||||
tiret (i.e. pas d'instruction), gramps va essayer d'ouvrir la base de
|
||||
données avec le nom donné par le premier argument et démarrer une ses‐
|
||||
Si le premier argument de la ligne de commande ne commence pas par un
|
||||
tiret (i.e. pas d'instruction), gramps va essayer d'ouvrir la base de
|
||||
données avec le nom donné par le premier argument et démarrer une ses‐
|
||||
sion interactive, en ignorant le reste de la ligne de commande.
|
||||
|
||||
|
||||
Si la commande **-O** est notée, alors gramps va essayer le fichier défini
|
||||
Si la commande **-O** est notée, alors gramps va essayer le fichier défini
|
||||
et va travailler avec ses données, comme pour les autres paramètres de
|
||||
la ligne de commande.
|
||||
|
||||
@@ -183,7 +181,7 @@ gramps(1) 4.0.0 gramps(1)
|
||||
Cette base sera **import_db.grdb** dans le répertoire **~/.gramps/import**.
|
||||
|
||||
|
||||
Les erreurs rencontrées lors d'importation, d'exportation, ou d'action, seront
|
||||
Les erreurs rencontrées lors d'importation, d'exportation, ou d'action, seront
|
||||
mémorisées en *stdout* (si elles sont le fait de la manipulation par
|
||||
gramps) ou en *stderr* (si elles ne sont pas le fait d'une manipulation).
|
||||
Utilisez les shell de redirection de *stdout* et *stderr* pour sauver
|
||||
@@ -191,16 +189,16 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
**EXEMPLES**
|
||||
Pour ouvrir un arbre familial et y importer un fichier XML, on peut
|
||||
Pour ouvrir un arbre familial et y importer un fichier XML, on peut
|
||||
saisir:
|
||||
|
||||
**gramps -O** *'Mon Arbre Familial'* **-i** *~/db3.gramps*
|
||||
**gramps -O** *'Mon Arbre Familial'* **-i** *~/db3.gramps*
|
||||
|
||||
Ceci ouvre un arbre familial, pour faire la même chose, mais importer
|
||||
dans un arbre familial temporaire et démarrer une session interactive,
|
||||
on peut saisir:
|
||||
dans un arbre familial temporaire et démarrer une session interactive,
|
||||
on peut saisir :
|
||||
|
||||
**gramps -i** *'Mon Arbre Familial'* **-i** *~/db3.gramps*
|
||||
**gramps -i** *'Mon Arbre Familial'* **-i** *~/db3.gramps*
|
||||
|
||||
Lecture de quatre bases de données dont les formats peuvent être
|
||||
devinés d'après les noms, puis vérification des données:
|
||||
@@ -225,12 +223,12 @@ gramps(1) 4.0.0 gramps(1)
|
||||
Pour lire trois ensembles de données puis lancer une session
|
||||
interactive de gramps sur le tout :
|
||||
|
||||
**gramps -i** *file1.ged* **-i** *file2.tgz* **-i** *~/db3.gramps*
|
||||
**gramps -i** *file1.ged* **-i** *file2.tgz* **-i** *~/db3.gramps*
|
||||
|
||||
Pour lancer l'outil de vérification de la base de données depuis la
|
||||
ligne de commande et obtenir le résultat :
|
||||
|
||||
**gramps -O** *'My Family Tree'* **-a** *tool* **-p name=** *verify*
|
||||
**gramps -O** *'My Family Tree'* **-a** *tool* **-p name=** *verify*
|
||||
|
||||
Enfin, pour lancer une session interactive normale, entrer :
|
||||
|
||||
@@ -253,21 +251,24 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
**CONCEPTS**
|
||||
Gramps est un système basé sur le support de plugin-python, permettant
|
||||
d'importer et d'exporter, la saisie, générer des rapports, des outils,
|
||||
et afficher des filtres pouvant être ajoutés sans modifier le programme.
|
||||
d'importer et d'exporter, la saisie, générer des rapports, des outils,
|
||||
et afficher des filtres pouvant être ajoutés sans modifier le programme.
|
||||
|
||||
Par ailleurs, gramps permet la génération directe : impression, rap‐
|
||||
ports avec sortie vers d'autres formats, comme *LibreOffice.org* ,
|
||||
*HTML* , ou *LaTeX* pour permettre à l'utilisateur de choisir selon ses
|
||||
*HTML* , ou *LaTeX* pour permettre à l'utilisateur de choisir selon ses
|
||||
besoins
|
||||
|
||||
|
||||
**BUGS CONNUS ET LIMITATIONS**
|
||||
|
||||
**FICHIERS**
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps*
|
||||
|
||||
@@ -296,4 +297,4 @@ gramps(1) 4.0.0 gramps(1)
|
||||
|
||||
|
||||
|
||||
Janvier 2013 4.0.0 gramps(1)
|
||||
gramps(1) @VERSION@ gramps(1)
|
||||
|
@@ -1,4 +1,4 @@
|
||||
.TH "GRAMPS" "1" "04 December 2012" "4.0" "Gramps"
|
||||
.TH "GRAMPS" "1" "28 December 2012" "4.0" "Gramps"
|
||||
.SH NAME
|
||||
gramps \- Gramps Documentation
|
||||
.
|
||||
@@ -28,10 +28,10 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
||||
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
||||
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
|
||||
..
|
||||
.\" Man page generated from reStructeredText.
|
||||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.sp
|
||||
gramps(1) 4.0.0 gramps(1)
|
||||
gramps(1) @VERSION@ gramps(1)
|
||||
.INDENT 0.0
|
||||
.TP
|
||||
.B \fBNOM\fP
|
||||
@@ -72,7 +72,7 @@ Les formats natifs de gramps sont acceptés, voir ci\-dessous.
|
||||
.TP
|
||||
.B \fB\-f\fP , \fB\-\-format=\fP \fIFORMAT\fP
|
||||
Le format spécifique du \fIFICHIER\fP est précédé par les arguments
|
||||
\fB\-i\fP , ou \fB\-e\fP . Si l\(aqoption \fB\-f\fP n\(aqest pas donnée pour le \fIFICHIER\fP ,
|
||||
\fB\-i\fP , ou \fB\-e\fP . Si l\(aqoption \fB\-f\fP n\(aqest pas donnée pour le \fIFICHIER\fP ,
|
||||
alors le format sera celui de l\(aqextension ou du type\-MIME.
|
||||
.sp
|
||||
Les formats de sortie disponibles sont \fBgramps\-xml\fP (deviné si
|
||||
@@ -96,10 +96,10 @@ Débloquer une base de données verrouillée.
|
||||
.TP
|
||||
.B \fB\-O\fP , \fB\-\-open=\fP \fIBASE_DE_DONNEES\fP
|
||||
Ouvrir une \fIBASE_DE_DONNEES\fP qui doit être une base présente dans
|
||||
le répertoire des bases ou le nom d\(aqun arbre familial existant.
|
||||
le répertoire des bases ou le nom d\(aqun arbre familial existant.
|
||||
Si aucune action n\(aqest définie, les options d\(aqimport ou d\(aqexport
|
||||
sont données par la ligne de commande puis une session interac‐
|
||||
tive est ouverte, utilisant cette base de données.
|
||||
sont données par la ligne de commande puis une session interactive
|
||||
est ouverte, utilisant cette base de données.
|
||||
.sp
|
||||
Seulement une base peut être ouverte. Si vous utilisez plusieurs
|
||||
sources, vous devez utiliser l\(aqoption d\(aqimport.
|
||||
@@ -109,9 +109,9 @@ Importer des données depuis un \fIFICHIER\fP . Si vous n\(aqavez pas
|
||||
spécifié de base de données alors une base de données temporaire
|
||||
est utilisée; elle sera effacée quand vous quitterez gramps.
|
||||
.sp
|
||||
Quand plus d\(aqun fichier doit être importé, chacun doit être
|
||||
Quand plus d\(aqun fichier doit être importé, chacun doit être
|
||||
précédé par la commande \fB\-i\fP . Ces fichiers sont importés dans le
|
||||
même ordre, i.e. \fB\-i\fP \fIFICHIER1\fP \fB\-i\fP \fIFICHIER2\fP et \fB\-i\fP \fIFICHIER2\fP \fB\-i\fP
|
||||
même ordre, \fB\-i\fP \fIFICHIER1\fP \fB\-i\fP \fIFICHIER2\fP et \fB\-i\fP \fIFICHIER2\fP \fB\-i\fP
|
||||
\fIFICHIER1\fP vont tous les deux produire différents IDs gramps.
|
||||
.TP
|
||||
.B \fB\-e\fP , \fB\-\-export=\fP \fIFICHIER\fP
|
||||
@@ -124,17 +124,15 @@ précédé par la commande \fB\-e\fP . Ces fichiers sont importés dans le
|
||||
même ordre.
|
||||
.TP
|
||||
.B \fB\-a\fP , \fB\-\-action=\fP \fIACTION\fP
|
||||
.INDENT 7.0
|
||||
.INDENT 3.5
|
||||
Accomplir une \fIACTION\fP sur les données importées. C\(aqest effectué à
|
||||
la fin de l\(aqimportation. Les actions possibles sont \fBsummary\fP
|
||||
(comme le rapport \-> Afficher \-> Statistiques sur la base),
|
||||
\fBcheck\fP (comme l\(aqoutil \-> Réparation de la base \-> Vérifier et
|
||||
réparer), \fBreport\fP (produit un rapport) et \fBtool\fP (utilise un
|
||||
la fin de l\(aqimportation. Les actions possibles sont \fBsummary\fP
|
||||
(comme le rapport \-> Afficher \-> Statistiques sur la base),
|
||||
\fBcheck\fP (comme l\(aqoutil \-> Réparation de la base \-> Vérifier et
|
||||
réparer), \fBreport\fP (produit un rapport) et \fBtool\fP (utilise un
|
||||
outil), ces derniers ont besoin de \fIOPTION\fP précédé par la commande \-p.
|
||||
.sp
|
||||
L\(aq \fIOPTION\fP doit satisfaire ces conditions:
|
||||
Il ne doit pas y avoir d\(aqespace. Si certains arguments doivent
|
||||
Il ne doit pas y avoir d\(aqespace. Si certains arguments doivent
|
||||
utiliser des espaces, la chaîne doit être encadrée par des
|
||||
guillemets. Les options vont par paire nom et valeur. Une
|
||||
paire est séparée par un signe égal. Différentes paires sont
|
||||
@@ -144,25 +142,21 @@ La plupart des options sont spécifiques à chaque rapport. Même
|
||||
s\(aqil existe des options communes.
|
||||
.sp
|
||||
\fBname=name\fP
|
||||
Cette option est obligatoire, elle détermine quel rapport ou
|
||||
Cette option est obligatoire, elle détermine quel rapport ou
|
||||
outil sera utilisé. Si le name saisi ne correspond à aucun
|
||||
module disponible, un message d\(aqerreur sera ajouté.
|
||||
.sp
|
||||
\fBshow=all\fP
|
||||
Cette option produit une liste avec les noms des options
|
||||
disponibles pour un rapport donné.
|
||||
.UNINDENT
|
||||
.UNINDENT
|
||||
.sp
|
||||
\fBshow=optionname\fP
|
||||
Cette option affiche une description de toutes les fonctionnalités
|
||||
proposées par optionname, aussi bien les types que les valeurs pour une option.
|
||||
.INDENT 7.0
|
||||
.TP
|
||||
.B Utiliser les options ci\-dessus pour trouver tout sur un rapport
|
||||
.sp
|
||||
Utiliser les options ci\-dessus pour trouver tout sur un rapport
|
||||
choisi.
|
||||
.UNINDENT
|
||||
.UNINDENT
|
||||
.sp
|
||||
Quand plus d\(aqune action doit être effectuée, chacune doit être précédée
|
||||
par la commande \fB\-a\fP . Les actions seront réalisées une à une, dans
|
||||
@@ -178,12 +172,12 @@ Imprime le numéro de version pour gramps puis quitte.
|
||||
.UNINDENT
|
||||
.TP
|
||||
.B \fBOpération\fP
|
||||
Si le premie argument de la ligne de commande ne commence pas par un
|
||||
tiret (i.e. pas d\(aqinstruction), gramps va essayer d\(aqouvrir la base de
|
||||
données avec le nom donné par le premier argument et démarrer une ses‐
|
||||
Si le premier argument de la ligne de commande ne commence pas par un
|
||||
tiret (i.e. pas d\(aqinstruction), gramps va essayer d\(aqouvrir la base de
|
||||
données avec le nom donné par le premier argument et démarrer une ses‐
|
||||
sion interactive, en ignorant le reste de la ligne de commande.
|
||||
.sp
|
||||
Si la commande \fB\-O\fP est notée, alors gramps va essayer le fichier défini
|
||||
Si la commande \fB\-O\fP est notée, alors gramps va essayer le fichier défini
|
||||
et va travailler avec ses données, comme pour les autres paramètres de
|
||||
la ligne de commande.
|
||||
.sp
|
||||
@@ -208,7 +202,7 @@ Utilisez les shell de redirection de \fIstdout\fP et \fIstderr\fP pour sauver
|
||||
les messages et les erreurs dans les fichiers.
|
||||
.TP
|
||||
.B \fBEXEMPLES\fP
|
||||
Pour ouvrir un arbre familial et y importer un fichier XML, on peut
|
||||
Pour ouvrir un arbre familial et y importer un fichier XML, on peut
|
||||
saisir:
|
||||
.INDENT 7.0
|
||||
.INDENT 3.5
|
||||
@@ -217,8 +211,8 @@ saisir:
|
||||
.UNINDENT
|
||||
.sp
|
||||
Ceci ouvre un arbre familial, pour faire la même chose, mais importer
|
||||
dans un arbre familial temporaire et démarrer une session interactive,
|
||||
on peut saisir:
|
||||
dans un arbre familial temporaire et démarrer une session interactive,
|
||||
on peut saisir :
|
||||
.INDENT 7.0
|
||||
.INDENT 3.5
|
||||
\fBgramps \-i\fP \fI\(aqMon Arbre Familial\(aq\fP \fB\-i\fP \fI~/db3.gramps\fP
|
||||
@@ -292,22 +286,25 @@ PROFILE pour Windows 2000/XP).
|
||||
.TP
|
||||
.B \fBCONCEPTS\fP
|
||||
Gramps est un système basé sur le support de plugin\-python, permettant
|
||||
d\(aqimporter et d\(aqexporter, la saisie, générer des rapports, des outils,
|
||||
et afficher des filtres pouvant être ajoutés sans modifier le programme.
|
||||
d\(aqimporter et d\(aqexporter, la saisie, générer des rapports, des outils,
|
||||
et afficher des filtres pouvant être ajoutés sans modifier le programme.
|
||||
.sp
|
||||
Par ailleurs, gramps permet la génération directe : impression, rap‐
|
||||
ports avec sortie vers d\(aqautres formats, comme \fILibreOffice.org\fP ,
|
||||
\fIHTML\fP , ou \fILaTeX\fP pour permettre à l\(aqutilisateur de choisir selon ses
|
||||
\fIHTML\fP , ou \fILaTeX\fP pour permettre à l\(aqutilisateur de choisir selon ses
|
||||
besoins
|
||||
.UNINDENT
|
||||
.sp
|
||||
\fBBUGS CONNUS ET LIMITATIONS\fP
|
||||
.sp
|
||||
\fBFICHIERS\fP
|
||||
.INDENT 0.0
|
||||
.INDENT 3.5
|
||||
\fI${PREFIX}/bin/gramps\fP
|
||||
.sp
|
||||
\fI${PREFIX}/share/gramps\fP
|
||||
\fI${PREFIX}/lib/python/dist\-packages/gramps/\fP
|
||||
.sp
|
||||
\fI${PREFIX}/share/\fP
|
||||
.sp
|
||||
\fI${HOME}/.gramps\fP
|
||||
.UNINDENT
|
||||
@@ -336,11 +333,10 @@ La documentation pour développeur est disponible sur le site
|
||||
\fI\%http://www.gramps-project.org/wiki/index.php?title=Portal:Developers\fP .
|
||||
.UNINDENT
|
||||
.sp
|
||||
Janvier 2013 4.0.0 gramps(1)
|
||||
gramps(1) @VERSION@ gramps(1)
|
||||
.SH AUTHOR
|
||||
Jerome Rapinat
|
||||
.SH COPYRIGHT
|
||||
2012, Gramps project
|
||||
.\" Generated by docutils manpage writer.
|
||||
.\"
|
||||
.
|
||||
|
@@ -298,9 +298,11 @@ or LaTeX to allow the users to modify the format to suit their needs.
|
||||
|
||||
.SH FILES
|
||||
.LP
|
||||
\fI${PREFIX}/bin/gramps\fP
|
||||
\fI${PREFIX}/bin/gramps\fP
|
||||
.br
|
||||
\fI${PREFIX}/share/gramps\fP
|
||||
\fI${PREFIX}/lib/python/dist\-packages/gramps/\fP
|
||||
.br
|
||||
\fI${PREFIX}/share/\fP
|
||||
.br
|
||||
\fI${HOME}/.gramps\fP
|
||||
|
||||
|
@@ -1,15 +0,0 @@
|
||||
# This is the data/man/nl level Makefile for Gramps
|
||||
# $Id: Makefile.am 9819 2008-01-15 15:42:10Z bmcage $
|
||||
|
||||
mandir = @mandir@/nl
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/nl/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
||||
|
@@ -227,11 +227,14 @@ gramps(1) 3.4.0 gramps(1)
|
||||
|
||||
|
||||
**GEKENDE BUGS EN BEPERKINGEN**
|
||||
|
||||
**BESTANDEN**
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps*
|
||||
|
||||
|
@@ -1,14 +0,0 @@
|
||||
# This is the data/man/sv level Makefile for Gramps
|
||||
# $Id: Makefile.am 6189 2006-03-21 19:05:46Z rshura $
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
mandir = @mandir@/pl
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/pl/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
@@ -276,7 +276,9 @@ gramps(1) 3.4.0 gramps(1)
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps (jeśli nie użyta została zmienna środowiskowa GRAMP‐
|
||||
SHOME)*
|
||||
|
@@ -1,14 +0,0 @@
|
||||
# This is the data/pt_BR level Makefile for Gramps
|
||||
# $Id: Makefile.am 16377 2011-01-13 18:32:42Z matlas $
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
mandir = @mandir@/pt_BR
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/pt_BR/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
@@ -255,9 +255,11 @@ gramps(1) 4.0.0 gramps(1)
|
||||
*ARQUIVOS**
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
|
||||
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps*
|
||||
|
||||
|
||||
|
@@ -1,14 +0,0 @@
|
||||
# This is the data/man/sv level Makefile for Gramps
|
||||
# $Id: Makefile.am 6189 2006-03-21 19:05:46Z rshura $
|
||||
|
||||
man_IN_FILES = gramps.1.in
|
||||
man_MANS = $(man_IN_FILES:.1.in=.1)
|
||||
|
||||
mandir = @mandir@/sv
|
||||
|
||||
EXTRA_DIST = $(man_MANS) $(man_IN_FILES)
|
||||
|
||||
gramps.1: $(top_builddir)/config.status gramps.1.in
|
||||
cd $(top_builddir) && CONFIG_FILES=data/man/sv/$@ $(SHELL) ./config.status
|
||||
|
||||
CLEANFILES=$(man_MANS)
|
@@ -246,7 +246,9 @@ Gramps(1) 3.4.0 Gramps(1)
|
||||
|
||||
*${PREFIX}/bin/gramps*
|
||||
|
||||
*${PREFIX}/share/gramps*
|
||||
*${PREFIX}/lib/python/dist-packages/gramps/*
|
||||
|
||||
*${PREFIX}/share/*
|
||||
|
||||
*${HOME}/.gramps*
|
||||
|
||||
|
@@ -52,11 +52,11 @@ SPHINXBUILD = 'sphinx-build'
|
||||
if sys.platform == 'win32':
|
||||
pythonCmd = os.path.join(sys.prefix, 'bin', 'python.exe')
|
||||
sphinxCmd = os.path.join(sys.prefix, 'bin', 'sphinx-build.exe')
|
||||
elif sys.platform == 'linux2' or os.name == 'darwin':
|
||||
elif sys.platform in ['linux2', 'darwin', 'cygwin']:
|
||||
pythonCmd = os.path.join(sys.prefix, 'bin', 'python')
|
||||
sphinxCmd = SPHINXBUILD
|
||||
else:
|
||||
print ("ERROR: unknown system, don't know sphinx, ... commands")
|
||||
print ("Update Man ERROR: unknown system, don't know sphinx, ... commands")
|
||||
sys.exit(0)
|
||||
|
||||
def tests():
|
||||
|
32
debian/control
vendored
32
debian/control
vendored
@@ -1,27 +1,17 @@
|
||||
Source: gramps
|
||||
Section: gnome
|
||||
Maintainer: Gramps Development Team
|
||||
Section: python
|
||||
Priority: optional
|
||||
Maintainer: Stéphane Charette <stephanecharette@gmail.com>
|
||||
Build-Depends-Indep: libxml-parser-perl, python-gtk2, gettext, python-central (>= 0.5.6), python, intltool
|
||||
Build-Depends: debhelper (>= 7)
|
||||
Standards-Version: 3.8.3
|
||||
Build-Depends-Indep: libxml-parser-perl, gettext, intltool
|
||||
Build-Depends: python-all (>= 2.7.0), debhelper (>= 7.4.3)
|
||||
Standards-Version: 3.9.1
|
||||
Homepage: http://www.gramps-project.org/
|
||||
XS-Python-Version: >=2.5
|
||||
|
||||
Package: gramps
|
||||
Architecture: all
|
||||
Depends: ${python:Depends}, librsvg2-common, python-gtk2, python-pyexiv2, xdg-utils, graphviz, python-osmgpsmap ${misc:Depends}
|
||||
Replaces: gramps-manual, gramps-extending-doc
|
||||
Conflicts: gramps-manual, gramps-extending-doc, gramps-common, python-gtk-1.2
|
||||
Recommends:
|
||||
Suggests: ttf-freefont, python-enchant, python-gtkspell
|
||||
Description: Genealogical research program
|
||||
GRAMPS is an Open Source genealogy program written in Python, using
|
||||
the GTK/GNOME interface. It is an extremely flexible program fitting
|
||||
the needs for both the amateur genealogist and serious genealogical
|
||||
researcher.
|
||||
GRAMPS has the ability to import GEDCOM files exported from many
|
||||
proprietary genealogy programs and can produce a large number of
|
||||
reports in many popular formats.
|
||||
XB-Python-Version: ${python:Versions}
|
||||
|
||||
Depends: ${misc:Depends}, ${python:Depends}, python-gobject (>= 3.3.2), librsvg2-2
|
||||
Recommends: python-pyicu, python-osmgpsmap, graphviz, xdg-utils
|
||||
Suggests: ttf-freefont, python-gtkspell, libgexiv2-1, rcs, python-imaging, python-pygoocanvas
|
||||
Description: Gramps (Genealogical Research and Analysis Management
|
||||
Programming System) is a full featured genealogy program supporting
|
||||
a Python based plugin system.
|
||||
|
2
debian/gramps.manpages
vendored
2
debian/gramps.manpages
vendored
@@ -1 +1 @@
|
||||
data/man/gramps.1
|
||||
data/man/gramps.1.in
|
||||
|
14
debian/gramps.preinst
vendored
Normal file
14
debian/gramps.preinst
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
#! /bin/sh
|
||||
|
||||
set -e
|
||||
|
||||
# This was added by stdeb to workaround Debian #479852. In a nutshell,
|
||||
# pycentral does not remove normally remove its symlinks on an
|
||||
# upgrade. Since we're using python-support, however, those symlinks
|
||||
# will be broken. This tells python-central to clean up any symlinks.
|
||||
if [ -e /var/lib/dpkg/info/gramps.list ] && which pycentral >/dev/null 2>&1
|
||||
then
|
||||
pycentral pkgremove gramps
|
||||
fi
|
||||
|
||||
#DEBHELPER#
|
72
debian/rules
vendored
72
debian/rules
vendored
@@ -1,73 +1,9 @@
|
||||
#!/usr/bin/make -f
|
||||
|
||||
build: build-stamp
|
||||
build-stamp:
|
||||
dh_testdir
|
||||
# This file was automatically generated by stdeb 0.6.0+git at
|
||||
# Sun, 31 Mar 2013 16:54:38 +0200
|
||||
|
||||
#./autogen.sh --prefix=/usr --mandir=\$${prefix}/share/man --sysconfdir=/etc
|
||||
./configure --enable-packager-mode --prefix=/usr --mandir=\$${prefix}/share/man --sysconfdir=/etc
|
||||
# ./configure --prefix=`pwd`/debian/tmp/usr --mandir=\$${prefix}/share/man
|
||||
$(MAKE)
|
||||
# $(MAKE) html
|
||||
|
||||
touch build-stamp
|
||||
|
||||
clean:
|
||||
dh_testdir
|
||||
dh_testroot
|
||||
|
||||
# [ ! -f Makefile ] || $(MAKE) distclean
|
||||
# -rm -f src/*.pyo src/*/*.pyo
|
||||
# -rm -f config.status config.log
|
||||
|
||||
dh_auto_clean
|
||||
dh_clean
|
||||
|
||||
install: build
|
||||
dh_testdir
|
||||
dh_testroot
|
||||
dh_prep
|
||||
dh_installdirs
|
||||
|
||||
# Add here commands to install the package into debian/tmp.
|
||||
# GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL=1
|
||||
$(MAKE) install DESTDIR=`pwd`/debian/gramps
|
||||
-rm -f debian/gramps/usr/share/gramps/COPYING
|
||||
ln -s /usr/share/common-licenses/GPL-2 debian/gramps/usr/share/gramps/COPYING
|
||||
-rm -rf debian/gramps/usr/var
|
||||
# cp src/data/gramps.xml debian/gramps/usr/share/mime/packages
|
||||
-find debian/gramps/usr/share/ -name "*.pyo" -exec rm -f '{}' ';'
|
||||
|
||||
cp debian/gramps.xpm debian/gramps/usr/share/pixmaps/
|
||||
# cp src/gramps.xpm debian/tmp/usr/share/pixmaps/
|
||||
# cp src/images/gramps.svg debian/gramps/usr/share/pixmaps/
|
||||
# chmod 644 debian/gramps/usr/share/pixmaps/gramps.svg
|
||||
|
||||
# Build architecture-independent files here.
|
||||
binary-indep: build install
|
||||
dh_testdir
|
||||
dh_testroot
|
||||
dh_installdocs FAQ
|
||||
dh_installmenu
|
||||
# dh_installman
|
||||
dh_installmime -i
|
||||
# dh_installchangelogs ChangeLog
|
||||
dh_installchangelogs
|
||||
dh_icons
|
||||
# dh_movefiles -i
|
||||
# dh_gconf -i
|
||||
dh_link -i
|
||||
dh_compress -i
|
||||
dh_fixperms -i
|
||||
dh_pycentral -i
|
||||
dh_installdeb -i
|
||||
dh_gencontrol -i
|
||||
dh_md5sums -i
|
||||
dh_builddeb -i
|
||||
%:
|
||||
dh $@ --with python2 --buildsystem=python_distutils
|
||||
|
||||
|
||||
# Build architecture-dependent files here.
|
||||
binary-arch: build install
|
||||
|
||||
binary: binary-indep binary-arch
|
||||
.PHONY: build clean binary-indep binary-arch binary install
|
||||
|
@@ -42,11 +42,11 @@ SPHINXBUILD = 'sphinx-build'
|
||||
if sys.platform == 'win32':
|
||||
pythonCmd = os.path.join(sys.prefix, 'bin', 'python.exe')
|
||||
sphinxCmd = os.path.join(sys.prefix, 'bin', 'sphinx-build.exe')
|
||||
elif sys.platform == 'linux2' or os.name == 'darwin':
|
||||
elif sys.platform in ['linux2', 'darwin', 'cygwin']:
|
||||
pythonCmd = os.path.join(sys.prefix, 'bin', 'python')
|
||||
sphinxCmd = SPHINXBUILD
|
||||
else:
|
||||
print ("ERROR: unknown system, don't know sphinx, ... commands")
|
||||
print ("Update Docs ERROR: unknown system, don't know sphinx, ... commands")
|
||||
sys.exit(0)
|
||||
|
||||
def tests():
|
||||
|
Binary file not shown.
@@ -39,7 +39,6 @@ Module responsible for handling the command line arguments for GRAMPS.
|
||||
from __future__ import print_function
|
||||
import os
|
||||
import sys
|
||||
from gramps.gen.ggettext import gettext as _
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
@@ -56,6 +55,8 @@ from gramps.gen.plug import BasePluginManager
|
||||
from gramps.gen.plug.report import CATEGORY_BOOK, CATEGORY_CODE, BookList
|
||||
from .plug import cl_report, cl_book
|
||||
from .user import User
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
@@ -165,6 +166,7 @@ class ArgHandler(object):
|
||||
self.actions = parser.actions
|
||||
self.list = parser.list
|
||||
self.list_more = parser.list_more
|
||||
self.list_table = parser.list_table
|
||||
self.open_gui = parser.open_gui
|
||||
self.imp_db_path = None
|
||||
self.dbman = CLIDbManager(self.dbstate)
|
||||
@@ -183,11 +185,9 @@ class ArgHandler(object):
|
||||
if self.errorfunc:
|
||||
self.errorfunc(msg1)
|
||||
else:
|
||||
# Need to convert to system file encoding before printing
|
||||
# For non latin characters in path/file/user names
|
||||
print(msg1.encode(sys.getfilesystemencoding()), file=sys.stderr)
|
||||
print(msg1, file=sys.stderr)
|
||||
if msg2 is not None:
|
||||
print(msg2.encode(sys.getfilesystemencoding()), file=sys.stderr)
|
||||
print(msg2, file=sys.stderr)
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
# Argument parser: sorts out given arguments
|
||||
@@ -218,7 +218,7 @@ class ArgHandler(object):
|
||||
if not self.check_db(db_path, self.force_unlock):
|
||||
sys.exit(0)
|
||||
if create:
|
||||
self.__error( _("Error: Family tree '%s' already exists.\n"
|
||||
self.__error( _("Error: Family Tree '%s' already exists.\n"
|
||||
"The '-C' option cannot be used.") % value)
|
||||
sys.exit(0)
|
||||
return db_path
|
||||
@@ -227,7 +227,7 @@ class ArgHandler(object):
|
||||
db_path, title = self.dbman.create_new_db_cli(title=value)
|
||||
return db_path
|
||||
else:
|
||||
self.__error( _('Error: Input family tree "%s" does not exist.\n'
|
||||
self.__error( _('Error: Input Family Tree "%s" does not exist.\n'
|
||||
"If GEDCOM, Gramps-xml or grdb, use the -i option "
|
||||
"to import into a family tree instead.") % value)
|
||||
sys.exit(0)
|
||||
@@ -293,14 +293,13 @@ class ArgHandler(object):
|
||||
ask = raw_input
|
||||
else:
|
||||
ask = input
|
||||
ans = ask(_('OK to overwrite? (yes/no) ') \
|
||||
.encode(sys.getfilesystemencoding()))
|
||||
ans = ask(_('OK to overwrite? (yes/no) '))
|
||||
except EOFError:
|
||||
print()
|
||||
sys.exit(0)
|
||||
if ans.upper() in ('Y', 'YES', _('YES').upper()):
|
||||
self.__error( _("Will overwrite the existing file: %s")
|
||||
% fullpath)
|
||||
self.__error(_("Will overwrite the existing file: %s")
|
||||
% fullpath)
|
||||
answer = "ok"
|
||||
else:
|
||||
sys.exit(0)
|
||||
@@ -377,12 +376,8 @@ class ArgHandler(object):
|
||||
if not self.check_db(db_path, self.force_unlock):
|
||||
sys.exit(0)
|
||||
# Add the file to the recent items
|
||||
path = os.path.join(db_path, "name.txt")
|
||||
try:
|
||||
ifile = open(path)
|
||||
title = ifile.readline().strip()
|
||||
ifile.close()
|
||||
except:
|
||||
title = self.dbstate.db.get_dbname()
|
||||
if not title:
|
||||
title = db_path
|
||||
recent_files(db_path, title)
|
||||
self.open = db_path
|
||||
@@ -407,47 +402,59 @@ class ArgHandler(object):
|
||||
"""
|
||||
|
||||
if self.list:
|
||||
print(_('List of known family trees in your database path\n').\
|
||||
encode(sys.getfilesystemencoding()))
|
||||
print(_('List of known Family Trees in your database path\n'))
|
||||
|
||||
for name, dirname in sorted(self.dbman.family_tree_list(),
|
||||
key=lambda pair: pair[0].lower()):
|
||||
|
||||
print((_("%(full_DB_path)s with name \"%(f_t_name)s\"") % \
|
||||
{'full_DB_path' : dirname,
|
||||
'f_t_name' : name}).encode(sys.getfilesystemencoding()))
|
||||
|
||||
print(_("%(full_DB_path)s with name \"%(f_t_name)s\"")
|
||||
% {'full_DB_path' : dirname, 'f_t_name' : name})
|
||||
sys.exit(0)
|
||||
|
||||
|
||||
if self.list_more:
|
||||
print(_('Gramps Family Trees:').encode(sys.getfilesystemencoding()))
|
||||
print(_('Gramps Family Trees:'))
|
||||
summary_list = self.dbman.family_tree_summary()
|
||||
for summary in sorted(summary_list,
|
||||
key=lambda sum: sum["Family tree"].lower()):
|
||||
print(_("Family Tree \"%s\":").\
|
||||
encode(sys.getfilesystemencoding()) % summary["Family tree"])
|
||||
key=lambda sum: sum[_("Family Tree")].lower()):
|
||||
print(_("Family Tree \"%s\":") % summary[_("Family Tree")])
|
||||
for item in sorted(summary):
|
||||
if item != "Family tree":
|
||||
print((" %s: %s" % (item, summary[item])).\
|
||||
encode(sys.getfilesystemencoding()))
|
||||
if item != "Family Tree":
|
||||
print(" %s: %s" % (item, summary[item]))
|
||||
sys.exit(0)
|
||||
|
||||
if self.list_table:
|
||||
print(_('Gramps Family Trees:'))
|
||||
summary_list = self.dbman.family_tree_summary()
|
||||
print(_("Family Tree"), end="")
|
||||
for key in sorted(summary_list[0]):
|
||||
if key != "Family Tree":
|
||||
print("\t ", end="")
|
||||
print(key, end="")
|
||||
print()
|
||||
for summary in sorted(summary_list,
|
||||
key=lambda sum: sum[_("Family Tree")].lower()):
|
||||
print('"%s"' % summary[_("Family Tree")], end="")
|
||||
for item in sorted(summary):
|
||||
if item != _("Family Tree"):
|
||||
print("\t ", end="")
|
||||
print('"%s"' % summary[item], end="")
|
||||
print()
|
||||
sys.exit(0)
|
||||
|
||||
self.__open_action()
|
||||
self.__import_action()
|
||||
|
||||
for (action, op_string) in self.actions:
|
||||
print(_("Performing action: %s.") % action, file=sys.stderr)
|
||||
if op_string:
|
||||
print(_("Using options string: %s") % op_string, file=sys.stderr)
|
||||
print(_("Using options string: %s")
|
||||
% op_string, file=sys.stderr)
|
||||
self.cl_action(action, op_string)
|
||||
|
||||
for expt in self.exports:
|
||||
# Need to convert path/filename to str before printing
|
||||
# For non latin characters in Windows path/file/user names
|
||||
fn = expt[0].encode(sys.getfilesystemencoding())
|
||||
fmt = str(expt[1])
|
||||
print(_("Exporting: file %(filename)s, "
|
||||
"format %(format)s.") % \
|
||||
{'filename' : fn,
|
||||
'format' : fmt}, file=sys.stderr)
|
||||
print(_("Exporting: file %(filename)s, format %(format)s.")
|
||||
% {'filename' : expt[0],
|
||||
'format' : expt[1]}, file=sys.stderr)
|
||||
self.cl_export(expt[0], expt[1])
|
||||
|
||||
if cleanup:
|
||||
@@ -479,14 +486,13 @@ class ArgHandler(object):
|
||||
if self.gui:
|
||||
self.imp_db_path, title = self.dbman.create_new_db_cli()
|
||||
else:
|
||||
self.imp_db_path = get_empty_tempdir("import_dbdir") \
|
||||
.encode(sys.getfilesystemencoding())
|
||||
self.imp_db_path = get_empty_tempdir("import_dbdir")
|
||||
newdb = DbBsddb()
|
||||
newdb.write_version(self.imp_db_path)
|
||||
|
||||
try:
|
||||
self.sm.open_activate(self.imp_db_path)
|
||||
msg = _("Created empty family tree successfully")
|
||||
msg = _("Created empty Family Tree successfully")
|
||||
print(msg, file=sys.stderr)
|
||||
except:
|
||||
print(_("Error opening the file."), file=sys.stderr)
|
||||
@@ -494,10 +500,8 @@ class ArgHandler(object):
|
||||
sys.exit(0)
|
||||
|
||||
for imp in self.imports:
|
||||
fn = imp[0].encode(sys.getfilesystemencoding())
|
||||
fmt = str(imp[1])
|
||||
msg = _("Importing: file %(filename)s, format %(format)s.") % \
|
||||
{'filename' : fn, 'format' : fmt}
|
||||
{'filename' : imp[0], 'format' : imp[1]}
|
||||
print(msg, file=sys.stderr)
|
||||
self.cl_import(imp[0], imp[1])
|
||||
|
||||
@@ -589,7 +593,8 @@ class ArgHandler(object):
|
||||
options_str_dict = _split_options(options_str)
|
||||
except:
|
||||
options_str_dict = {}
|
||||
print(_("Ignoring invalid options string."), file=sys.stderr)
|
||||
print(_("Ignoring invalid options string."),
|
||||
file=sys.stderr)
|
||||
|
||||
name = options_str_dict.pop('name', None)
|
||||
_cl_list = pmgr.get_reg_reports(gui=False)
|
||||
@@ -617,16 +622,17 @@ class ArgHandler(object):
|
||||
msg = _("Report name not given. "
|
||||
"Please use one of %(donottranslate)s=reportname") % \
|
||||
{'donottranslate' : '[-p|--options] name'}
|
||||
|
||||
|
||||
print(_("%s\n Available names are:") % msg, file=sys.stderr)
|
||||
for pdata in sorted(_cl_list, key= lambda pdata: pdata.id.lower()):
|
||||
# Print cli report name ([item[0]), GUI report name (item[4])
|
||||
if len(pdata.id) <= 25:
|
||||
print(" %s%s- %s" % ( pdata.id, " " * (26 - len(pdata.id)),
|
||||
pdata.name.encode(sys.getfilesystemencoding())), file=sys.stderr)
|
||||
print(" %s%s- %s"
|
||||
% ( pdata.id, " " * (26 - len(pdata.id)),
|
||||
pdata.name), file=sys.stderr)
|
||||
else:
|
||||
print(" %s\t- %s" % (pdata.id,
|
||||
pdata.name.encode(sys.getfilesystemencoding())), file=sys.stderr)
|
||||
print(" %s\t- %s"
|
||||
% (pdata.id, pdata.name), file=sys.stderr)
|
||||
|
||||
elif action == "tool":
|
||||
from gramps.gui.plug import tool
|
||||
@@ -635,7 +641,8 @@ class ArgHandler(object):
|
||||
chunk in options_str.split(',') ] )
|
||||
except:
|
||||
options_str_dict = {}
|
||||
print(_("Ignoring invalid options string."), file=sys.stderr)
|
||||
print(_("Ignoring invalid options string."),
|
||||
file=sys.stderr)
|
||||
|
||||
name = options_str_dict.pop('name', None)
|
||||
_cli_tool_list = pmgr.get_reg_tools(gui=False)
|
||||
@@ -657,24 +664,26 @@ class ArgHandler(object):
|
||||
msg = _("Tool name not given. "
|
||||
"Please use one of %(donottranslate)s=toolname.") % \
|
||||
{'donottranslate' : '[-p|--options] name'}
|
||||
|
||||
|
||||
print(_("%s\n Available names are:") % msg, file=sys.stderr)
|
||||
for pdata in sorted(_cli_tool_list,
|
||||
key=lambda pdata: pdata.id.lower()):
|
||||
# Print cli report name ([item[0]), GUI report name (item[4])
|
||||
if len(pdata.id) <= 25:
|
||||
print(" %s%s- %s" % ( pdata.id, " " * (26 - len(pdata.id)),
|
||||
pdata.name.encode(sys.getfilesystemencoding())), file=sys.stderr)
|
||||
print(" %s%s- %s"
|
||||
% ( pdata.id, " " * (26 - len(pdata.id)),
|
||||
pdata.name), file=sys.stderr)
|
||||
else:
|
||||
print(" %s\t- %s" % (pdata.id,
|
||||
pdata.name.encode(sys.getfilesystemencoding())), file=sys.stderr)
|
||||
print(" %s\t- %s"
|
||||
% (pdata.id, pdata.name), file=sys.stderr)
|
||||
|
||||
elif action == "book":
|
||||
try:
|
||||
options_str_dict = _split_options(options_str)
|
||||
except:
|
||||
options_str_dict = {}
|
||||
print(_("Ignoring invalid options string."), file=sys.stderr)
|
||||
print(_("Ignoring invalid options string."),
|
||||
file=sys.stderr)
|
||||
|
||||
name = options_str_dict.pop('name', None)
|
||||
book_list = BookList('books.xml', self.dbstate.db)
|
||||
|
@@ -39,7 +39,6 @@ Module responsible for handling the command line arguments for GRAMPS.
|
||||
from __future__ import print_function
|
||||
import sys
|
||||
import getopt
|
||||
from gramps.gen.ggettext import gettext as _
|
||||
import logging
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
@@ -51,6 +50,8 @@ from gramps.gen.const import LONGOPTS, SHORTOPTS
|
||||
from gramps.gen.config import config
|
||||
from gramps.gen.utils.configmanager import safe_eval
|
||||
from gramps.gen.utils.file import get_unicode_path_from_env_var
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
# Note: Make sure to edit const.py.in POPT_TABLE too!
|
||||
_HELP = _("""
|
||||
@@ -62,17 +63,18 @@ Help options
|
||||
--usage Display brief usage message
|
||||
|
||||
Application options
|
||||
-O, --open=FAMILY_TREE Open family tree
|
||||
-C, --create=FAMILY_TREE Create on open if new family tree
|
||||
-O, --open=FAMILY_TREE Open Family Tree
|
||||
-C, --create=FAMILY_TREE Create on open if new Family Tree
|
||||
-i, --import=FILENAME Import file
|
||||
-e, --export=FILENAME Export file
|
||||
-f, --format=FORMAT Specify family tree format
|
||||
-f, --format=FORMAT Specify Family Tree format
|
||||
-a, --action=ACTION Specify action
|
||||
-p, --options=OPTIONS_STRING Specify options
|
||||
-d, --debug=LOGGER_NAME Enable debug logs
|
||||
-l List Family Trees
|
||||
-L List Family Trees in Detail
|
||||
-u, --force-unlock Force unlock of family tree
|
||||
-t List Family Trees, tab delimited
|
||||
-u, --force-unlock Force unlock of Family Tree
|
||||
-s, --show Show config settings
|
||||
-c, --config=[config.setting[:value]] Set config setting(s) and start Gramps
|
||||
-v, --version Show versions
|
||||
@@ -110,7 +112,7 @@ Use the name=timeline,show=all to find out about all available options for the t
|
||||
To find out details of a particular option, use show=option_name , e.g. name=timeline,show=off string.
|
||||
To learn about available report names, use name=show string.
|
||||
|
||||
9. To convert a family tree on the fly to a .gramps xml file:
|
||||
9. To convert a Family Tree on the fly to a .gramps xml file:
|
||||
gramps -O 'Family Tree 1' -e output.gramps -f gramps-xml
|
||||
|
||||
10. To generate a web site into an other locale (in german):
|
||||
@@ -175,6 +177,7 @@ class ArgParser(object):
|
||||
self.imp_db_path = None
|
||||
self.list = False
|
||||
self.list_more = False
|
||||
self.list_table = False
|
||||
self.help = False
|
||||
self.usage = False
|
||||
self.force_unlock = False
|
||||
@@ -241,7 +244,8 @@ class ArgParser(object):
|
||||
# if there were an argument without option,
|
||||
# use it as a file to open and return
|
||||
self.open_gui = leftargs[0]
|
||||
print ("Trying to open: %s ..." % leftargs[0], file=sys.stderr)
|
||||
print(_("Trying to open: %s ...") % leftargs[0],
|
||||
file=sys.stderr)
|
||||
#see if force open is on
|
||||
for opt_ix in range(len(options)):
|
||||
option, value = options[opt_ix]
|
||||
@@ -274,7 +278,8 @@ class ArgParser(object):
|
||||
elif option in ( '-a', '--action' ):
|
||||
action = value
|
||||
if action not in ('report', 'tool', 'book'):
|
||||
print ("Unknown action: %s. Ignoring." % action, file=sys.stderr)
|
||||
print(_("Unknown action: %s. Ignoring.") % action,
|
||||
file=sys.stderr)
|
||||
continue
|
||||
options_str = ""
|
||||
if opt_ix < len(options)-1 \
|
||||
@@ -282,7 +287,7 @@ class ArgParser(object):
|
||||
options_str = options[opt_ix+1][1]
|
||||
self.actions.append((action, options_str))
|
||||
elif option in ('-d', '--debug'):
|
||||
print ('setup debugging', value, file=sys.stderr)
|
||||
print(_('setup debugging'), value, file=sys.stderr)
|
||||
logger = logging.getLogger(value)
|
||||
logger.setLevel(logging.DEBUG)
|
||||
cleandbg += [opt_ix]
|
||||
@@ -290,15 +295,17 @@ class ArgParser(object):
|
||||
self.list = True
|
||||
elif option in ('-L'):
|
||||
self.list_more = True
|
||||
elif option in ('-t'):
|
||||
self.list_table = True
|
||||
elif option in ('-s','--show'):
|
||||
print ("Gramps config settings from %s:" % \
|
||||
config.filename.encode(sys.getfilesystemencoding()))
|
||||
print(_("Gramps config settings from %s:")
|
||||
% config.filename)
|
||||
for section in config.data:
|
||||
for setting in config.data[section]:
|
||||
print ("%s.%s=%s" % (
|
||||
section, setting,
|
||||
repr(config.data[section][setting])))
|
||||
print ('')
|
||||
print("%s.%s=%s"
|
||||
% (section, setting,
|
||||
repr(config.data[section][setting])))
|
||||
print()
|
||||
sys.exit(0)
|
||||
elif option in ('-c', '--config'):
|
||||
setting_name = value
|
||||
@@ -309,24 +316,24 @@ class ArgParser(object):
|
||||
set_value = True
|
||||
if config.has_default(setting_name):
|
||||
setting_value = config.get(setting_name)
|
||||
print ("Current Gramps config setting: " \
|
||||
"%s:%s" % (setting_name, repr(setting_value)), file=sys.stderr)
|
||||
print(_("Current Gramps config setting: %s:%s")
|
||||
% (setting_name, repr(setting_value)),
|
||||
file=sys.stderr)
|
||||
if set_value:
|
||||
if new_value == "DEFAULT":
|
||||
new_value = config.get_default(setting_name)
|
||||
else:
|
||||
new_value = safe_eval(new_value)
|
||||
config.set(setting_name, new_value)
|
||||
print (" New Gramps config " \
|
||||
"setting: %s:%s" % (
|
||||
setting_name,
|
||||
repr(config.get(setting_name))
|
||||
), file=sys.stderr)
|
||||
print(_(" New Gramps config setting: %s:%s")
|
||||
% (setting_name,
|
||||
repr(config.get(setting_name))),
|
||||
file=sys.stderr)
|
||||
else:
|
||||
need_to_quit = True
|
||||
else:
|
||||
print ("Gramps: no such config setting:" \
|
||||
" '%s'" % setting_name, file=sys.stderr)
|
||||
print(_("Gramps: no such config setting: '%s'")
|
||||
% setting_name, file=sys.stderr)
|
||||
need_to_quit = True
|
||||
cleandbg += [opt_ix]
|
||||
elif option in ('-h', '-?', '--help'):
|
||||
@@ -344,7 +351,8 @@ class ArgParser(object):
|
||||
del options[ind]
|
||||
|
||||
if len(options) > 0 and self.open is None and self.imports == [] \
|
||||
and not (self.list or self.list_more or self.help or self.runqml):
|
||||
and not (self.list or self.list_more or self.list_table or
|
||||
self.help or self.runqml):
|
||||
# Extract and convert to unicode the arguments in the list.
|
||||
# The % operator replaces the list elements with repr() of
|
||||
# the list elements, which is OK for latin characters
|
||||
@@ -371,7 +379,7 @@ class ArgParser(object):
|
||||
#errors in argument parsing ==> give cli error, no gui needed
|
||||
return False
|
||||
|
||||
if self.list or self.list_more or self.help:
|
||||
if self.list or self.list_more or self.list_table or self.help:
|
||||
return False
|
||||
|
||||
if self.open_gui:
|
||||
@@ -401,15 +409,13 @@ class ArgParser(object):
|
||||
If the user gives the --help or -h option, print the output to terminal.
|
||||
"""
|
||||
if self.help:
|
||||
# Convert Help messages to file system encoding before printing
|
||||
print (_HELP.encode(sys.getfilesystemencoding()))
|
||||
print(_HELP)
|
||||
sys.exit(0)
|
||||
|
||||
|
||||
def print_usage(self):
|
||||
"""
|
||||
If the user gives the --usage print the output to terminal.
|
||||
"""
|
||||
if self.usage:
|
||||
# Convert Help messages to file system encoding before printing
|
||||
print (_USAGE.encode(sys.getfilesystemencoding()))
|
||||
print(_USAGE)
|
||||
sys.exit(0)
|
||||
|
@@ -44,7 +44,6 @@ else:
|
||||
from urllib.parse import urlparse
|
||||
from urllib.request import urlopen, url2pathname
|
||||
import tempfile
|
||||
from gramps.gen.ggettext import gettext as _
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# set up logging
|
||||
@@ -52,12 +51,16 @@ from gramps.gen.ggettext import gettext as _
|
||||
#-------------------------------------------------------------------------
|
||||
import logging
|
||||
LOG = logging.getLogger(".clidbman")
|
||||
from gramps.gen.db.dbconst import DBLOGNAME
|
||||
_LOG = logging.getLogger(DBLOGNAME)
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# gramps modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
from gramps.gen.db import DbBsddb
|
||||
from gramps.gen.plug import BasePluginManager
|
||||
from gramps.gen.config import config
|
||||
@@ -135,70 +138,94 @@ class CLIDbManager(object):
|
||||
"""
|
||||
pass
|
||||
|
||||
def get_dbdir_summary(self, file_name):
|
||||
def get_dbdir_summary(self, dirpath, name):
|
||||
"""
|
||||
Returns (people_count, version_number) of current DB.
|
||||
Returns ("Unknown", "Unknown") if invalid DB or other error.
|
||||
Returns (people_count, bsddb_version, schema_version) of
|
||||
current DB.
|
||||
Returns ("Unknown", "Unknown", "Unknown") if invalid DB or other error.
|
||||
"""
|
||||
if config.get('preferences.use-bsddb3') or sys.version_info[0] >= 3:
|
||||
from bsddb3 import dbshelve, db
|
||||
else:
|
||||
from bsddb import dbshelve, db
|
||||
|
||||
from gramps.gen.db import META, PERSON_TBL
|
||||
from gramps.gen.db.dbconst import BDBVERSFN
|
||||
|
||||
bdbversion_file = os.path.join(dirpath, BDBVERSFN)
|
||||
if os.path.isfile(bdbversion_file):
|
||||
vers_file = open(bdbversion_file)
|
||||
bsddb_version = vers_file.readline().strip()
|
||||
else:
|
||||
return "Unknown", "Unknown", "Unknown"
|
||||
|
||||
current_bsddb_version = str(db.version())
|
||||
if bsddb_version != current_bsddb_version:
|
||||
return "Unknown", bsddb_version, "Unknown"
|
||||
|
||||
env = db.DBEnv()
|
||||
flags = db.DB_CREATE | db.DB_PRIVATE |\
|
||||
db.DB_INIT_MPOOL | db.DB_INIT_LOCK |\
|
||||
db.DB_INIT_LOG | db.DB_INIT_TXN | db.DB_THREAD
|
||||
db.DB_INIT_MPOOL |\
|
||||
db.DB_INIT_LOG | db.DB_INIT_TXN
|
||||
try:
|
||||
env.open(file_name, flags)
|
||||
except:
|
||||
return "Unknown", "Unknown"
|
||||
env.open(dirpath, flags)
|
||||
except Exception as msg:
|
||||
LOG.warning("Error opening db environment for '%s': %s" %
|
||||
(name, str(msg)))
|
||||
try:
|
||||
env.close()
|
||||
except Exception as msg:
|
||||
LOG.warning("Error closing db environment for '%s': %s" %
|
||||
(name, str(msg)))
|
||||
return "Unknown", bsddb_version, "Unknown"
|
||||
dbmap1 = dbshelve.DBShelf(env)
|
||||
fname = os.path.join(file_name, META + ".db")
|
||||
fname = os.path.join(dirpath, META + ".db")
|
||||
try:
|
||||
dbmap1.open(fname, META, db.DB_HASH, db.DB_RDONLY)
|
||||
except:
|
||||
return "Unknown", "Unknown"
|
||||
version = dbmap1.get('version', default=None)
|
||||
env.close()
|
||||
return "Unknown", bsddb_version, "Unknown"
|
||||
schema_version = dbmap1.get(b'version', default=None)
|
||||
dbmap1.close()
|
||||
dbmap2 = dbshelve.DBShelf(env)
|
||||
fname = os.path.join(file_name, PERSON_TBL + ".db")
|
||||
fname = os.path.join(dirpath, PERSON_TBL + ".db")
|
||||
try:
|
||||
dbmap2.open(fname, PERSON_TBL, db.DB_HASH, db.DB_RDONLY)
|
||||
except:
|
||||
env.close()
|
||||
return "Unknown", "Unknown"
|
||||
return "Unknown", bsddb_version, schema_version
|
||||
count = len(dbmap2)
|
||||
dbmap2.close()
|
||||
env.close()
|
||||
return (count, version)
|
||||
return (count, bsddb_version, schema_version)
|
||||
|
||||
def family_tree_summary(self):
|
||||
"""
|
||||
Return a list of dictionaries of the known family trees.
|
||||
"""
|
||||
# make the default directory if it does not exist
|
||||
list = []
|
||||
summary_list = []
|
||||
for item in self.current_names:
|
||||
(name, dirpath, path_name, last,
|
||||
tval, enable, stock_id) = item
|
||||
count, version = self.get_dbdir_summary(dirpath)
|
||||
count, bsddb_version, schema_version = self.get_dbdir_summary(dirpath, name)
|
||||
retval = {}
|
||||
retval["Number of people"] = count
|
||||
retval[_("Number of people")] = count
|
||||
if enable:
|
||||
retval["Locked?"] = "yes"
|
||||
retval[_("Locked?")] = _("yes")
|
||||
else:
|
||||
retval["Locked?"] = "no"
|
||||
retval["DB version"] = version
|
||||
retval[_("Locked?")] = _("no")
|
||||
retval[_("Bsddb version")] = bsddb_version
|
||||
retval[_("Schema version")] = schema_version
|
||||
if sys.version_info[0] < 3:
|
||||
retval["Family tree"] = name.encode(sys.getfilesystemencoding())
|
||||
retval[_("Family Tree")] = name.encode(glocale.getfilesystemencoding())
|
||||
else:
|
||||
retval["Family tree"] = name
|
||||
retval["Path"] = dirpath
|
||||
retval["Last accessed"] = time.strftime('%x %X',
|
||||
retval[_("Family Tree")] = name
|
||||
retval[_("Path")] = dirpath
|
||||
retval[_("Last accessed")] = time.strftime('%x %X',
|
||||
time.localtime(tval))
|
||||
list.append( retval )
|
||||
return list
|
||||
summary_list.append( retval )
|
||||
return summary_list
|
||||
|
||||
def _populate_cli(self):
|
||||
""" Get the list of current names in the database dir
|
||||
@@ -206,7 +233,7 @@ class CLIDbManager(object):
|
||||
# make the default directory if it does not exist
|
||||
dbdir = os.path.expanduser(config.get('behavior.database-path'))
|
||||
if sys.version_info[0] < 3:
|
||||
dbdir = dbdir.encode(sys.getfilesystemencoding())
|
||||
dbdir = dbdir.encode(glocale.getfilesystemencoding())
|
||||
db_ok = make_dbdir(dbdir)
|
||||
|
||||
self.current_names = []
|
||||
@@ -217,6 +244,7 @@ class CLIDbManager(object):
|
||||
if os.path.isfile(path_name):
|
||||
file = open(path_name)
|
||||
name = file.readline().strip()
|
||||
file.close()
|
||||
|
||||
(tval, last) = time_val(dirpath)
|
||||
(enable, stock_id) = self.icon_values(dirpath, self.active,
|
||||
@@ -324,6 +352,11 @@ class CLIDbManager(object):
|
||||
# write locally:
|
||||
temp_fp.write(data)
|
||||
url_fp.close()
|
||||
from gen.db.dbconst import BDBVERSFN
|
||||
versionpath = os.path.join(name, BDBVERSFN)
|
||||
_LOG.debug("Write bsddb version %s" % str(dbase.version()))
|
||||
with open(versionpath, "w") as version_file:
|
||||
version_file.write(str(dbase.version()))
|
||||
temp_fp.close()
|
||||
|
||||
(name, ext) = os.path.splitext(os.path.basename(filename))
|
||||
@@ -379,7 +412,7 @@ class CLIDbManager(object):
|
||||
name_file.write(new_text)
|
||||
name_file.close()
|
||||
except (OSError, IOError) as msg:
|
||||
CLIDbManager.ERROR(_("Could not rename family tree"),
|
||||
CLIDbManager.ERROR(_("Could not rename Family Tree"),
|
||||
str(msg))
|
||||
return None, None
|
||||
return old_text, new_text
|
||||
@@ -413,7 +446,7 @@ def make_dbdir(dbdir):
|
||||
if not os.path.isdir(dbdir):
|
||||
os.makedirs(dbdir)
|
||||
except (IOError, OSError) as msg:
|
||||
msg = conv_to_unicode(str(msg), sys.getfilesystemencoding())
|
||||
msg = conv_to_unicode(str(msg), glocale.getfilesystemencoding())
|
||||
LOG.error(_("\nERROR: Wrong database path in Edit Menu->Preferences.\n"
|
||||
"Open preferences and set correct database path.\n\n"
|
||||
"Details: Could not make database directory:\n %s\n\n") % msg)
|
||||
@@ -442,7 +475,7 @@ def find_next_db_dir():
|
||||
base = "%x" % int(time.time())
|
||||
dbdir = os.path.expanduser(config.get('behavior.database-path'))
|
||||
if sys.version_info[0] < 3:
|
||||
dbdir = dbdir.encode(sys.getfilesystemencoding())
|
||||
dbdir = dbdir.encode(glocale.getfilesystemencoding())
|
||||
new_path = os.path.join(dbdir, base)
|
||||
if not os.path.isdir(new_path):
|
||||
break
|
||||
@@ -485,7 +518,7 @@ def find_locker_name(dirpath):
|
||||
# Convert username to unicode according to system encoding
|
||||
# Otherwise problems with non ASCII characters in
|
||||
# username in Windows
|
||||
username = conv_to_unicode(username, sys.getfilesystemencoding())
|
||||
username = conv_to_unicode(username, glocale.getfilesystemencoding())
|
||||
# feature request 2356: avoid genitive form
|
||||
last = _("Locked by %s") % username
|
||||
ifile.close()
|
||||
|
@@ -35,7 +35,8 @@ Provides also two small base classes: CLIDbLoader, CLIManager
|
||||
#-------------------------------------------------------------------------
|
||||
from __future__ import print_function
|
||||
|
||||
from gramps.gen.ggettext import gettext as _
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
import os
|
||||
import sys
|
||||
|
||||
@@ -54,7 +55,13 @@ from gramps.gen.errors import DbError
|
||||
from gramps.gen.dbstate import DbState
|
||||
from gramps.gen.db import DbBsddb
|
||||
from gramps.gen.db.exceptions import (DbUpgradeRequiredError,
|
||||
DbVersionError)
|
||||
BsddbDowngradeError,
|
||||
DbVersionError,
|
||||
DbEnvironmentError,
|
||||
BsddbUpgradeRequiredError,
|
||||
BsddbDowngradeRequiredError,
|
||||
PythonUpgradeRequiredError,
|
||||
PythonDowngradeError)
|
||||
from gramps.gen.plug import BasePluginManager
|
||||
from gramps.gen.utils.config import get_researcher
|
||||
from gramps.gen.recentfiles import recent_files
|
||||
@@ -76,14 +83,14 @@ class CLIDbLoader(object):
|
||||
"""
|
||||
Issue a warning message. Inherit for GUI action
|
||||
"""
|
||||
print(_('WARNING: %s') % warnmessage)
|
||||
print(_('WARNING: %s') % warnmessage, file=sys.stderr)
|
||||
|
||||
def _errordialog(self, title, errormessage):
|
||||
"""
|
||||
Show the error. A title for the error and an errormessage
|
||||
Inherit for GUI action
|
||||
"""
|
||||
print(_('ERROR: %s') % errormessage)
|
||||
print(_('ERROR: %s') % errormessage, file=sys.stderr)
|
||||
sys.exit(1)
|
||||
|
||||
def _dberrordialog(self, msg):
|
||||
@@ -157,17 +164,35 @@ class CLIDbLoader(object):
|
||||
try:
|
||||
self.dbstate.db.load(filename, self._pulse_progress, mode)
|
||||
self.dbstate.db.set_save_path(filename)
|
||||
except gen.db.exceptions.DbUpgradeRequiredError as msg:
|
||||
except DbEnvironmentError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except gen.db.exceptions.DbVersionError as msg:
|
||||
except BsddbUpgradeRequiredError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except BsddbDowngradeRequiredError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except BsddbDowngradeError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except DbUpgradeRequiredError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except PythonDowngradeError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except PythonUpgradeRequiredError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except DbVersionError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog( _("Cannot open database"), str(msg))
|
||||
except OSError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._errordialog(
|
||||
_("Could not open file: %s") % filename, str(msg))
|
||||
except Errors.DbError as msg:
|
||||
except DbError as msg:
|
||||
self.dbstate.no_database()
|
||||
self._dberrordialog(msg)
|
||||
except Exception:
|
||||
@@ -196,7 +221,7 @@ class CLIManager(object):
|
||||
self.db_loader = None
|
||||
self.file_loaded = False
|
||||
self._pmgr = BasePluginManager.get_instance()
|
||||
|
||||
|
||||
def open_activate(self, path):
|
||||
"""
|
||||
Open and make a family tree active
|
||||
@@ -207,7 +232,7 @@ class CLIManager(object):
|
||||
"""
|
||||
Show the error. A title for the error and an errormessage
|
||||
"""
|
||||
print(_('ERROR: %s') % errormessage)
|
||||
print(_('ERROR: %s') % errormessage, file=sys.stderr)
|
||||
sys.exit(1)
|
||||
|
||||
def _read_recent_file(self, filename):
|
||||
@@ -294,24 +319,18 @@ def startcli(errors, argparser):
|
||||
"""
|
||||
if errors:
|
||||
#already errors encountered. Show first one on terminal and exit
|
||||
# Convert error message to file system encoding before print
|
||||
errmsg = _('Error encountered: %s') % errors[0][0]
|
||||
errmsg = errmsg.encode(sys.getfilesystemencoding())
|
||||
print(errmsg)
|
||||
print(errmsg, file=sys.stderr)
|
||||
errmsg = _(' Details: %s') % errors[0][1]
|
||||
errmsg = errmsg.encode(sys.getfilesystemencoding())
|
||||
print(errmsg)
|
||||
print(errmsg, file=sys.stderr)
|
||||
sys.exit(1)
|
||||
|
||||
if argparser.errors:
|
||||
# Convert error message to file system encoding before print
|
||||
errmsg = _('Error encountered in argument parsing: %s') \
|
||||
% argparser.errors[0][0]
|
||||
errmsg = errmsg.encode(sys.getfilesystemencoding())
|
||||
print(errmsg)
|
||||
print(errmsg, file=sys.stderr)
|
||||
errmsg = _(' Details: %s') % argparser.errors[0][1]
|
||||
errmsg = errmsg.encode(sys.getfilesystemencoding())
|
||||
print(errmsg)
|
||||
print(errmsg, file=sys.stderr)
|
||||
sys.exit(1)
|
||||
|
||||
#we need to keep track of the db state
|
||||
|
@@ -34,8 +34,6 @@
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from __future__ import print_function
|
||||
|
||||
from gramps.gen.ggettext import gettext as _
|
||||
import traceback
|
||||
import os
|
||||
import sys
|
||||
@@ -59,13 +57,15 @@ from gramps.gen.display.name import displayer as name_displayer
|
||||
from gramps.gen.errors import ReportError, FilterError
|
||||
from gramps.gen.plug.report import (CATEGORY_TEXT, CATEGORY_DRAW, CATEGORY_BOOK,
|
||||
CATEGORY_GRAPHVIZ, CATEGORY_CODE,
|
||||
ReportOptions, create_style_sheet)
|
||||
ReportOptions, append_styles)
|
||||
from gramps.gen.plug.report._paper import paper_sizes
|
||||
from gramps.gen.const import USER_HOME
|
||||
from gramps.gen.dbstate import DbState
|
||||
from gramps.gen.constfunc import STRTYPE, conv_to_unicode_direct
|
||||
from ..grampscli import CLIManager
|
||||
from ..user import User
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
#
|
||||
@@ -168,7 +168,8 @@ def _validate_options(options, dbase):
|
||||
phandle = None
|
||||
person = dbase.get_person_from_handle(phandle)
|
||||
if not person:
|
||||
print(_("ERROR: Please specify a person"))
|
||||
print(_("ERROR: Please specify a person"),
|
||||
file=sys.stderr)
|
||||
if person:
|
||||
option.set_value(person.get_gramps_id())
|
||||
|
||||
@@ -192,7 +193,7 @@ def _validate_options(options, dbase):
|
||||
family = dbase.get_family_from_handle(family_handle)
|
||||
option.set_value(family.get_gramps_id())
|
||||
else:
|
||||
print(_("ERROR: Please specify a family"))
|
||||
print(_("ERROR: Please specify a family"), file=sys.stderr)
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
#
|
||||
@@ -264,17 +265,21 @@ class CommandLineReport(object):
|
||||
}
|
||||
|
||||
self.options_help = {
|
||||
'of' : ["=filename", "Output file name. MANDATORY", ""],
|
||||
'off' : ["=format", "Output file format.", []],
|
||||
'style' : ["=name", "Style name.", ""],
|
||||
'papers' : ["=name", "Paper size name.", ""],
|
||||
'papero' : ["=num", "Paper orientation number.", ""],
|
||||
'paperml' : ["=num", "Left paper margin", "Size in cm"],
|
||||
'papermr' : ["=num", "Right paper margin", "Size in cm"],
|
||||
'papermt' : ["=num", "Top paper margin", "Size in cm"],
|
||||
'papermb' : ["=num", "Bottom paper margin", "Size in cm"],
|
||||
'css' : ["=css filename", "CSS filename to use, html format"
|
||||
" only", ""],
|
||||
'of' : [_("=filename"), _("Output file name. MANDATORY"),""],
|
||||
'off' : [_("=format"), _("Output file format."), []],
|
||||
'style' : [_("=name"), _("Style name."), ""],
|
||||
'papers' : [_("=name"), _("Paper size name."), ""],
|
||||
'papero' : [_("=number"), _("Paper orientation number."), ""],
|
||||
'paperml' : [_("=number"), _("Left paper margin"),
|
||||
_("Size in cm")],
|
||||
'papermr' : [_("=number"), _("Right paper margin"),
|
||||
_("Size in cm")],
|
||||
'papermt' : [_("=number"), _("Top paper margin"),
|
||||
_("Size in cm")],
|
||||
'papermb' : [_("=number"), _("Bottom paper margin"),
|
||||
_("Size in cm")],
|
||||
'css' : [_("=css filename"), _("CSS filename to use, "
|
||||
"html format only"), ""],
|
||||
}
|
||||
|
||||
if noopt:
|
||||
@@ -416,12 +421,14 @@ class CommandLineReport(object):
|
||||
elif isinstance(option, Option):
|
||||
self.options_help[name].append(option.get_help())
|
||||
else:
|
||||
print(_("Unknown option: %s") % option)
|
||||
print(_("Unknown option: %s") % option, file=sys.stderr)
|
||||
print(_(" Valid options are:"),
|
||||
", ".join(list(self.options_dict.keys())))
|
||||
print((_(" Use '%(donottranslate)s' to see description "
|
||||
"and acceptable values") %
|
||||
{'donottranslate' : "show=option"}))
|
||||
", ".join(list(self.options_dict.keys())),
|
||||
file=sys.stderr)
|
||||
print(_(" Use '%(donottranslate)s' to see description "
|
||||
"and acceptable values")
|
||||
% {'donottranslate' : "show=option"},
|
||||
file=sys.stderr)
|
||||
|
||||
def parse_options(self):
|
||||
"""
|
||||
@@ -471,13 +478,14 @@ class CommandLineReport(object):
|
||||
else:
|
||||
self.format = None
|
||||
if _chosen_format and _format_str:
|
||||
print((_("Ignoring '%(notranslate1)s=%(notranslate2)s' "
|
||||
"and using '%(notranslate1)s=%(notranslate3)s'.") %
|
||||
{'notranslate1' : "off",
|
||||
'notranslate2' : self.options_dict['off'],
|
||||
'notranslate3' : _chosen_format}))
|
||||
print((_("Use '%(notranslate)s' to see valid values.") %
|
||||
{'notranslate' : "show=off"}))
|
||||
print(_("Ignoring '%(notranslate1)s=%(notranslate2)s' "
|
||||
"and using '%(notranslate1)s=%(notranslate3)s'.")
|
||||
% {'notranslate1' : "off",
|
||||
'notranslate2' : self.options_dict['off'],
|
||||
'notranslate3' : _chosen_format},
|
||||
file=sys.stderr)
|
||||
print(_("Use '%(notranslate)s' to see valid values.")
|
||||
% {'notranslate' : "show=off"}, file=sys.stderr)
|
||||
|
||||
self.do_doc_options()
|
||||
|
||||
@@ -489,21 +497,23 @@ class CommandLineReport(object):
|
||||
|
||||
self.option_class.handler.options_dict[opt] = \
|
||||
self.options_dict[opt]
|
||||
|
||||
|
||||
if menu and opt in menu_opt_names:
|
||||
option = menu.get_option_by_name(opt)
|
||||
option.set_value(self.options_dict[opt])
|
||||
|
||||
else:
|
||||
print(_("Ignoring unknown option: %s") % opt )
|
||||
print(_("Ignoring unknown option: %s") % opt, file=sys.stderr)
|
||||
print(_(" Valid options are:"),
|
||||
", ".join(list(self.options_dict.keys())))
|
||||
", ".join(list(self.options_dict.keys())),
|
||||
file=sys.stderr)
|
||||
print(_(" Use '%(donottranslate)s' to see description "
|
||||
"and acceptable values") %
|
||||
{'donottranslate' : "show=option"})
|
||||
{'donottranslate' : "show=option"}, file=sys.stderr)
|
||||
|
||||
self.option_class.handler.output = self.options_dict['of']
|
||||
|
||||
self.paper = paper_sizes[0] # make sure one exists
|
||||
for paper in paper_sizes:
|
||||
if paper.get_name() == self.options_dict['papers']:
|
||||
self.paper = paper
|
||||
@@ -570,14 +580,13 @@ class CommandLineReport(object):
|
||||
# Make the output nicer to read, assume a tab has 8 spaces
|
||||
tabs = '\t\t' if len(key) < 10 else '\t'
|
||||
optmsg = " %s%s%s (%s)" % (key, tabs, opt[1], opt[0])
|
||||
print(optmsg.encode(sys.getfilesystemencoding()))
|
||||
else:
|
||||
optmsg = " %s%s%s" % (key, tabs,
|
||||
_('(no help available)'))
|
||||
print(optmsg.encode(sys.getfilesystemencoding()))
|
||||
print((_(" Use '%(donottranslate)s' to see description "
|
||||
"and acceptable values") %
|
||||
{'donottranslate' : "show=option"}))
|
||||
print(optmsg)
|
||||
print(_(" Use '%(donottranslate)s' to see description "
|
||||
"and acceptable values")
|
||||
% {'donottranslate' : "show=option"})
|
||||
elif self.show in self.options_help:
|
||||
opt = self.options_help[self.show]
|
||||
tabs = '\t\t' if len(self.show) < 10 else '\t'
|
||||
@@ -586,17 +595,17 @@ class CommandLineReport(object):
|
||||
vals = opt[2]
|
||||
if isinstance(vals, (list, tuple)):
|
||||
for val in vals:
|
||||
optmsg = " %s" % val
|
||||
print(optmsg.encode(sys.getfilesystemencoding()))
|
||||
print(" %s" % val)
|
||||
else:
|
||||
optmsg = " %s" % opt[2]
|
||||
print(optmsg.encode(sys.getfilesystemencoding()))
|
||||
print(" %s" % opt[2])
|
||||
|
||||
else:
|
||||
#there was a show option given, but the option is invalid
|
||||
print((_("option '%(optionname)s' not valid. "
|
||||
"Use '%(donottranslate)s' to see all valid options.") %
|
||||
{'optionname' : self.show, 'donottranslate' : "show=all"}))
|
||||
print(_("option '%(optionname)s' not valid. "
|
||||
"Use '%(donottranslate)s' to see all valid options.")
|
||||
% {'optionname' : self.show,
|
||||
'donottranslate' : "show=all"},
|
||||
file=sys.stderr)
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
#
|
||||
@@ -644,10 +653,10 @@ def cl_report(database, name, category, report_class, options_class,
|
||||
return clr
|
||||
except ReportError as msg:
|
||||
(m1, m2) = msg.messages()
|
||||
print(err_msg)
|
||||
print(m1)
|
||||
print(err_msg, file=sys.stderr)
|
||||
print(m1, file=sys.stderr)
|
||||
if m2:
|
||||
print(m2)
|
||||
print(m2, file=sys.stderr)
|
||||
except:
|
||||
if len(log.handlers) > 0:
|
||||
log.error(err_msg, exc_info=True)
|
||||
@@ -726,6 +735,7 @@ def cl_book(database, name, book, options_str_dict):
|
||||
clr.marginr, clr.margint, clr.marginb))
|
||||
user = User()
|
||||
rptlist = []
|
||||
selected_style = StyleSheet()
|
||||
for item in book.get_item_list():
|
||||
|
||||
# The option values were loaded magically by the book parser.
|
||||
@@ -741,14 +751,15 @@ def cl_book(database, name, book, options_str_dict):
|
||||
report_class = item.get_write_item()
|
||||
obj = write_book_item(database,
|
||||
report_class, item.option_class, user)
|
||||
style_sheet = create_style_sheet(item)
|
||||
rptlist.append((obj, style_sheet))
|
||||
if obj:
|
||||
append_styles(selected_style, item)
|
||||
rptlist.append(obj)
|
||||
|
||||
doc.set_style_sheet(selected_style)
|
||||
doc.open(clr.option_class.get_output())
|
||||
doc.init()
|
||||
newpage = 0
|
||||
for rpt, style_sheet in rptlist:
|
||||
doc.set_style_sheet(style_sheet)
|
||||
for rpt in rptlist:
|
||||
if newpage:
|
||||
doc.page_break()
|
||||
newpage = 1
|
||||
@@ -768,10 +779,10 @@ def write_book_item(database, report_class, options, user):
|
||||
return report_class(database, options, user)
|
||||
except ReportError as msg:
|
||||
(m1, m2) = msg.messages()
|
||||
print("ReportError", m1, m2)
|
||||
print("ReportError", m1, m2, file=sys.stderr)
|
||||
except FilterError as msg:
|
||||
(m1, m2) = msg.messages()
|
||||
print("FilterError", m1, m2)
|
||||
print("FilterError", m1, m2, file=sys.stderr)
|
||||
except:
|
||||
log.error("Failed to write book item.", exc_info=True)
|
||||
return None
|
||||
|
@@ -38,7 +38,8 @@ import sys
|
||||
# Gramps Modules
|
||||
#
|
||||
#------------------------------------------------------------------------
|
||||
from gramps.gen.ggettext import gettext as _
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
from gramps.gen.user import User
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
|
@@ -1,21 +0,0 @@
|
||||
# This is the src/data level Makefile for gramps
|
||||
# $Id$
|
||||
#
|
||||
SUBDIRS =
|
||||
|
||||
pkgdatadir = $(datadir)/@PACKAGE@/data
|
||||
|
||||
dist_pkgdata_DATA = \
|
||||
authors.xml \
|
||||
papersize.xml \
|
||||
tips.xml\
|
||||
lds.xml
|
||||
|
||||
# Rules for files with translatable strings
|
||||
# These are taken care of by the intltool
|
||||
xml_in_files = tips.xml.in
|
||||
xml_files = $(xml_in_files:.xml.in=.xml)
|
||||
@INTLTOOL_XML_NOMERGE_RULE@
|
||||
|
||||
EXTRA_DIST = $(xml_in_files)
|
||||
CLEANFILES = $(xml_files)
|
@@ -41,7 +41,8 @@ import logging
|
||||
# Gramps imports
|
||||
#
|
||||
#---------------------------------------------------------------
|
||||
from .ggettext import gettext as _
|
||||
from .const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
from .const import HOME_DIR, USER_HOME, VERSION_DIR
|
||||
from .utils.configmanager import ConfigManager
|
||||
|
||||
@@ -151,6 +152,7 @@ register('behavior.surname-guessing', 0)
|
||||
register('behavior.use-tips', False)
|
||||
register('behavior.welcome', 100)
|
||||
register('behavior.web-search-url', 'http://google.com/#&q=%(text)s')
|
||||
register('behavior.addons-url', "http://svn.code.sf.net/p/gramps-addons/code/branches/gramps40/")
|
||||
|
||||
register('export.proxy-order', [
|
||||
["privacy", 0],
|
||||
@@ -187,7 +189,7 @@ register('interface.clipboard-height', 300)
|
||||
register('interface.clipboard-width', 300)
|
||||
register('interface.dont-ask', False)
|
||||
register('interface.view-categories',
|
||||
["Gramplets", "People", "Relationships", "Families",
|
||||
["Dashboard", "People", "Relationships", "Families",
|
||||
"Ancestry", "Events", "Places", "Geography", "Sources",
|
||||
"Citations", "Repositories", "Media", "Notes"])
|
||||
register('interface.edit-filter-width', 500)
|
||||
@@ -208,6 +210,7 @@ register('interface.filter', False)
|
||||
register('interface.filter-editor-width', 400)
|
||||
register('interface.filter-editor-height', 350)
|
||||
register('interface.fullscreen', False)
|
||||
register('interface.grampletbar-close', False)
|
||||
register('interface.height', 500)
|
||||
register('interface.lds-height', 450)
|
||||
register('interface.lds-width', 600)
|
||||
@@ -278,6 +281,8 @@ register('preferences.date-format', 0)
|
||||
register('preferences.calendar-format-report', 0)
|
||||
register('preferences.cprefix', 'C%04d')
|
||||
register('preferences.default-source', False)
|
||||
register('preferences.tag-on-import', False)
|
||||
register('preferences.tag-on-import-format', _("Imported %Y/%m/%d %H:%M:%S"))
|
||||
register('preferences.eprefix', 'E%04d')
|
||||
register('preferences.family-warn', True)
|
||||
register('preferences.fprefix', 'F%04d')
|
||||
|
@@ -4,6 +4,7 @@
|
||||
#
|
||||
# Copyright (C) 2000-2006 Donald N. Allingham
|
||||
# Copyright (C) 2012 Doug Blank
|
||||
# Copyright (C) 2013 John Ralls <jralls@ceridwen.us>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -42,7 +43,7 @@ import uuid
|
||||
# Gramps modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from .ggettext import sgettext as _
|
||||
from .svn_revision import get_svn_revision
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
@@ -50,12 +51,7 @@ from .ggettext import sgettext as _
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
PROGRAM_NAME = "Gramps"
|
||||
if "@VERSIONSTRING@" == "@" + "VERSIONSTRING" + "@":
|
||||
VERSION = "4.0.0"
|
||||
else:
|
||||
VERSION = "@VERSIONSTRING@"
|
||||
VERSION_TUPLE = (4, 0, 0)
|
||||
|
||||
from ..version import VERSION, VERSION_TUPLE, major_version
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Standard GRAMPS Websites
|
||||
@@ -65,11 +61,11 @@ URL_HOMEPAGE = "http://gramps-project.org/"
|
||||
URL_MAILINGLIST = "http://sourceforge.net/mail/?group_id=25770"
|
||||
URL_BUGTRACKER = "http://bugs.gramps-project.org/bug_report_advanced_page.php"
|
||||
URL_WIKISTRING = "http://gramps-project.org/wiki/index.php?title="
|
||||
URL_MANUAL_PAGE = "Gramps_4.0_Wiki_Manual"
|
||||
URL_MANUAL_PAGE = "Gramps_%s_Wiki_Manual" % major_version
|
||||
WIKI_FAQ = "FAQ"
|
||||
WIKI_KEYBINDINGS = "Gramps_4.0_Wiki_Manual_-_Keybindings"
|
||||
WIKI_EXTRAPLUGINS= "4.0_Addons"
|
||||
WIKI_EXTRAPLUGINS_RAWDATA = "Plugins4.0&action=raw"
|
||||
WIKI_KEYBINDINGS = "Gramps_%s_Wiki_Manual_-_Keybindings" % major_version
|
||||
WIKI_EXTRAPLUGINS= "%s_Addons" % major_version
|
||||
WIKI_EXTRAPLUGINS_RAWDATA = "Plugins%s&action=raw" % major_version
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
@@ -84,36 +80,6 @@ APP_GRAMPS_PKG = "application/x-gramps-package"
|
||||
APP_GENEWEB = "application/x-geneweb"
|
||||
APP_VCARD = ["text/x-vcard", "text/x-vcalendar"]
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# system paths
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
if sys.platform == "win32":
|
||||
if sys.prefix == os.path.dirname(os.getcwd()):
|
||||
PREFIXDIR = sys.prefix
|
||||
SYSCONFDIR = os.path.join(sys.prefix, "etc")
|
||||
else:
|
||||
PREFIXDIR = os.path.join(os.path.dirname(__file__), os.pardir)
|
||||
SYSCONFDIR = os.path.join(PREFIXDIR, "etc")
|
||||
elif sys.platform == "darwin" and sys.prefix != sys.exec_prefix:
|
||||
PREFIXDIR = sys.prefix
|
||||
SYSCONFDIR = os.path.join(sys.prefix, "etc")
|
||||
else:
|
||||
PREFIXDIR = "@prefix@"
|
||||
SYSCONFDIR = "@sysconfdir@"
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Platforms
|
||||
# Never test on LINUX, handle Linux in the else statement as default
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
LINUX = ["Linux", "linux", "linux2"]
|
||||
MACOS = ["Darwin", "darwin"]
|
||||
WINDOWS = ["Windows", "win32"]
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Determine the home directory. According to Wikipedia, most UNIX like
|
||||
@@ -145,24 +111,6 @@ if sys.version_info[0] < 3:
|
||||
else:
|
||||
pass
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Paths to files - assumes that files reside in the same directory as
|
||||
# this one, and that the plugins directory is in a directory below this.
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
ROOT_DIR = os.path.abspath(os.path.join(os.path.dirname(
|
||||
__file__), os.pardir))
|
||||
if sys.version_info[0] < 3:
|
||||
# test for sys.frozen to detect a py2exe executable on Windows
|
||||
if hasattr(sys, "frozen"):
|
||||
ROOT_DIR = os.path.abspath(os.path.dirname(
|
||||
unicode(sys.executable, sys.getfilesystemencoding())))
|
||||
else:
|
||||
ROOT_DIR = os.path.abspath(os.path.join(os.path.dirname(
|
||||
unicode(__file__, sys.getfilesystemencoding())), os.pardir))
|
||||
|
||||
IMAGE_DIR = os.path.join(ROOT_DIR, "images")
|
||||
VERSION_DIR = os.path.join(
|
||||
HOME_DIR, "gramps%s%s" % (VERSION_TUPLE[0], VERSION_TUPLE[1]))
|
||||
|
||||
@@ -180,15 +128,28 @@ USER_PLUGINS = os.path.join(VERSION_DIR, "plugins")
|
||||
USER_DIRLIST = (HOME_DIR, VERSION_DIR, ENV_DIR, TEMP_DIR, THUMB_DIR,
|
||||
THUMB_NORMAL, THUMB_LARGE, USER_PLUGINS)
|
||||
|
||||
ICON = os.path.join(ROOT_DIR, "images", "gramps.png")
|
||||
LOGO = os.path.join(ROOT_DIR, "images", "logo.png")
|
||||
SPLASH = os.path.join(ROOT_DIR, "images", "splash.jpg")
|
||||
LICENSE_FILE = os.path.join(ROOT_DIR, "COPYING")
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Paths to python modules - assumes that the root directory is one level
|
||||
# above this one, and that the plugins directory is below the root directory.
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
ROOT_DIR = os.path.abspath(os.path.join(os.path.dirname(
|
||||
__file__), os.pardir))
|
||||
if sys.version_info[0] < 3:
|
||||
# test for sys.frozen to detect a py2exe executable on Windows
|
||||
if hasattr(sys, "frozen"):
|
||||
ROOT_DIR = os.path.abspath(os.path.dirname(
|
||||
unicode(sys.executable, sys.getfilesystemencoding())))
|
||||
else:
|
||||
ROOT_DIR = os.path.abspath(os.path.join(os.path.dirname(
|
||||
unicode(__file__, sys.getfilesystemencoding())), os.pardir))
|
||||
|
||||
VERSION += get_svn_revision(ROOT_DIR)
|
||||
|
||||
#
|
||||
# Glade files
|
||||
#
|
||||
|
||||
GLADE_DIR = os.path.join(ROOT_DIR, "gui", "glade")
|
||||
GLADE_FILE = os.path.join(GLADE_DIR, "gramps.glade")
|
||||
PERSON_GLADE = os.path.join(GLADE_DIR, "edit_person.glade")
|
||||
@@ -198,29 +159,51 @@ RULE_GLADE = os.path.join(GLADE_DIR, "rule.glade")
|
||||
|
||||
|
||||
PLUGINS_DIR = os.path.join(ROOT_DIR, "plugins")
|
||||
DATA_DIR = os.path.join(ROOT_DIR, "data")
|
||||
WEB_DIR = os.path.join(ROOT_DIR, 'webapp')
|
||||
#SYSTEM_FILTERS = os.path.join(DATA_DIR, "system_filters.xml")
|
||||
TIP_DATA = os.path.join(DATA_DIR, "tips.xml")
|
||||
WEBSTUFF_DIR = os.path.join(PLUGINS_DIR, "webstuff")
|
||||
WEBSTUFF_IMAGE_DIR = os.path.join(WEBSTUFF_DIR, "images")
|
||||
|
||||
PAPERSIZE = os.path.join(DATA_DIR, "papersize.xml")
|
||||
USE_TIPS = False
|
||||
|
||||
USE_TIPS = False
|
||||
|
||||
if os.sys.platform in WINDOWS:
|
||||
if sys.platform == 'win32':
|
||||
USE_THUMBNAILER = False
|
||||
else:
|
||||
USE_THUMBNAILER = True
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Paths to data files.
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from gramps.gen.utils.resourcepath import ResourcePath
|
||||
_resources = ResourcePath()
|
||||
DATA_DIR = _resources.data_dir
|
||||
IMAGE_DIR = _resources.image_dir
|
||||
|
||||
TIP_DATA = os.path.join(DATA_DIR, "tips.xml")
|
||||
PAPERSIZE = os.path.join(DATA_DIR, "papersize.xml")
|
||||
|
||||
ICON = os.path.join(IMAGE_DIR, "gramps.png")
|
||||
LOGO = os.path.join(IMAGE_DIR, "logo.png")
|
||||
SPLASH = os.path.join(IMAGE_DIR, "splash.jpg")
|
||||
|
||||
LICENSE_FILE = os.path.join(_resources.doc_dir, 'COPYING')
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Init Localization
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from gramps.gen.utils.grampslocale import GrampsLocale
|
||||
GRAMPS_LOCALE = GrampsLocale(localedir=_resources.locale_dir)
|
||||
_ = GRAMPS_LOCALE.translation.sgettext
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# About box information
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
COPYRIGHT_MSG = "© 2001-2006 Donald N. Allingham\n" \
|
||||
"© 2007-2012 The Gramps Developers"
|
||||
"© 2007-2013 The Gramps Developers"
|
||||
COMMENTS = _("Gramps (Genealogical Research and Analysis "
|
||||
"Management Programming System) is a personal "
|
||||
"genealogy program.")
|
||||
@@ -231,9 +214,10 @@ AUTHORS = [
|
||||
"Donald A. Peterson",
|
||||
"Donald N. Allingham",
|
||||
"David Hampton",
|
||||
"Martin Hawlisch",
|
||||
"Martin Hawlisch",
|
||||
"Richard Taylor",
|
||||
"Tim Waugh",
|
||||
"Tim Waugh",
|
||||
"John Ralls"
|
||||
]
|
||||
|
||||
AUTHORS_FILE = os.path.join(DATA_DIR, "authors.xml")
|
||||
@@ -322,6 +306,6 @@ LONGOPTS = [
|
||||
"qml",
|
||||
]
|
||||
|
||||
SHORTOPTS = "O:C:i:e:f:a:p:d:c:lLhuv?s"
|
||||
SHORTOPTS = "O:C:i:e:f:a:p:d:c:lLthuv?s"
|
||||
|
||||
GRAMPS_UUID = uuid.UUID('516cd010-5a41-470f-99f8-eb22f1098ad6')
|
@@ -37,10 +37,13 @@ import sys
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Gramps modules
|
||||
# Platforms
|
||||
# Never test on LINUX, handle Linux in the else statement as default
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from .const import WINDOWS, MACOS, LINUX
|
||||
LINUX = ["Linux", "linux", "linux2"]
|
||||
MACOS = ["Darwin", "darwin"]
|
||||
WINDOWS = ["Windows", "win32"]
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
@@ -64,6 +67,13 @@ else:
|
||||
STRTYPE = str
|
||||
UNITYPE = str
|
||||
cuni = conv_to_unicode_direct
|
||||
|
||||
# handle in database is bytes, while internally Gramps wants unicode for py3
|
||||
if sys.version_info[0] < 3:
|
||||
handle2internal = lambda x: x
|
||||
else:
|
||||
handle2internal = lambda x: conv_to_unicode(x, 'utf-8')
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Platform determination functions
|
||||
|
@@ -24,8 +24,15 @@
|
||||
Class handling language-specific selection for date parser and displayer.
|
||||
"""
|
||||
|
||||
from __future__ import print_function
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# set up logging
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
import logging
|
||||
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.sgettext
|
||||
# import prerequisites for localized handlers
|
||||
from ._datehandler import (LANG, LANG_SHORT, LANG_TO_PARSER, LANG_TO_DISPLAY,
|
||||
register_datehandler)
|
||||
@@ -59,7 +66,7 @@ try:
|
||||
else:
|
||||
parser = LANG_TO_PARSER[LANG_SHORT]()
|
||||
except:
|
||||
print("Date parser for", LANG, "not available, using default")
|
||||
logging.warning(_("Date parser for '%s' not available, using default") % LANG)
|
||||
parser = LANG_TO_PARSER["C"]()
|
||||
|
||||
# Initialize global displayer
|
||||
@@ -75,7 +82,7 @@ try:
|
||||
else:
|
||||
displayer = LANG_TO_DISPLAY[LANG_SHORT](val)
|
||||
except:
|
||||
print("Date displayer for", LANG, "not available, using default")
|
||||
logging.warning(_("Date displayer for '%s' not available, using default") % LANG)
|
||||
displayer = LANG_TO_DISPLAY["C"](val)
|
||||
|
||||
|
||||
|
@@ -176,4 +176,4 @@ class DateDisplayNb(DateDisplay):
|
||||
# Register classes
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
register_datehandler(('nb_NO', 'nb', 'norsk', 'Norwegian'), DateParserNb, DateDisplayNb)
|
||||
register_datehandler(('nb_NO', 'nb', 'nn_NO', 'nn', 'norsk', 'Norwegian'), DateParserNb, DateDisplayNb)
|
||||
|
364
gramps/gen/datehandler/_date_uk.py
Normal file
364
gramps/gen/datehandler/_date_uk.py
Normal file
@@ -0,0 +1,364 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# Gramps - a GTK+/GNOME based genealogy program
|
||||
#
|
||||
# Copyright (C) 2004-2006 Donald N. Allingham
|
||||
# Copyright (C) 2013 Fedir Zinchuk <fedikw[at]gmail.com>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
#
|
||||
|
||||
# $Id: _Date_uk.py 18361 2011-10-23 03:13:50Z paul-franklin $
|
||||
|
||||
"""
|
||||
Ukrainian-specific classes for parsing and displaying dates.
|
||||
"""
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Python modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from __future__ import unicode_literals
|
||||
import re
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# GRAMPS modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
from ..lib.date import Date
|
||||
from ._dateparser import DateParser
|
||||
from ._datedisplay import DateDisplay
|
||||
from ._datehandler import register_datehandler
|
||||
from . import _grampslocale
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Ukrainian parser
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
class DateParserUK(DateParser):
|
||||
"""
|
||||
Convert a text string into a Date object. If the date cannot be
|
||||
converted, the text string is assigned.
|
||||
"""
|
||||
|
||||
month_to_int = DateParser.month_to_int
|
||||
|
||||
# the genitive
|
||||
month_to_int["січня"] = 1
|
||||
month_to_int["лютого"] = 2
|
||||
month_to_int["березня"] = 3
|
||||
month_to_int["квітня"] = 4
|
||||
month_to_int["травня"] = 5
|
||||
month_to_int["червня"] = 6
|
||||
month_to_int["липня"] = 7
|
||||
month_to_int["серпня"] = 8
|
||||
month_to_int["вересня"] = 9
|
||||
month_to_int["жовтня"] = 10
|
||||
month_to_int["листопада"] = 11
|
||||
month_to_int["грудня"] = 12
|
||||
|
||||
# some short variants of the months
|
||||
month_to_int["січ."] = 1
|
||||
month_to_int["січ"] = 1
|
||||
month_to_int["лют."] = 2
|
||||
month_to_int["лют"] = 2
|
||||
month_to_int["бер."] = 3
|
||||
month_to_int["бер"] = 3
|
||||
month_to_int["квіт."] = 4
|
||||
month_to_int["квіт"] = 4
|
||||
month_to_int["трав."] = 5
|
||||
month_to_int["трав"] = 5
|
||||
month_to_int["черв."] = 6
|
||||
month_to_int["черв"] = 6
|
||||
month_to_int["лип."] = 7
|
||||
month_to_int["лип"] = 7
|
||||
month_to_int["серп."] = 8
|
||||
month_to_int["серп"] = 8
|
||||
month_to_int["вер."] = 9
|
||||
month_to_int["вер"] = 9
|
||||
month_to_int["жовт."] = 10
|
||||
month_to_int["жовт"] = 10
|
||||
month_to_int["лист."] = 11
|
||||
month_to_int["лист"] = 11
|
||||
month_to_int["груд."] = 12
|
||||
month_to_int["груд"] = 12
|
||||
|
||||
|
||||
# modifiers before the date
|
||||
modifier_to_int = {
|
||||
'перед' : Date.MOD_BEFORE,
|
||||
'до' : Date.MOD_BEFORE,
|
||||
'раніше' : Date.MOD_BEFORE,
|
||||
|
||||
'після' : Date.MOD_AFTER,
|
||||
'п.' : Date.MOD_AFTER,
|
||||
'за' : Date.MOD_AFTER,
|
||||
|
||||
'приблизно': Date.MOD_ABOUT,
|
||||
'прибл.' : Date.MOD_ABOUT,
|
||||
'приб.' : Date.MOD_ABOUT,
|
||||
'близько' : Date.MOD_ABOUT,
|
||||
'бл.' : Date.MOD_ABOUT,
|
||||
'біля' : Date.MOD_ABOUT,
|
||||
}
|
||||
|
||||
hebrew_to_int = {
|
||||
"тішрі" : 1, "хешвен" : 2, "кіслев" : 3,
|
||||
"тевет" : 4, "шват" : 5, "адар" : 6,
|
||||
"адара" : 7, "нісан" : 8, "іяр" : 9,
|
||||
"сиван" : 10, "таммуз" : 11, "ав" : 12,
|
||||
"елул" : 13,
|
||||
#alternative spelling
|
||||
"мархешван": 2, "ве адар" : 7,
|
||||
#GEDCOM months
|
||||
"tsh" : 1, "csh": 5, "ksl": 3, "tvt": 4, "shv": 5, "adr": 6,
|
||||
"ads" : 7, "nsn": 8, "iyr": 9, "svn":10, "tmz":11, "aav":12,
|
||||
"ell":13,
|
||||
}
|
||||
|
||||
french_to_int = {
|
||||
'вандем’єр' : 1, 'брюмер' : 2,
|
||||
'фрімер' : 3, 'нівоз' : 4,
|
||||
'плювіоз' : 5, 'вентоз' : 6,
|
||||
'жерміналь' : 7, 'флореаль' : 8,
|
||||
'преріаль' : 9, 'мессідор' : 10,
|
||||
'термідор' : 11, 'фрюктідор': 12,
|
||||
'додатковий' : 13,
|
||||
#short
|
||||
'ванд' : 1, 'брюм' : 2,
|
||||
'фрім' : 3, 'нів' : 4,
|
||||
'плюв' : 5, 'вент' : 6,
|
||||
'жерм' : 7, 'флор' : 8,
|
||||
'прер' : 9, 'месс' : 10,
|
||||
'терм' : 11, 'фрюкт': 12,
|
||||
'дод' : 13,
|
||||
#GEDCOM months
|
||||
'vend' : 1, 'brum' : 2,
|
||||
'frim' : 3, 'nivo' : 4,
|
||||
'pluv' : 5, 'vent' : 6,
|
||||
'germ' : 7, 'flor' : 8,
|
||||
'prai' : 9, 'mess' : 10,
|
||||
'ther' : 11, 'fruc' : 12,
|
||||
'comp' : 13,
|
||||
}
|
||||
|
||||
islamic_to_int = {
|
||||
"мухаррам" : 1, "мухаррем" : 1,
|
||||
"сафар" : 2, "рабі-аль-авваль" : 3,
|
||||
"рабі-ассані" : 4,
|
||||
"джумада-аль-уля" : 5, "джумада-аль-авваль" : 5,
|
||||
"джумада-аль-ахіра" : 6, "джумада-ас-сані" : 6,
|
||||
"раджаб" : 7, "шаабан" : 8,
|
||||
"рамадан" : 9, "рамазан" : 9,
|
||||
"шавваль" : 10, "зуль-каада" : 11,
|
||||
"зуль-хіджжа" : 12,
|
||||
}
|
||||
|
||||
persian_to_int = {
|
||||
"фарвардін" : 1, "ордібехешт" : 2,
|
||||
"хордад" : 3, "тир" : 4,
|
||||
"мордад" : 5, "шахрівар" : 6,
|
||||
"мехр" : 7, "абан" : 8,
|
||||
"азар" : 9, "дей" : 10,
|
||||
"бахман" : 11, "есфанд" : 12,
|
||||
}
|
||||
|
||||
bce = ['до нашої ери', 'до н. е.', 'до н.е.']
|
||||
|
||||
calendar_to_int = {
|
||||
'григоріанський' : Date.CAL_GREGORIAN,
|
||||
'г' : Date.CAL_GREGORIAN,
|
||||
'юліанський' : Date.CAL_JULIAN,
|
||||
'ю' : Date.CAL_JULIAN,
|
||||
'єврейський' : Date.CAL_HEBREW,
|
||||
'є' : Date.CAL_HEBREW,
|
||||
'ісламський' : Date.CAL_ISLAMIC,
|
||||
'і' : Date.CAL_ISLAMIC,
|
||||
'французький' : Date.CAL_FRENCH,
|
||||
'французький республіканський': Date.CAL_FRENCH,
|
||||
'французький революційний' : Date.CAL_FRENCH,
|
||||
'ф' : Date.CAL_FRENCH,
|
||||
'іранський' : Date.CAL_PERSIAN,
|
||||
'перський' : Date.CAL_PERSIAN,
|
||||
'п' : Date.CAL_PERSIAN,
|
||||
'шведський' : Date.CAL_SWEDISH,
|
||||
'ш' : Date.CAL_SWEDISH,
|
||||
}
|
||||
|
||||
quality_to_int = {
|
||||
'за оцінкою' : Date.QUAL_ESTIMATED,
|
||||
'за оц.' : Date.QUAL_ESTIMATED,
|
||||
'оцінено' : Date.QUAL_ESTIMATED,
|
||||
'орієнтовно' : Date.QUAL_ESTIMATED,
|
||||
'приблизно' : Date.QUAL_ESTIMATED,
|
||||
'прибл.' : Date.QUAL_ESTIMATED,
|
||||
'підраховано' : Date.QUAL_CALCULATED,
|
||||
'підрах.' : Date.QUAL_CALCULATED,
|
||||
'розраховано' : Date.QUAL_CALCULATED,
|
||||
'розрахунково' : Date.QUAL_CALCULATED,
|
||||
'розрах.' : Date.QUAL_CALCULATED,
|
||||
}
|
||||
|
||||
def init_strings(self):
|
||||
"""
|
||||
This method compiles regular expression strings for matching dates.
|
||||
|
||||
See DateParser.init_strings()
|
||||
"""
|
||||
DateParser.init_strings(self)
|
||||
|
||||
_span_1 = ['з', 'від']
|
||||
# b.c.e. pattern also have "до" so skip "до н."
|
||||
_span_2 = ['по', 'до?!\sн\.']
|
||||
self._span = re.compile("(%s)\s+(?P<start>.+)\s+(%s)\s+(?P<stop>.+)" %
|
||||
('|'.join(_span_1), '|'.join(_span_2)),
|
||||
re.IGNORECASE)
|
||||
_range_1 = ['між']
|
||||
_range_2 = ['і', 'та']
|
||||
self._range = re.compile("(%s)\s+(?P<start>.+)\s+(%s)\s+(?P<stop>.+)" %
|
||||
('|'.join(_range_1), '|'.join(_range_2)),
|
||||
re.IGNORECASE)
|
||||
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Ukrainian displayer
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
class DateDisplayUK(DateDisplay):
|
||||
"""
|
||||
Ukrainian language date display class.
|
||||
"""
|
||||
|
||||
# the months as the noun or as the genitive???
|
||||
|
||||
# as the genitive:
|
||||
long_months = (
|
||||
"", "січня", "лютого", "березня", "квітня",
|
||||
"травня", "червня", "липня", "серпня",
|
||||
"вересня", "жовтня", "листопада", "грудня"
|
||||
)
|
||||
|
||||
# as the noun:
|
||||
# long_months = (
|
||||
# "", "січень", "лютий", "березень", "квітень",
|
||||
# "травень", "червень", "липень", "серпень",
|
||||
# "вересень", "жовтень", "листопад", "грудень"
|
||||
# )
|
||||
|
||||
short_months = (
|
||||
"", "січ.", "лют.", "бер.", "квіт.", "трав.", "черв.",
|
||||
"лип.", "серп.", "вер.", "жовт.", "лист.", "груд."
|
||||
)
|
||||
|
||||
hebrew = (
|
||||
"", "тішрі", "хешвен", "кіслев", "тевет", "шват",
|
||||
"адар", "адара", "нісан", "іяр", "сиван", "таммуз",
|
||||
"ав", "елул"
|
||||
)
|
||||
|
||||
french = (
|
||||
'', 'вандем’єр', 'брюмер', 'фрімер', 'нівоз',
|
||||
'плювіоз', 'вентоз', 'жерміналь', 'флореаль',
|
||||
'преріаль', 'мессідор', 'термідор', 'фрюктідор',
|
||||
'додатковий'
|
||||
)
|
||||
|
||||
persian = (
|
||||
"", "фарвардін", "ордібехешт", "хордад", "тир",
|
||||
"мордад", "шахрівар", "мехр", "абан",
|
||||
"азар", "дей", "бахман", "есфанд"
|
||||
)
|
||||
|
||||
islamic = (
|
||||
"", "мухаррам", "сафар", "рабі-аль-авваль",
|
||||
"рабі-ассані", "джумада-аль-уля", "джумада-аль-ахіра",
|
||||
"раджаб", "шаабан", "рамадан", "шавваль", "зуль-каада",
|
||||
"зуль-хіджжа",
|
||||
)
|
||||
|
||||
# Replace the previous "Numerical" by a string which
|
||||
# do have an explicit meaning: "System default (format)"
|
||||
_locale_tformat = _grampslocale.tformat
|
||||
_locale_tformat = _locale_tformat.replace('%d', "д")
|
||||
_locale_tformat = _locale_tformat.replace('%m', "м")
|
||||
_locale_tformat = _locale_tformat.replace('%Y', "р")
|
||||
|
||||
formats = (
|
||||
"рррр-мм-дд (ISO)", #0
|
||||
"стандартний для системи (" + _locale_tformat + ")", #1
|
||||
"місяць день, рік", #2
|
||||
"міс. дд, рррр", #3
|
||||
"день місяць рік", #4
|
||||
"дд міс. рррр" #5
|
||||
)
|
||||
|
||||
calendar = (
|
||||
"", "юліанський", "єврейський", "французький республіканський",
|
||||
"іранський", "ісламський", "шведський"
|
||||
)
|
||||
|
||||
_mod_str = ("", "до ", "після ", "близько ", "", "", "")
|
||||
|
||||
_qual_str = ("", "орієнтовно ", "розрахунково ")
|
||||
|
||||
_bce_str = "%s до н.е."
|
||||
|
||||
def display(self, date):
|
||||
"""
|
||||
Return a text string representing the date.
|
||||
"""
|
||||
mod = date.get_modifier()
|
||||
cal = date.get_calendar()
|
||||
qual = date.get_quality()
|
||||
start = date.get_start_date()
|
||||
newyear = date.get_new_year()
|
||||
|
||||
qual_str = self._qual_str[qual]
|
||||
|
||||
if mod == Date.MOD_TEXTONLY:
|
||||
return date.get_text()
|
||||
elif start == Date.EMPTY:
|
||||
return ""
|
||||
elif mod == Date.MOD_SPAN:
|
||||
d1 = self.display_cal[cal](start)
|
||||
d2 = self.display_cal[cal](date.get_stop_date())
|
||||
scal = self.format_extras(cal, newyear)
|
||||
return "%sз %s %s %s%s" % (qual_str, d1, 'по', d2,
|
||||
scal)
|
||||
elif mod == Date.MOD_RANGE:
|
||||
d1 = self.display_cal[cal](start)
|
||||
d2 = self.display_cal[cal](date.get_stop_date())
|
||||
scal = self.format_extras(cal, newyear)
|
||||
return "%s%s %s %s %s%s" % (qual_str, 'між', d1, 'та',
|
||||
d2, scal)
|
||||
else:
|
||||
text = self.display_cal[date.get_calendar()](start)
|
||||
scal = self.format_extras(cal, newyear)
|
||||
return "%s%s%s%s" % (qual_str, self._mod_str[mod],
|
||||
text, scal)
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Register classes
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
register_datehandler(('uk_UA', 'uk', 'ukrainian', 'Ukrainian'),
|
||||
DateParserUK, DateDisplayUK)
|
@@ -30,7 +30,6 @@ from __future__ import unicode_literals
|
||||
# Python modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
import locale
|
||||
import os
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
@@ -49,16 +48,13 @@ log = logging.getLogger(".gen.datehandler")
|
||||
from ._dateparser import DateParser
|
||||
from ._datedisplay import DateDisplay, DateDisplayEn
|
||||
from ..constfunc import win, cuni
|
||||
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Constants
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
if not win():
|
||||
LANG = locale.getlocale(locale.LC_TIME)[0]
|
||||
else:
|
||||
LANG = locale.getdefaultlocale(locale.LC_TIME)[0]
|
||||
LANG = glocale.calendar
|
||||
|
||||
# If LANG contains ".UTF-8" use only the part to the left of "."
|
||||
# Otherwise some date handler will not load.
|
||||
@@ -86,6 +82,7 @@ LANG_TO_PARSER = {
|
||||
LANG_TO_DISPLAY = {
|
||||
'C' : DateDisplayEn,
|
||||
'en' : DateDisplayEn,
|
||||
'en_GB' : DateDisplayEn,
|
||||
'English_United States' : DateDisplayEn,
|
||||
'zh_CN' : DateDisplay,
|
||||
'zh_TW' : DateDisplay,
|
||||
|
@@ -25,6 +25,8 @@ import locale
|
||||
import sys
|
||||
from ..constfunc import mac, win, conv_to_unicode
|
||||
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
|
||||
"""
|
||||
Some OS environments do not support the locale.nl_langinfo() method
|
||||
of determing month names and other date related information.
|
||||
@@ -40,8 +42,9 @@ if sys.version_info[0] < 3:
|
||||
else:
|
||||
#locale returns unicode in python 3
|
||||
to_uni = lambda x, y: x
|
||||
codeset = glocale.encoding
|
||||
|
||||
try:
|
||||
codeset = locale.nl_langinfo(locale.CODESET)
|
||||
|
||||
month_to_int = {
|
||||
to_uni(locale.nl_langinfo(locale.MON_1), codeset).lower() : 1,
|
||||
@@ -137,69 +140,64 @@ try:
|
||||
|
||||
except:
|
||||
import time
|
||||
codeset = None
|
||||
if win() or mac():
|
||||
codeset = locale.getlocale()[1]
|
||||
if codeset is None:
|
||||
codeset = locale.getpreferredencoding()
|
||||
|
||||
month_to_int = {
|
||||
to_uni(time.strftime('%B',(0,1,1,1,1,1,1,1,1)), codeset).lower() : 1,
|
||||
to_uni(time.strftime('%b',(0,1,1,1,1,1,1,1,1)), codeset).lower() : 1,
|
||||
to_uni(time.strftime('%B',(0,2,1,1,1,1,1,1,1)), codeset).lower() : 2,
|
||||
to_uni(time.strftime('%b',(0,2,1,1,1,1,1,1,1)), codeset).lower() : 2,
|
||||
to_uni(time.strftime('%B',(0,3,1,1,1,1,1,1,1)), codeset).lower() : 3,
|
||||
to_uni(time.strftime('%b',(0,3,1,1,1,1,1,1,1)), codeset).lower() : 3,
|
||||
to_uni(time.strftime('%B',(0,4,1,1,1,1,1,1,1)), codeset).lower() : 4,
|
||||
to_uni(time.strftime('%b',(0,4,1,1,1,1,1,1,1)), codeset).lower() : 4,
|
||||
to_uni(time.strftime('%B',(0,5,1,1,1,1,1,1,1)), codeset).lower() : 5,
|
||||
to_uni(time.strftime('%b',(0,5,1,1,1,1,1,1,1)), codeset).lower() : 5,
|
||||
to_uni(time.strftime('%B',(0,6,1,1,1,1,1,1,1)), codeset).lower() : 6,
|
||||
to_uni(time.strftime('%b',(0,6,1,1,1,1,1,1,1)), codeset).lower() : 6,
|
||||
to_uni(time.strftime('%B',(0,7,1,1,1,1,1,1,1)), codeset).lower() : 7,
|
||||
to_uni(time.strftime('%b',(0,7,1,1,1,1,1,1,1)), codeset).lower() : 7,
|
||||
to_uni(time.strftime('%B',(0,8,1,1,1,1,1,1,1)), codeset).lower() : 8,
|
||||
to_uni(time.strftime('%b',(0,8,1,1,1,1,1,1,1)), codeset).lower() : 8,
|
||||
to_uni(time.strftime('%B',(0,9,1,1,1,1,1,1,1)), codeset).lower() : 9,
|
||||
to_uni(time.strftime('%b',(0,9,1,1,1,1,1,1,1)), codeset).lower() : 9,
|
||||
to_uni(time.strftime('%B',(0,10,1,1,1,1,1,1,1)), codeset).lower() : 10,
|
||||
to_uni(time.strftime('%b',(0,10,1,1,1,1,1,1,1)), codeset).lower() : 10,
|
||||
to_uni(time.strftime('%B',(0,11,1,1,1,1,1,1,1)), codeset).lower() : 11,
|
||||
to_uni(time.strftime('%b',(0,11,1,1,1,1,1,1,1)), codeset).lower() : 11,
|
||||
to_uni(time.strftime('%B',(0,12,1,1,1,1,1,1,1)), codeset).lower() : 12,
|
||||
to_uni(time.strftime('%b',(0,12,1,1,1,1,1,1,1)), codeset).lower() : 12,
|
||||
to_uni(time.strftime('%B',(1,1,1,1,1,1,1,1,1)), codeset).lower() : 1,
|
||||
to_uni(time.strftime('%b',(1,1,1,1,1,1,1,1,1)), codeset).lower() : 1,
|
||||
to_uni(time.strftime('%B',(1,2,1,1,1,1,1,1,1)), codeset).lower() : 2,
|
||||
to_uni(time.strftime('%b',(1,2,1,1,1,1,1,1,1)), codeset).lower() : 2,
|
||||
to_uni(time.strftime('%B',(1,3,1,1,1,1,1,1,1)), codeset).lower() : 3,
|
||||
to_uni(time.strftime('%b',(1,3,1,1,1,1,1,1,1)), codeset).lower() : 3,
|
||||
to_uni(time.strftime('%B',(1,4,1,1,1,1,1,1,1)), codeset).lower() : 4,
|
||||
to_uni(time.strftime('%b',(1,4,1,1,1,1,1,1,1)), codeset).lower() : 4,
|
||||
to_uni(time.strftime('%B',(1,5,1,1,1,1,1,1,1)), codeset).lower() : 5,
|
||||
to_uni(time.strftime('%b',(1,5,1,1,1,1,1,1,1)), codeset).lower() : 5,
|
||||
to_uni(time.strftime('%B',(1,6,1,1,1,1,1,1,1)), codeset).lower() : 6,
|
||||
to_uni(time.strftime('%b',(1,6,1,1,1,1,1,1,1)), codeset).lower() : 6,
|
||||
to_uni(time.strftime('%B',(1,7,1,1,1,1,1,1,1)), codeset).lower() : 7,
|
||||
to_uni(time.strftime('%b',(1,7,1,1,1,1,1,1,1)), codeset).lower() : 7,
|
||||
to_uni(time.strftime('%B',(1,8,1,1,1,1,1,1,1)), codeset).lower() : 8,
|
||||
to_uni(time.strftime('%b',(1,8,1,1,1,1,1,1,1)), codeset).lower() : 8,
|
||||
to_uni(time.strftime('%B',(1,9,1,1,1,1,1,1,1)), codeset).lower() : 9,
|
||||
to_uni(time.strftime('%b',(1,9,1,1,1,1,1,1,1)), codeset).lower() : 9,
|
||||
to_uni(time.strftime('%B',(1,10,1,1,1,1,1,1,1)), codeset).lower() : 10,
|
||||
to_uni(time.strftime('%b',(1,10,1,1,1,1,1,1,1)), codeset).lower() : 10,
|
||||
to_uni(time.strftime('%B',(1,11,1,1,1,1,1,1,1)), codeset).lower() : 11,
|
||||
to_uni(time.strftime('%b',(1,11,1,1,1,1,1,1,1)), codeset).lower() : 11,
|
||||
to_uni(time.strftime('%B',(1,12,1,1,1,1,1,1,1)), codeset).lower() : 12,
|
||||
to_uni(time.strftime('%b',(1,12,1,1,1,1,1,1,1)), codeset).lower() : 12,
|
||||
}
|
||||
|
||||
long_months = (
|
||||
"",
|
||||
to_uni(time.strftime('%B',(0,1,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,2,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,3,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,4,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,5,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,6,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,7,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,8,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,9,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,10,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,11,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(0,12,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,1,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,2,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,3,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,4,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,5,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,6,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,7,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,8,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,9,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,10,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,11,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%B',(1,12,1,1,1,1,1,1,1)), codeset),
|
||||
)
|
||||
|
||||
short_months = (
|
||||
"",
|
||||
to_uni(time.strftime('%b',(0,1,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,2,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,3,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,4,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,5,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,6,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,7,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,8,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,9,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,10,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,11,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(0,12,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,1,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,2,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,3,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,4,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,5,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,6,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,7,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,8,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,9,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,10,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,11,1,1,1,1,1,1,1)), codeset),
|
||||
to_uni(time.strftime('%b',(1,12,1,1,1,1,1,1,1)), codeset),
|
||||
)
|
||||
|
||||
# Gramps day number: Sunday => 1, Monday => 2, etc
|
||||
@@ -213,31 +211,31 @@ except:
|
||||
# just a dummy.
|
||||
long_days = (
|
||||
"",
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,6,1,1)), codeset), # Sunday
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,0,1,1)), codeset), # Monday
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,1,1,1)), codeset), # Tuesday
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,2,1,1)), codeset), # Wednesday
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,3,1,1)), codeset), # Thursday
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,4,1,1)), codeset), # Friday
|
||||
to_uni(time.strftime('%A',(0,1,1,1,1,1,5,1,1)), codeset), # Saturday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,6,1,1)), codeset), # Sunday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,0,1,1)), codeset), # Monday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,1,1,1)), codeset), # Tuesday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,2,1,1)), codeset), # Wednesday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,3,1,1)), codeset), # Thursday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,4,1,1)), codeset), # Friday
|
||||
to_uni(time.strftime('%A',(1,1,1,1,1,1,5,1,1)), codeset), # Saturday
|
||||
)
|
||||
|
||||
short_days = (
|
||||
"",
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,6,1,1)), codeset), # Sunday
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,0,1,1)), codeset), # Monday
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,1,1,1)), codeset), # Tuesday
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,2,1,1)), codeset), # Wednesday
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,3,1,1)), codeset), # Thursday
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,4,1,1)), codeset), # Friday
|
||||
to_uni(time.strftime('%a',(0,1,1,1,1,1,5,1,1)), codeset), # Saturday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,6,1,1)), codeset), # Sunday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,0,1,1)), codeset), # Monday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,1,1,1)), codeset), # Tuesday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,2,1,1)), codeset), # Wednesday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,3,1,1)), codeset), # Thursday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,4,1,1)), codeset), # Friday
|
||||
to_uni(time.strftime('%a',(1,1,1,1,1,1,5,1,1)), codeset), # Saturday
|
||||
)
|
||||
|
||||
# depending on the locale, the value returned for 20th Feb 2009 could be
|
||||
# of the format '20/2/2009', '20/02/2009', '20.2.2009', '20.02.2009',
|
||||
# '20-2-2009', '20-02-2009', '2009/02/20', '2009.02.20', '2009-02-20',
|
||||
# '09-02-20' hence to reduce the possible values to test, make sure month
|
||||
# is double digit also day should be double digit, prefebably greater than
|
||||
# is double digit also day should be double digit, preferably greater than
|
||||
# 12 for human readablity
|
||||
|
||||
timestr = time.strftime('%x',(2005,10,25,1,1,1,1,1,1))
|
||||
|
@@ -32,7 +32,8 @@ from this class.
|
||||
# Python libraries
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from ..ggettext import gettext as _
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
@@ -1029,7 +1030,8 @@ class DbReadBase(object):
|
||||
"""
|
||||
raise NotImplementedError
|
||||
|
||||
def load(self, name, callback, mode=None, upgrade=False):
|
||||
def load(self, name, callback, mode=None, force_schema_upgrade=False,
|
||||
force_bsddb_upgrade=False):
|
||||
"""
|
||||
Open the specified database.
|
||||
"""
|
||||
@@ -1414,7 +1416,7 @@ class DbWriteBase(DbReadBase):
|
||||
"""
|
||||
raise NotImplementedError
|
||||
|
||||
def need_upgrade(self):
|
||||
def need_schema_upgrade(self):
|
||||
"""
|
||||
Return True if database needs to be upgraded
|
||||
"""
|
||||
|
@@ -198,8 +198,8 @@ if __name__ == "__main__":
|
||||
x = db.DBEnv()
|
||||
print("3")
|
||||
x.open('/tmp', db.DB_CREATE | db.DB_PRIVATE |\
|
||||
db.DB_INIT_MPOOL | db.DB_INIT_LOCK |\
|
||||
db.DB_INIT_LOG | db.DB_INIT_TXN | db.DB_THREAD)
|
||||
db.DB_INIT_MPOOL |\
|
||||
db.DB_INIT_LOG | db.DB_INIT_TXN)
|
||||
print("4")
|
||||
d = dbshelve.DBShelf(x)
|
||||
print("5")
|
||||
|
@@ -111,7 +111,11 @@ class BsddbBaseCursor(object):
|
||||
_flags | flags | (db.DB_RMW if self._update else 0),
|
||||
**kwargs)
|
||||
|
||||
return (data[0], loads(data[1])) if data else None
|
||||
try:
|
||||
return (data[0], loads(data[1])) if data else None
|
||||
except UnicodeDecodeError:
|
||||
#we need to assume we opened data in python3 saved in python2
|
||||
return (data[0], loads(data[1], encoding='utf-8')) if data else None
|
||||
|
||||
return get
|
||||
|
||||
|
@@ -27,7 +27,8 @@
|
||||
# Standard python modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from ..ggettext import gettext as _
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
|
||||
class DbException(Exception):
|
||||
@@ -71,13 +72,23 @@ class DbVersionError(Exception):
|
||||
Error used to report that a file could not be read because it is written
|
||||
in an unsupported version of the file format.
|
||||
"""
|
||||
def __init__(self):
|
||||
def __init__(self, tree_vers, min_vers, max_vers):
|
||||
Exception.__init__(self)
|
||||
self.tree_vers = tree_vers
|
||||
self.min_vers = min_vers
|
||||
self.max_vers = max_vers
|
||||
|
||||
def __str__(self):
|
||||
return _("The database version is not supported by this version of "
|
||||
"Gramps.\nPlease upgrade to the corresponding version or use "
|
||||
"XML for porting data between different database versions.")
|
||||
return _('The schema version is not supported by this version of '
|
||||
'Gramps.\n\n'
|
||||
'This Family Tree is schema version %(tree_vers)s, and this '
|
||||
'version of Gramps supports versions %(min_vers)s to '
|
||||
'%(max_vers)s\n\n'
|
||||
'Please upgrade to the corresponding version or use '
|
||||
'XML for porting data between different schema versions.') %\
|
||||
{'tree_vers': self.tree_vers,
|
||||
'min_vers': self.min_vers,
|
||||
'max_vers': self.max_vers}
|
||||
|
||||
class BsddbDowngradeError(Exception):
|
||||
"""
|
||||
@@ -90,19 +101,70 @@ class BsddbDowngradeError(Exception):
|
||||
self.bdb_version = str(bdb_version)
|
||||
|
||||
def __str__(self):
|
||||
return _('Gramps stores its data in a Berkeley Database. '
|
||||
'The family tree you try to load was created with version '
|
||||
'%(env_version)s of the Berkeley DB. However, the Gramps '
|
||||
'version in use right now employs version %(bdb_version)s '
|
||||
'of the Berkeley DB. So you are trying to load data created '
|
||||
'in a newer format into an older program; this is bound to '
|
||||
'fail. The right approach in this case is to use XML export '
|
||||
'and import. So try to open the family tree on that computer '
|
||||
'with that software that created the family tree, export it '
|
||||
'to XML and load that XML into the version of Gramps you '
|
||||
'intend to use.') % {'env_version': self.env_version,
|
||||
return _('The Family Tree you are trying to load is in the Bsddb '
|
||||
'version %(env_version)s format. This version of Gramps uses '
|
||||
'Bsddb version %(bdb_version)s. So you are trying to load '
|
||||
'data created in a newer format into an older program, and '
|
||||
'this is bound to fail.\n\n'
|
||||
'You should start your <b>newer</b> version of Gramps and '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=How_to_make_a_backup">'
|
||||
'make a backup</a> of your Family Tree. You can then import '
|
||||
'this backup into this version of Gramps.') % \
|
||||
{'env_version': self.env_version,
|
||||
'bdb_version': self.bdb_version}
|
||||
|
||||
class BsddbDowngradeRequiredError(Exception):
|
||||
"""
|
||||
Error used to report that the Berkeley database used to create the family
|
||||
tree is of a version that is newer than the current version, but it may be
|
||||
possible to open the tree, because the difference is only a point upgrade
|
||||
(i.e. a difference in the last digit of the version tuple).
|
||||
"""
|
||||
def __init__(self, env_version, bdb_version):
|
||||
Exception.__init__(self)
|
||||
self.env_version = str(env_version)
|
||||
self.bdb_version = str(bdb_version)
|
||||
|
||||
def __str__(self):
|
||||
return _('The Family Tree you are trying to load is in the Bsddb '
|
||||
'version %(env_version)s format. This version of Gramps uses '
|
||||
'Bsddb version %(bdb_version)s. So you are trying to load '
|
||||
'data created in a newer format into an older program. In '
|
||||
'this particular case, the difference is very small, so it '
|
||||
'may work.\n\n'
|
||||
'If you have not already made a backup of your Family Tree, '
|
||||
'then you should start your <b>newer</b> version of Gramps and '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=How_to_make_a_backup">'
|
||||
'make a backup</a> of your Family Tree.') % \
|
||||
{'env_version': self.env_version,
|
||||
'bdb_version': self.bdb_version}
|
||||
|
||||
class BsddbUpgradeRequiredError(Exception):
|
||||
"""
|
||||
Error used to report that the Berkeley database used to create the family
|
||||
tree is of a version that is too new to be supported by the current version.
|
||||
"""
|
||||
def __init__(self, env_version, bsddb_version):
|
||||
Exception.__init__(self)
|
||||
self.env_version = str(env_version)
|
||||
self.bsddb_version = str(bsddb_version)
|
||||
|
||||
def __str__(self):
|
||||
return _('The Family Tree you are trying to load is in the Bsddb '
|
||||
'version %(env_version)s format. This version of Gramps uses '
|
||||
'Bsddb version %(bdb_version)s. Therefore you cannot load '
|
||||
'this Family Tree without upgrading the Bsddb version of the '
|
||||
'Family Tree.\n\n'
|
||||
'Opening the Family Tree with this version of Gramps might '
|
||||
'irretrievably corrupt your Family Tree. You are strongly '
|
||||
'advised to backup your Family Tree.\n\n'
|
||||
'If you have not already made a backup of your Family Tree, '
|
||||
'then you should start your <b>old</b> version of Gramps and '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=How_to_make_a_backup">'
|
||||
'make a backup</a> of your Family Tree.') % \
|
||||
{'env_version': self.env_version,
|
||||
'bdb_version': self.bsddb_version}
|
||||
|
||||
class DbEnvironmentError(Exception):
|
||||
"""
|
||||
Error used to report that the database 'environment' could not be opened.
|
||||
@@ -132,11 +194,83 @@ class DbUpgradeRequiredError(Exception):
|
||||
Error used to report that a database needs to be upgraded before it can be
|
||||
used.
|
||||
"""
|
||||
def __init__(self):
|
||||
def __init__(self, oldschema, newschema):
|
||||
Exception.__init__(self)
|
||||
self.oldschema = oldschema
|
||||
self.newschema = newschema
|
||||
|
||||
def __str__(self):
|
||||
return _("You cannot open this database without upgrading it.\n"
|
||||
"If you upgrade then you won't be able to use previous "
|
||||
"versions of Gramps.\n"
|
||||
"You might want to make a backup copy first.")
|
||||
return _('The Family Tree you are trying to load is in the schema '
|
||||
'version %(oldschema)s format. This version of Gramps uses '
|
||||
'schema version %(newschema)s. Therefore you cannot load this '
|
||||
'Family Tree without upgrading the schema version of the '
|
||||
'Family Tree.\n\n'
|
||||
'If you upgrade then you won\'t be able to use the previous '
|
||||
'version of Gramps, even if you subsequently '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_Manage_Family_Trees#Backing_up_a_Family_Tree">backup</a> '
|
||||
'or <a href="http://www.gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_Manage_Family_Trees#Export_into_Gramps_formats">export</a> '
|
||||
'your upgraded Family Tree.\n\n'
|
||||
'Upgrading is a difficult task which could irretrievably '
|
||||
'corrupt your Family Tree if it is interrupted or fails.\n\n'
|
||||
'If you have not already made a backup of your Family Tree, '
|
||||
'then you should start your <b>old</b> version of Gramps and '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=How_to_make_a_backup">make a backup</a> '
|
||||
'of your Family Tree.') % \
|
||||
{'oldschema': self.oldschema,
|
||||
'newschema': self.newschema}
|
||||
|
||||
class PythonDowngradeError(Exception):
|
||||
"""
|
||||
Error used to report that the Python version used to create the family tree
|
||||
(i.e. Python3) is of a version that is newer than the current version
|
||||
(i.e.Python2), so the Family Tree cannot be opened
|
||||
"""
|
||||
def __init__(self, db_python_version, current_python_version):
|
||||
Exception.__init__(self)
|
||||
self.db_python_version = str(db_python_version)
|
||||
self.current_python_version = str(current_python_version)
|
||||
|
||||
def __str__(self):
|
||||
return _('The Family Tree you are trying to load was created with '
|
||||
'Python version %(db_python_version)s. This version of Gramps '
|
||||
'uses Python version %(current_python_version)s. So you are '
|
||||
'trying to load '
|
||||
'data created in a newer format into an older program, and '
|
||||
'this is bound to fail.\n\n'
|
||||
'You should start your <b>newer</b> version of Gramps and '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=How_to_make_a_backup">'
|
||||
'make a backup</a> of your Family Tree. You can then import '
|
||||
'this backup into this version of Gramps.') % \
|
||||
{'db_python_version': self.db_python_version,
|
||||
'current_python_version': self.current_python_version}
|
||||
|
||||
class PythonUpgradeRequiredError(Exception):
|
||||
"""
|
||||
Error used to report that the Python version used to create the family tree
|
||||
(i.e. Python2) is earlier than the current Python version (i.e. Python3), so
|
||||
the Family Tree needs to be upgraded..
|
||||
"""
|
||||
def __init__(self, db_python_version, current_python_version):
|
||||
Exception.__init__(self)
|
||||
self.db_python_version = str(db_python_version)
|
||||
self.current_python_version = str(current_python_version)
|
||||
|
||||
def __str__(self):
|
||||
return _('The Family Tree you are trying to load is in the Python '
|
||||
'version %(db_python_version)s format. This version of Gramps '
|
||||
'uses Python version %(current_python_version)s. Therefore '
|
||||
'you cannot load this Family Tree without upgrading the '
|
||||
'Python version of the Family Tree.\n\n'
|
||||
'If you upgrade then you won\'t be able to use the previous '
|
||||
'version of Gramps, even if you subsequently '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_Manage_Family_Trees#Backing_up_a_Family_Tree">backup</a> '
|
||||
'or <a href="http://www.gramps-project.org/wiki/index.php?title=Gramps_4.0_Wiki_Manual_-_Manage_Family_Trees#Export_into_Gramps_formats">export</a> '
|
||||
'your upgraded Family Tree.\n\n'
|
||||
'Upgrading is a difficult task which could irretrievably '
|
||||
'corrupt your Family Tree if it is interrupted or fails.\n\n'
|
||||
'If you have not already made a backup of your Family Tree, '
|
||||
'then you should start your <b>old</b> version of Gramps and '
|
||||
'<a href="http://www.gramps-project.org/wiki/index.php?title=How_to_make_a_backup">make a backup</a> '
|
||||
'of your Family Tree.') % \
|
||||
{'db_python_version': self.db_python_version,
|
||||
'current_python_version': self.current_python_version}
|
||||
|
@@ -40,7 +40,6 @@ else:
|
||||
import pickle
|
||||
import time
|
||||
import random
|
||||
import locale
|
||||
import os
|
||||
from sys import maxsize
|
||||
|
||||
@@ -49,7 +48,8 @@ if config.get('preferences.use-bsddb3') or sys.version_info[0] >= 3:
|
||||
from bsddb3 import db
|
||||
else:
|
||||
from bsddb import db
|
||||
from ..ggettext import gettext as _
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
import re
|
||||
|
||||
import logging
|
||||
@@ -79,7 +79,8 @@ from ..utils.cast import conv_dbstr_to_unicode
|
||||
from . import (BsddbBaseCursor, DbReadBase)
|
||||
from ..utils.id import create_id
|
||||
from ..errors import DbError
|
||||
from ..constfunc import UNITYPE, STRTYPE, cuni
|
||||
from ..constfunc import UNITYPE, STRTYPE, cuni, handle2internal
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
|
||||
LOG = logging.getLogger(DBLOGNAME)
|
||||
LOG = logging.getLogger(".citation")
|
||||
@@ -102,6 +103,17 @@ DBERRS = (db.DBRunRecoveryError, db.DBAccessError,
|
||||
# Helper functions
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
def find_byte_surname(key, data):
|
||||
"""
|
||||
Creating a surname from raw data of a person, to use for sort and index
|
||||
returns a byte string
|
||||
"""
|
||||
surn = __index_surname(data[3][5])
|
||||
# in python 3 we work with unicode internally, but need byte function sometimes
|
||||
if isinstance(surn, UNITYPE):
|
||||
return surn.encode('utf-8')
|
||||
return surn
|
||||
|
||||
def find_surname(key, data):
|
||||
"""
|
||||
Creating a surname from raw data of a person, to use for sort and index
|
||||
@@ -127,7 +139,10 @@ def __index_surname(surn_list):
|
||||
NameOriginType.PATRONYMIC, NameOriginType.MATRONYMIC]) ])
|
||||
else:
|
||||
surn = ""
|
||||
return surn.encode('utf-8')
|
||||
if sys.version_info[0] < 3:
|
||||
return surn.encode('utf-8')
|
||||
else:
|
||||
return surn
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
@@ -745,6 +760,8 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
return self.get_from_handle(handle, Tag, self.tag_map)
|
||||
|
||||
def __get_obj_from_gramps_id(self, val, tbl, class_, prim_tbl):
|
||||
if isinstance(tbl, dict):
|
||||
return None ## trying to get object too early
|
||||
if isinstance(val, UNITYPE):
|
||||
val = val.encode('utf-8')
|
||||
try:
|
||||
@@ -951,6 +968,11 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
return self.get_number_of_records(self.tag_map)
|
||||
|
||||
def all_handles(self, table):
|
||||
""" return all the keys of a database table
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
return table.keys(txn=self.txn)
|
||||
|
||||
def get_person_handles(self, sort_handles=False):
|
||||
@@ -959,6 +981,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
the database.
|
||||
|
||||
If sort_handles is True, the list is sorted by surnames.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
handle_list = self.all_handles(self.person_map)
|
||||
@@ -973,6 +999,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
the database.
|
||||
|
||||
If sort_handles is True, the list is sorted by Place title.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
|
||||
if self.db_is_open:
|
||||
@@ -987,7 +1017,11 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
Return a list of database handles, one handle for each Source in
|
||||
the database.
|
||||
|
||||
If sort_handles is True, the list is sorted by Source title.
|
||||
If sort_handles is True, the list is sorted by Source title.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
handle_list = self.all_handles(self.source_map)
|
||||
@@ -1001,7 +1035,11 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
Return a list of database handles, one handle for each Citation in
|
||||
the database.
|
||||
|
||||
If sort_handles is True, the list is sorted by Citation Volume/Page.
|
||||
If sort_handles is True, the list is sorted by Citation Volume/Page.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
handle_list = self.all_handles(self.citation_map)
|
||||
@@ -1016,6 +1054,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
the database.
|
||||
|
||||
If sort_handles is True, the list is sorted by title.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
handle_list = self.all_handles(self.media_map)
|
||||
@@ -1028,6 +1070,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
"""
|
||||
Return a list of database handles, one handle for each Event in the
|
||||
database.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
return self.all_handles(self.event_map)
|
||||
@@ -1037,6 +1083,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
"""
|
||||
Return a list of database handles, one handle for each Family in
|
||||
the database.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
return self.all_handles(self.family_map)
|
||||
@@ -1046,6 +1096,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
"""
|
||||
Return a list of database handles, one handle for each Repository in
|
||||
the database.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
return self.all_handles(self.repository_map)
|
||||
@@ -1055,6 +1109,10 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
"""
|
||||
Return a list of database handles, one handle for each Note in the
|
||||
database.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
return self.all_handles(self.note_map)
|
||||
@@ -1065,7 +1123,11 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
Return a list of database handles, one handle for each Tag in
|
||||
the database.
|
||||
|
||||
If sort_handles is True, the list is sorted by Tag name.
|
||||
If sort_handles is True, the list is sorted by Tag name.
|
||||
|
||||
CAREFUL: For speed the keys are directly returned, so on python3
|
||||
bytestrings are returned! Use constfunc.py handle2internal
|
||||
on this result!
|
||||
"""
|
||||
if self.db_is_open:
|
||||
handle_list = self.all_handles(self.tag_map)
|
||||
@@ -1081,7 +1143,7 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
def g(self):
|
||||
with curs_(self) as cursor:
|
||||
for key, data in cursor:
|
||||
yield key
|
||||
yield handle2internal(key)
|
||||
return g
|
||||
|
||||
# Use closure to define iterators for each primary object type
|
||||
@@ -1513,10 +1575,16 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
"""
|
||||
Helper method for get_raw_<object>_data methods
|
||||
"""
|
||||
if table is None:
|
||||
return None ## trying to get object too early
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
try:
|
||||
return table.get(handle, txn=self.txn)
|
||||
except UnicodeDecodeError:
|
||||
#we need to assume we opened data in python3 saved in python2
|
||||
raw = table.db.get(handle, txn=self.txn)
|
||||
return pickle.loads(raw, encoding='utf-8')
|
||||
except DBERRS as msg:
|
||||
self.__log_error()
|
||||
raise DbError(msg)
|
||||
@@ -1626,7 +1694,7 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
def __sortbyperson_key(self, handle):
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
return locale.strxfrm(find_surname(handle,
|
||||
return glocale.sort_key(find_surname(handle,
|
||||
self.person_map.get(handle)))
|
||||
|
||||
def __sortbyplace(self, first, second):
|
||||
@@ -1634,13 +1702,13 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
first = first.encode('utf-8')
|
||||
if isinstance(second, UNITYPE):
|
||||
second = second.encode('utf-8')
|
||||
return locale.strcoll(self.place_map.get(first)[2],
|
||||
return glocale.strcoll(self.place_map.get(first)[2],
|
||||
self.place_map.get(second)[2])
|
||||
|
||||
def __sortbyplace_key(self, place):
|
||||
if isinstance(place, UNITYPE):
|
||||
place = place.encode('utf-8')
|
||||
return locale.strxfrm(self.place_map.get(place)[2])
|
||||
return glocale.sort_key(self.place_map.get(place)[2])
|
||||
|
||||
def __sortbysource(self, first, second):
|
||||
if isinstance(first, UNITYPE):
|
||||
@@ -1649,13 +1717,13 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
second = second.encode('utf-8')
|
||||
source1 = cuni(self.source_map[first][2])
|
||||
source2 = cuni(self.source_map[second][2])
|
||||
return locale.strcoll(source1, source2)
|
||||
return glocale.strcoll(source1, source2)
|
||||
|
||||
def __sortbysource_key(self, key):
|
||||
if isinstance(key, UNITYPE):
|
||||
key = key.encode('utf-8')
|
||||
source = cuni(self.source_map[key][2])
|
||||
return locale.strxfrm(source)
|
||||
return glocale.sort_key(source)
|
||||
|
||||
def __sortbycitation(self, first, second):
|
||||
if isinstance(first, UNITYPE):
|
||||
@@ -1664,13 +1732,13 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
second = second.encode('utf-8')
|
||||
citation1 = cuni(self.citation_map[first][3])
|
||||
citation2 = cuni(self.citation_map[second][3])
|
||||
return locale.strcoll(citation1, citation2)
|
||||
return glocale.strcoll(citation1, citation2)
|
||||
|
||||
def __sortbycitation_key(self, key):
|
||||
if isinstance(key, UNITYPE):
|
||||
key = key.encode('utf-8')
|
||||
citation = cuni(self.citation_map[key][3])
|
||||
return locale.strxfrm(citation)
|
||||
return glocale.sort_key(citation)
|
||||
|
||||
def __sortbymedia(self, first, second):
|
||||
if isinstance(first, UNITYPE):
|
||||
@@ -1679,13 +1747,13 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
second = second.encode('utf-8')
|
||||
media1 = self.media_map[first][4]
|
||||
media2 = self.media_map[second][4]
|
||||
return locale.strcoll(media1, media2)
|
||||
return glocale.strcoll(media1, media2)
|
||||
|
||||
def __sortbymedia_key(self, key):
|
||||
if isinstance(key, UNITYPE):
|
||||
key = key.encode('utf-8')
|
||||
media = self.media_map[key][4]
|
||||
return locale.strxfrm(media)
|
||||
return glocale.sort_key(media)
|
||||
|
||||
def __sortbytag(self, first, second):
|
||||
if isinstance(first, UNITYPE):
|
||||
@@ -1694,13 +1762,13 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
second = second.encode('utf-8')
|
||||
tag1 = self.tag_map[first][1]
|
||||
tag2 = self.tag_map[second][1]
|
||||
return locale.strcoll(tag1, tag2)
|
||||
return glocale.strcoll(tag1, tag2)
|
||||
|
||||
def __sortbytag_key(self, key):
|
||||
if isinstance(key, UNITYPE):
|
||||
key = key.encode('utf-8')
|
||||
tag = self.tag_map[key][1]
|
||||
return locale.strxfrm(tag)
|
||||
return glocale.sort_key(tag)
|
||||
|
||||
def set_mediapath(self, path):
|
||||
"""Set the default media path for database, path should be utf-8."""
|
||||
@@ -1832,7 +1900,7 @@ class DbBsddbRead(DbReadBase, Callback):
|
||||
filepath = os.path.join(self.path, "name.txt")
|
||||
try:
|
||||
name_file = open(filepath, "r")
|
||||
name = name_file.read()
|
||||
name = name_file.readline().strip()
|
||||
name_file.close()
|
||||
except (OSError, IOError) as msg:
|
||||
self.__log_error()
|
||||
|
@@ -213,7 +213,7 @@ class DbTest(object):
|
||||
"commit_source",
|
||||
"commit_tag",
|
||||
"delete_primary_from_reference_map",
|
||||
"need_upgrade",
|
||||
"need_schema_upgrade",
|
||||
"rebuild_secondary",
|
||||
"reindex_reference_map",
|
||||
"remove_event",
|
||||
|
@@ -46,13 +46,15 @@ if config.get('preferences.use-bsddb3') or sys.version_info[0] >= 3:
|
||||
from bsddb3 import db
|
||||
else:
|
||||
from bsddb import db
|
||||
from ..ggettext import gettext as _
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Gramps modules
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
from ..constfunc import conv_to_unicode, handle2internal
|
||||
from .dbconst import *
|
||||
from . import BSDDBTxn
|
||||
from ..errors import DbError
|
||||
@@ -67,6 +69,7 @@ DBERRS = (db.DBRunRecoveryError, db.DBAccessError,
|
||||
|
||||
_SIGBASE = ('person', 'family', 'source', 'event', 'media',
|
||||
'place', 'repository', 'reference', 'note', 'tag', 'citation')
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# DbUndo class
|
||||
@@ -315,7 +318,7 @@ class DbUndo(object):
|
||||
"""
|
||||
try:
|
||||
if data is None:
|
||||
emit(signal_root + '-delete', ([handle],))
|
||||
emit(signal_root + '-delete', ([handle2internal(handle)],))
|
||||
db_map.delete(handle, txn=self.txn)
|
||||
else:
|
||||
ex_data = db_map.get(handle, txn=self.txn)
|
||||
@@ -324,7 +327,7 @@ class DbUndo(object):
|
||||
else:
|
||||
signal = signal_root + '-add'
|
||||
db_map.put(handle, data, txn=self.txn)
|
||||
emit(signal, ([handle],))
|
||||
emit(signal, ([handle2internal(handle)],))
|
||||
|
||||
except DBERRS as msg:
|
||||
self.db._log_error()
|
||||
|
@@ -30,7 +30,8 @@ import time
|
||||
import logging
|
||||
LOG = logging.getLogger(".citation")
|
||||
|
||||
from ..ggettext import gettext as _
|
||||
from ..const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
from ..constfunc import cuni
|
||||
|
||||
"""
|
||||
@@ -144,7 +145,9 @@ def gramps_upgrade_16(self):
|
||||
new_citation_list, note_list, change, tag_list,
|
||||
private, person_ref_list)
|
||||
with BSDDBTxn(self.env, self.person_map) as txn:
|
||||
txn.put(str(handle), new_person)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_person)
|
||||
self.update()
|
||||
|
||||
LOG.debug("%d persons upgraded with %d citations in %d seconds. " %
|
||||
@@ -176,7 +179,9 @@ def gramps_upgrade_16(self):
|
||||
change, date, tag_list, private)
|
||||
LOG.debug(" upgrade new_media %s" % [new_media])
|
||||
with BSDDBTxn(self.env, self.media_map) as txn:
|
||||
txn.put(str(handle), new_media)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_media)
|
||||
LOG.debug(" update ref map media %s" % [handle,
|
||||
self.get_object_from_handle(handle) ])
|
||||
self.update()
|
||||
@@ -195,7 +200,7 @@ def gramps_upgrade_16(self):
|
||||
start_time = time.time()
|
||||
for place_handle in self.place_map.keys():
|
||||
place = self.place_map[place_handle]
|
||||
(handle, gramps_id, title, int, lat,
|
||||
(handle, gramps_id, title, longi, lat,
|
||||
main_loc, alt_loc, urls, media_list, source_list, note_list,
|
||||
change, private) = place
|
||||
if source_list:
|
||||
@@ -208,11 +213,13 @@ def gramps_upgrade_16(self):
|
||||
self, media_list)
|
||||
if source_list or media_list:
|
||||
new_place = (handle, gramps_id, title,
|
||||
int, lat, main_loc, alt_loc, urls,
|
||||
longi, lat, main_loc, alt_loc, urls,
|
||||
media_list, new_citation_list, note_list,
|
||||
change, private)
|
||||
with BSDDBTxn(self.env, self.place_map) as txn:
|
||||
txn.put(str(handle), new_place)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_place)
|
||||
self.update()
|
||||
|
||||
LOG.debug("%d places upgraded with %d citations in %d seconds. " %
|
||||
@@ -260,7 +267,9 @@ def gramps_upgrade_16(self):
|
||||
attribute_list, lds_seal_list, new_citation_list,
|
||||
note_list, change, tag_list, private)
|
||||
with BSDDBTxn(self.env, self.family_map) as txn:
|
||||
txn.put(str(handle), new_family)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_family)
|
||||
self.update()
|
||||
|
||||
LOG.debug("%d familys upgraded with %d citations in %d seconds. " %
|
||||
@@ -300,7 +309,9 @@ def gramps_upgrade_16(self):
|
||||
attribute_list,
|
||||
change, private)
|
||||
with BSDDBTxn(self.env, self.event_map) as txn:
|
||||
txn.put(str(handle), new_event)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_event)
|
||||
t2 = time.time()
|
||||
upgrade_time += t2 - t1
|
||||
t3 = time.time()
|
||||
@@ -332,7 +343,9 @@ def gramps_upgrade_16(self):
|
||||
new_repository = (handle, gramps_id, the_type, name, note_list,
|
||||
address_list, urls, change, private)
|
||||
with BSDDBTxn(self.env, self.repository_map) as txn:
|
||||
txn.put(str(handle), new_repository)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_repository)
|
||||
self.update()
|
||||
|
||||
LOG.debug("%d repositorys upgraded with %d citations in %d seconds. " %
|
||||
@@ -535,7 +548,9 @@ def convert_source_list_to_citation_list_16(self, source_list):
|
||||
date, page, confidence, ref, note_list, new_media_list,
|
||||
new_data_map, new_change, private)
|
||||
with BSDDBTxn(self.env, self.citation_map) as txn:
|
||||
txn.put(str(new_handle), new_citation)
|
||||
if isinstance(new_handle, UNITYPE):
|
||||
new_handle = new_handle.encode('utf-8')
|
||||
txn.put(new_handle, new_citation)
|
||||
self.cmap_index += 1
|
||||
# # add backlinks for references from Citation to Source
|
||||
# with BSDDBTxn(self.env) as txn:
|
||||
@@ -621,7 +636,9 @@ def gramps_upgrade_15(self):
|
||||
)
|
||||
|
||||
with BSDDBTxn(self.env, self.person_map) as txn:
|
||||
txn.put(str(handle), new_person)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_person)
|
||||
self.update()
|
||||
#surname is now different, remove secondary index with names
|
||||
_db = db.DB(self.env)
|
||||
@@ -644,7 +661,9 @@ def gramps_upgrade_15(self):
|
||||
new_family[13] = []
|
||||
new_family = tuple(new_family)
|
||||
with BSDDBTxn(self.env, self.family_map) as txn:
|
||||
txn.put(str(handle), new_family)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_family)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -661,7 +680,9 @@ def gramps_upgrade_15(self):
|
||||
new_note[6] = []
|
||||
new_note = tuple(new_note)
|
||||
with BSDDBTxn(self.env, self.note_map) as txn:
|
||||
txn.put(str(handle), new_note)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_note)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -674,7 +695,9 @@ def gramps_upgrade_15(self):
|
||||
new_media[10] = []
|
||||
new_media = tuple(new_media)
|
||||
with BSDDBTxn(self.env, self.media_map) as txn:
|
||||
txn.put(str(handle), new_media)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_media)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -688,7 +711,9 @@ def gramps_upgrade_15(self):
|
||||
#new_event[11] = []
|
||||
new_event = tuple(new_event)
|
||||
with BSDDBTxn(self.env, self.event_map) as txn:
|
||||
txn.put(str(handle), new_event)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_event)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -704,7 +729,9 @@ def gramps_upgrade_15(self):
|
||||
new_place = new_place[:12] + new_place[13:]
|
||||
new_place = tuple(new_place)
|
||||
with BSDDBTxn(self.env, self.place_map) as txn:
|
||||
txn.put(str(handle), new_place)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_place)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -717,7 +744,9 @@ def gramps_upgrade_15(self):
|
||||
new_source = new_source[:11] + new_source[12:]
|
||||
new_source = tuple(new_source)
|
||||
with BSDDBTxn(self.env, self.source_map) as txn:
|
||||
txn.put(str(handle), new_source)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_source)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -731,7 +760,9 @@ def gramps_upgrade_15(self):
|
||||
new_repository[5] = list(map(convert_address, new_repository[5]))
|
||||
new_repository = tuple(new_repository)
|
||||
with BSDDBTxn(self.env, self.repository_map) as txn:
|
||||
txn.put(str(handle), new_repository)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_repository)
|
||||
self.update()
|
||||
|
||||
# Bump up database version. Separate transaction to save metadata.
|
||||
@@ -753,6 +784,8 @@ def convert_marker(self, marker_field):
|
||||
tag.set_name(tag_name)
|
||||
tag.set_priority(len(self.tags))
|
||||
with BSDDBTxn(self.env, self.tag_map) as txn:
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, tag.serialize())
|
||||
self.tags[tag_name] = handle
|
||||
return self.tags[tag_name]
|
||||
@@ -819,7 +852,9 @@ def gramps_upgrade_14(self):
|
||||
new_note = (handle, gramps_id, styled_text, format, note_type,
|
||||
change, marker, private)
|
||||
with BSDDBTxn(self.env, self.note_map) as txn:
|
||||
txn.put(str(handle), new_note)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_note)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -839,7 +874,9 @@ def gramps_upgrade_14(self):
|
||||
description, place, new_source_list, note_list,
|
||||
new_media_list, new_attribute_list, change,marker,private)
|
||||
with BSDDBTxn(self.env, self.event_map) as txn:
|
||||
txn.put(str(handle), new_event)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_event)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -921,7 +958,9 @@ def gramps_upgrade_14(self):
|
||||
)
|
||||
|
||||
with BSDDBTxn(self.env, self.person_map) as txn:
|
||||
txn.put(str(handle), new_person)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_person)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -953,7 +992,9 @@ def gramps_upgrade_14(self):
|
||||
change, marker, private)
|
||||
|
||||
with BSDDBTxn(self.env, self.family_map) as txn:
|
||||
txn.put(str(handle), new_family)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_family)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -978,7 +1019,9 @@ def gramps_upgrade_14(self):
|
||||
new_address_list, urls, change, marker, private)
|
||||
|
||||
with BSDDBTxn(self.env, self.repository_map) as txn:
|
||||
txn.put(str(handle), new_repository)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_repository)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -996,7 +1039,9 @@ def gramps_upgrade_14(self):
|
||||
new_date, marker, private)
|
||||
|
||||
with BSDDBTxn(self.env, self.media_map) as txn:
|
||||
txn.put(str(handle), new_media)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_media)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -1004,17 +1049,19 @@ def gramps_upgrade_14(self):
|
||||
# ---------------------------------
|
||||
for place_handle in self.place_map.keys():
|
||||
place = self.place_map[place_handle]
|
||||
(handle, gramps_id, title, int, lat,
|
||||
(handle, gramps_id, title, longi, lat,
|
||||
main_loc, alt_loc, urls, media_list, source_list, note_list,
|
||||
change, marker, private) = place
|
||||
new_media_list = new_media_list_14(media_list)
|
||||
new_source_list = new_source_list_14(source_list)
|
||||
new_place = (handle, gramps_id, title, int, lat,
|
||||
new_place = (handle, gramps_id, title, longi, lat,
|
||||
main_loc, alt_loc, urls, new_media_list,
|
||||
new_source_list, note_list, change, marker, private)
|
||||
|
||||
with BSDDBTxn(self.env, self.place_map) as txn:
|
||||
txn.put(str(handle), new_place)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_place)
|
||||
self.update()
|
||||
|
||||
# ---------------------------------
|
||||
@@ -1033,7 +1080,9 @@ def gramps_upgrade_14(self):
|
||||
marker, private)
|
||||
|
||||
with BSDDBTxn(self.env, self.source_map) as txn:
|
||||
txn.put(str(handle), new_source)
|
||||
if isinstance(handle, UNITYPE):
|
||||
handle = handle.encode('utf-8')
|
||||
txn.put(handle, new_source)
|
||||
self.update()
|
||||
|
||||
# Bump up database version. Separate transaction to save metadata.
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user