From: | "Alexis Ballier (aballier)" <aballier@g.o> |
---|---|
To: | gentoo-commits@l.g.o |
Subject: | [gentoo-commits] gentoo commit in src/patchsets/texlive/2011/texlive-core: 150_all_texdoc_update.patch series |
Date: | Wed, 30 May 2012 23:40:42 |
Message-Id: | 20120530234032.1C6062004B@flycatcher.gentoo.org |
1 | aballier 12/05/30 23:40:32 |
2 | |
3 | Modified: series |
4 | Added: 150_all_texdoc_update.patch |
5 | Log: |
6 | import upstream patch to improve DE guessing in texdoc, bug #418183 |
7 | |
8 | Revision Changes Path |
9 | 1.7 src/patchsets/texlive/2011/texlive-core/series |
10 | |
11 | file : http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/texlive/2011/texlive-core/series?rev=1.7&view=markup |
12 | plain: http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/texlive/2011/texlive-core/series?rev=1.7&content-type=text/plain |
13 | diff : http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/texlive/2011/texlive-core/series?r1=1.6&r2=1.7 |
14 | |
15 | Index: series |
16 | =================================================================== |
17 | RCS file: /var/cvsroot/gentoo/src/patchsets/texlive/2011/texlive-core/series,v |
18 | retrieving revision 1.6 |
19 | retrieving revision 1.7 |
20 | diff -u -r1.6 -r1.7 |
21 | --- series 25 May 2012 18:27:30 -0000 1.6 |
22 | +++ series 30 May 2012 23:40:32 -0000 1.7 |
23 | @@ -4,3 +4,4 @@ |
24 | 120_all_noasmpic.patch |
25 | 130_all_zlib126.patch |
26 | 140_all_poppler020.patch |
27 | +150_all_texdoc_update.patch |
28 | |
29 | |
30 | |
31 | 1.1 src/patchsets/texlive/2011/texlive-core/150_all_texdoc_update.patch |
32 | |
33 | file : http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/texlive/2011/texlive-core/150_all_texdoc_update.patch?rev=1.1&view=markup |
34 | plain: http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/texlive/2011/texlive-core/150_all_texdoc_update.patch?rev=1.1&content-type=text/plain |
35 | |
36 | Index: 150_all_texdoc_update.patch |
37 | =================================================================== |
38 | Update from upstream svn. |
39 | Improves guessing of DE for opening documents. |
40 | https://bugs.gentoo.org/show_bug.cgi?id=418183 |
41 | |
42 | Index: texlive-20110705-source/texmf/scripts/texdoc/config.tlu |
43 | =================================================================== |
44 | --- texlive-20110705-source.orig/texmf/scripts/texdoc/config.tlu |
45 | +++ texlive-20110705-source/texmf/scripts/texdoc/config.tlu |
46 | @@ -329,13 +329,18 @@ function is_in_path(name) |
47 | end |
48 | end |
49 | |
50 | --- guess a viewer from a list: |
51 | +-- guess a viewer from a list: |
52 | +-- - xdg-open from freedesktop if available |
53 | -- - try detecting desktop environments |
54 | -- - or return the first element of "list" whose name is found in path |
55 | -- - or nil |
56 | -- caches results of desktop environment detection |
57 | do local de_viewer |
58 | function guess_viewer(cmds) |
59 | + -- try the freedesktop method |
60 | + if is_in_path('xdg-open') then |
61 | + return '(xdg-open %s) &' |
62 | + end |
63 | -- try desktop environment |
64 | if not de_viewer then de_viewer = desktop_environment_viewer() end |
65 | if de_viewer then return de_viewer end |
66 | @@ -357,7 +362,8 @@ function desktop_environment_viewer() |
67 | return '(kfmclient exec %s) &' -- kde < 4 |
68 | end |
69 | if os.getenv('GNOME_DESKTOP_SESSION_ID') then -- gnome |
70 | - return '(gnome-open %s) &' |
71 | + if is_in_path('gvfs-open') then return '(gvfs-open %s) &' end |
72 | + if is_in_path('gnome-open') then return '(gnome-open %s) &' end |
73 | end |
74 | if not is_in_path('xprop') then return end |
75 | local xprop_fh = io.popen('xprop -root _DT_SAVE_MODE 2>/dev/null') |