Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/activity.py
diff options
context:
space:
mode:
authorC. Scott Ananian <cscott@laptop.org>2007-12-11 22:35:15 (GMT)
committer C. Scott Ananian <cscott@laptop.org>2007-12-11 22:35:15 (GMT)
commit6b9a427f10ebf8b233c1640532ba7b5a9ae71315 (patch)
tree8b5a13c25cb91950266eed4458e5192eac0a327f /activity.py
parent387995e07fa348d292b07597b1b6239395db201f (diff)
Fix pippy sub-shell invocation, which I broke by naming the standard library 'pippy'.
Diffstat (limited to 'activity.py')
-rw-r--r--activity.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/activity.py b/activity.py
index f0602e1..fd7af00 100644
--- a/activity.py
+++ b/activity.py
@@ -211,7 +211,8 @@ class PippyActivity(Activity):
start, end = self.text_buffer.get_bounds()
text = self.text_buffer.get_text(start, end)
- file = open('/tmp/pippy.py', 'w', 0)
+ pippy_app_name = '%s/tmp/pippy_app.py' % self.get_activity_root()
+ file = open(pippy_app_name, 'w', 0)
for line in text:
file.write(line)
file.close()
@@ -219,10 +220,9 @@ class PippyActivity(Activity):
self._pid = self._vte.fork_command \
(command="/bin/sh",
argv=["/bin/sh", "-c",
- "python /tmp/pippy.py; sleep 1"],
+ "python %s; sleep 1" % pippy_app_name],
envv=["PYTHONPATH=%s/library" % get_bundle_path()],
- directory=get_bundle_path(),
- lastlog=False, utmp=False, wtmp=False)
+ directory=get_bundle_path())
def stopbutton_cb(self, button):
os.kill(self._pid, SIGTERM)