Spaces:
Running
Running
PhoenixStormJr
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ def greet(command):
|
|
6 |
commandList = command.split(' ')
|
7 |
if(commandList[0] == "cd"):
|
8 |
os.chdir(commandList[1])
|
9 |
-
output = subprocess.run([pwd], stdout=subprocess.PIPE).stdout.decode('utf-8')
|
10 |
return f"{command}: \n {output}"
|
11 |
else:
|
12 |
output = subprocess.run(commandList, stdout=subprocess.PIPE).stdout.decode('utf-8')
|
|
|
6 |
commandList = command.split(' ')
|
7 |
if(commandList[0] == "cd"):
|
8 |
os.chdir(commandList[1])
|
9 |
+
output = subprocess.run(['pwd'], stdout=subprocess.PIPE).stdout.decode('utf-8')
|
10 |
return f"{command}: \n {output}"
|
11 |
else:
|
12 |
output = subprocess.run(commandList, stdout=subprocess.PIPE).stdout.decode('utf-8')
|