Use subprocess instead of os.system.
os.system wasn't working on Ubuntu? I like the syntax of Popen better anyways.
This commit is contained in:
@@ -4,6 +4,7 @@ import time
|
|||||||
import os
|
import os
|
||||||
from uuid import uuid4
|
from uuid import uuid4
|
||||||
from tempfile import NamedTemporaryFile
|
from tempfile import NamedTemporaryFile
|
||||||
|
from subprocess import Popen
|
||||||
|
|
||||||
import praw.errors
|
import praw.errors
|
||||||
|
|
||||||
@@ -265,7 +266,7 @@ class SubmissionPage(BasePage):
|
|||||||
return
|
return
|
||||||
|
|
||||||
curses.endwin()
|
curses.endwin()
|
||||||
os.system(editor + ' ' + fp.name)
|
Popen([editor, fp.name]).wait()
|
||||||
curses.doupdate()
|
curses.doupdate()
|
||||||
|
|
||||||
fp.seek(0)
|
fp.seek(0)
|
||||||
|
|||||||
Reference in New Issue
Block a user