forked from mirrors/ranger_udisk_menu
fix relative path in menu.py
This commit is contained in:
parent
d7f107c352
commit
1cd5befbf3
1 changed files with 3 additions and 2 deletions
|
@ -15,12 +15,13 @@ class mount(Command):
|
||||||
|
|
||||||
Show menu to mount and unmount
|
Show menu to mount and unmount
|
||||||
"""
|
"""
|
||||||
|
|
||||||
def execute(self):
|
def execute(self):
|
||||||
""" Show menu to mount and unmount """
|
""" Show menu to mount and unmount """
|
||||||
(f, p) = tempfile.mkstemp()
|
(f, p) = tempfile.mkstemp()
|
||||||
os.close(f)
|
os.close(f)
|
||||||
self.fm.execute_console(f"shell python3 {os.getcwd()}/menu.py {p}")
|
self.fm.execute_console(
|
||||||
|
f"shell python3 {os.path.dirname(os.path.realpath(__file__))}/menu.py {p}"
|
||||||
|
)
|
||||||
with open(p, 'r') as f:
|
with open(p, 'r') as f:
|
||||||
d = f.readline()
|
d = f.readline()
|
||||||
if os.path.exists(d):
|
if os.path.exists(d):
|
||||||
|
|
Loading…
Reference in a new issue