Skip to content

Commit

Permalink
games-util/pyfa: updated patch for live ebuild (bug #584624)
Browse files Browse the repository at this point in the history
Thanks to Martin McCourt.

Package-Manager: portage-2.3.0_rc1
  • Loading branch information
tetromino committed Jun 5, 2016
1 parent 27afc3d commit 4ffb77e
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 1 deletion.
33 changes: 33 additions & 0 deletions games-util/pyfa/files/pyfa-1.21.4-html-export-path.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
From a596f7f5398f613a607ecc91e06ea651806b8b63 Mon Sep 17 00:00:00 2001
From: Alexandre Rostovtsev <[email protected]>
Date: Mon, 16 Jul 2012 05:43:38 -0400
Subject: [PATCH] Export fits to home directory, not python sitedir

---
service/settings.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/service/settings.py b/service/settings.py
index cd1b33b..a883ca1 100644
--- a/service/settings.py
+++ b/service/settings.py
@@ -21,6 +21,7 @@ import cPickle
import os.path
import config
import urllib2
+import sys

class SettingsProvider():
BASE_PATH = os.path.join(config.savePath, "settings")
@@ -221,7 +222,7 @@ class HTMLExportSettings():
return cls._instance

def __init__(self):
- serviceHTMLExportDefaultSettings = {"enabled": False, "path": config.pyfaPath + os.sep + 'pyfaFits.html', "website": "null-sec.com", "minimal": False }
+ serviceHTMLExportDefaultSettings = {"enabled": False, "path": unicode(os.path.expanduser(os.path.join('~', 'pyfaFits.html')), sys.getfilesystemencoding()), "website": "null-sec.com", "minimal": False }
self.serviceHTMLExportSettings = SettingsProvider.getInstance().getSettings("pyfaServiceHTMLExportSettings", serviceHTMLExportDefaultSettings)

def getEnabled(self):
--
2.8.3

2 changes: 1 addition & 1 deletion games-util/pyfa/pyfa-9999.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ src_prepare() {
eapply "${FILESDIR}/${PN}-1.15.1-staticdata.patch"

# do not try to save exported html to python sitedir
eapply "${FILESDIR}/${PN}-1.20.2-html-export-path.patch"
eapply "${FILESDIR}/${PN}-1.21.4-html-export-path.patch"

# fix import path in the main script for systemwide installation
eapply "${FILESDIR}/${PN}-1.15.1-import-pyfa.patch"
Expand Down

0 comments on commit 4ffb77e

Please sign in to comment.