Update to alacarte-3.7.90 to unbreak runtime.
ok jasper@
This commit is contained in:
parent
a969ec038f
commit
e2ae313f8d
@ -1,9 +1,9 @@
|
||||
# $OpenBSD: Makefile,v 1.43 2013/04/02 17:45:46 ajacoutot Exp $
|
||||
# $OpenBSD: Makefile,v 1.44 2013/04/04 07:05:06 ajacoutot Exp $
|
||||
|
||||
COMMENT= fd.o menu editor for GNOME
|
||||
|
||||
GNOME_PROJECT= alacarte
|
||||
GNOME_VERSION= 3.6.1
|
||||
GNOME_VERSION= 3.7.90
|
||||
|
||||
CATEGORIES= sysutils
|
||||
|
||||
|
@ -1,2 +1,2 @@
|
||||
SHA256 (gnome/alacarte-3.6.1.tar.xz) = fhe9gOQxMK/qY3KpV3d9KJybm21Ik6ogrT9Fu9SN0l4=
|
||||
SIZE (gnome/alacarte-3.6.1.tar.xz) = 177640
|
||||
SHA256 (gnome/alacarte-3.7.90.tar.xz) = N5rkhCL/a8e5ZX0fmWioPuTrj4xplk27jOLaxuC1zPA=
|
||||
SIZE (gnome/alacarte-3.7.90.tar.xz) = 180172
|
||||
|
@ -1,32 +0,0 @@
|
||||
$OpenBSD: patch-Alacarte_MainWindow_py,v 1.4 2013/03/11 09:37:03 ajacoutot Exp $
|
||||
|
||||
From f7835d7dcd37b10f25e208581ec52919cf68e732 Mon Sep 17 00:00:00 2001
|
||||
From: Jasper St. Pierre <jstpierre@mecheye.net>
|
||||
Date: Sat, 17 Nov 2012 04:22:14 +0000
|
||||
Subject: Fix crashes when writing out files
|
||||
|
||||
From 10f611c074ae7b2ab0ec48ff3b8946c5f8e19970 Mon Sep 17 00:00:00 2001
|
||||
From: Jasper St. Pierre <jstpierre@mecheye.net>
|
||||
Date: Sat, 17 Nov 2012 04:26:14 +0000
|
||||
Subject: Use with statements for management
|
||||
|
||||
--- Alacarte/MainWindow.py.orig Mon Mar 11 09:45:41 2013
|
||||
+++ Alacarte/MainWindow.py Mon Mar 11 09:45:33 2013
|
||||
@@ -19,6 +19,7 @@
|
||||
|
||||
from gi.repository import Gtk, GObject, Gio, GdkPixbuf, Gdk, GMenu, GLib
|
||||
import cgi
|
||||
+import codecs
|
||||
import os
|
||||
import gettext
|
||||
import subprocess
|
||||
@@ -319,7 +320,8 @@ class MainWindow(object):
|
||||
|
||||
if not os.path.isfile(file_path):
|
||||
data = open(item.get_desktop_file_path()).read()
|
||||
- open(file_path, 'w').write(data)
|
||||
+ with codecs.open(file_path, 'w', 'utf8') as f:
|
||||
+ f.write(data)
|
||||
|
||||
if file_path not in self.edit_pool:
|
||||
self.edit_pool.append(file_path)
|
@ -1,87 +0,0 @@
|
||||
$OpenBSD: patch-Alacarte_MenuEditor_py,v 1.3 2013/03/11 09:37:03 ajacoutot Exp $
|
||||
|
||||
From fe7211f2eb4c8bcf7cbddca75bf4e28ee7b98659 Mon Sep 17 00:00:00 2001
|
||||
From: Jasper St. Pierre <jstpierre@mecheye.net>
|
||||
Date: Tue, 23 Oct 2012 03:08:38 +0000
|
||||
Subject: MenuEditor: deal with the case of having no $XDG_MENU_PREFIX
|
||||
|
||||
From f7835d7dcd37b10f25e208581ec52919cf68e732 Mon Sep 17 00:00:00 2001
|
||||
From: Jasper St. Pierre <jstpierre@mecheye.net>
|
||||
Date: Sat, 17 Nov 2012 04:22:14 +0000
|
||||
Subject: Fix crashes when writing out files
|
||||
|
||||
From 10f611c074ae7b2ab0ec48ff3b8946c5f8e19970 Mon Sep 17 00:00:00 2001
|
||||
From: Jasper St. Pierre <jstpierre@mecheye.net>
|
||||
Date: Sat, 17 Nov 2012 04:26:14 +0000
|
||||
Subject: Use with statements for management
|
||||
|
||||
--- Alacarte/MenuEditor.py.orig Mon Mar 11 09:45:45 2013
|
||||
+++ Alacarte/MenuEditor.py Mon Mar 11 09:45:33 2013
|
||||
@@ -16,6 +16,7 @@
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
+import codecs
|
||||
import os
|
||||
import xml.dom.minidom
|
||||
import xml.parsers.expat
|
||||
@@ -23,7 +24,7 @@ from gi.repository import GMenu, GLib
|
||||
from Alacarte import util
|
||||
|
||||
class MenuEditor(object):
|
||||
- def __init__(self, name=os.environ['XDG_MENU_PREFIX'] + 'applications.menu'):
|
||||
+ def __init__(self, name=os.environ.get('XDG_MENU_PREFIX', '') + 'applications.menu'):
|
||||
self.name = name
|
||||
|
||||
self.tree = GMenu.Tree.new(name, GMenu.TreeFlags.SHOW_EMPTY|GMenu.TreeFlags.INCLUDE_EXCLUDED|GMenu.TreeFlags.INCLUDE_NODISPLAY|GMenu.TreeFlags.SHOW_ALL_SEPARATORS|GMenu.TreeFlags.SORT_DISPLAY_NAME)
|
||||
@@ -48,9 +49,8 @@ class MenuEditor(object):
|
||||
self.load()
|
||||
|
||||
def save(self):
|
||||
- fd = open(self.path, 'w')
|
||||
- fd.write(self.dom.toprettyxml())
|
||||
- fd.close()
|
||||
+ with codecs.open(self.path, 'w', 'utf8') as f:
|
||||
+ f.write(self.dom.toprettyxml())
|
||||
|
||||
def restoreToSystem(self):
|
||||
self.restoreTree(self.tree.get_root_directory())
|
||||
@@ -259,9 +259,8 @@ class MenuEditor(object):
|
||||
|
||||
contents, length = keyfile.to_data()
|
||||
|
||||
- f = open(out_path, 'w')
|
||||
- f.write(contents)
|
||||
- f.close()
|
||||
+ with codecs.open(out_path, 'w', 'utf8') as f:
|
||||
+ f.write(contents)
|
||||
|
||||
self.addItem(new_parent, file_id, dom)
|
||||
self.positionItem(new_parent, ('Item', file_id), before, after)
|
||||
@@ -400,9 +399,10 @@ class MenuEditor(object):
|
||||
|
||||
contents, length = keyfile.to_data()
|
||||
|
||||
- f = open(os.path.join(util.getUserItemPath(), file_id), 'w')
|
||||
- f.write(contents)
|
||||
- f.close()
|
||||
+ path = os.path.join(util.getUserItemPath(), file_id)
|
||||
+ with codecs.open(path, 'w', 'utf8') as f:
|
||||
+ f.write(contents)
|
||||
+
|
||||
return file_id
|
||||
|
||||
def writeMenu(self, menu, **kwargs):
|
||||
@@ -421,9 +421,9 @@ class MenuEditor(object):
|
||||
|
||||
contents, length = keyfile.to_data()
|
||||
|
||||
- f = open(os.path.join(util.getUserDirectoryPath(), file_id), 'w')
|
||||
- f.write(contents)
|
||||
- f.close()
|
||||
+ path = os.path.join(util.getUserDirectoryPath(), file_id)
|
||||
+ with codecs.open(path, 'w', 'utf8') as f:
|
||||
+ f.write(contents)
|
||||
return file_id
|
||||
|
||||
def getXmlNodesByName(self, name, element):
|
@ -1,6 +1,9 @@
|
||||
@comment $OpenBSD: PLIST,v 1.13 2013/03/11 09:37:03 ajacoutot Exp $
|
||||
@comment $OpenBSD: PLIST,v 1.14 2013/04/04 07:05:06 ajacoutot Exp $
|
||||
bin/alacarte
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/ItemEditor.py
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/ItemEditor.pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/ItemEditor.pyo
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/MainWindow.py
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/MainWindow.pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/MainWindow.pyo
|
||||
@ -18,6 +21,8 @@ lib/python${MODPY_VERSION}/site-packages/Alacarte/util.pyc
|
||||
lib/python${MODPY_VERSION}/site-packages/Alacarte/util.pyo
|
||||
share/alacarte/
|
||||
share/alacarte/alacarte.ui
|
||||
share/alacarte/directory-editor.ui
|
||||
share/alacarte/launcher-editor.ui
|
||||
share/applications/alacarte.desktop
|
||||
share/icons/hicolor/16x16/apps/alacarte.png
|
||||
share/icons/hicolor/22x22/apps/alacarte.png
|
||||
|
Loading…
Reference in New Issue
Block a user