feat(core): 在线版ampy上传文件时首先获取工作路径
This commit is contained in:
6
common/templates/python/cwd.py
Normal file
6
common/templates/python/cwd.py
Normal file
@@ -0,0 +1,6 @@
|
||||
try:
|
||||
import os
|
||||
except ImportError:
|
||||
import uos as os
|
||||
|
||||
print(os.getcwd(), end='')
|
||||
@@ -20,7 +20,7 @@ def check_path(path):
|
||||
return 'file'
|
||||
else:
|
||||
return 'special file'
|
||||
except OSError:
|
||||
except Exception:
|
||||
return 'none'
|
||||
|
||||
def listdir(directory):
|
||||
|
||||
Reference in New Issue
Block a user