Skip to content

Conversation

@xly0805
Copy link

@xly0805 xly0805 commented Oct 30, 2019

DONE:

  • 用户输入客户发来文件夹路径 找出路径下的资产文件并获取文件名,文件路径,资产类型信息

  • 用户输入要存入资产的项目路径 并检查对应路径是否为空 非空备份文件 然后复制到对应路径

  • 将此次传入进来的资产信息存入json文件
    TODO:

  • 用户选择要导出给客户的资产名 找到最新版文件 按客户格式存储到outbox路径

  • 想把整个代码搬到maya里 加上给资产文件截图功能

  • 加上UI

Copy link
Contributor

@sol87 sol87 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

整体还是很不错的! 加油。

assets_data, input_dir = get_input_data()
show_dir = input("请选择项目路径>>>>>>>>>>>")
# r'C:\Users\geyij\Desktop\new\AssetIO\example\project\TDC'
show_name = show_dir.rpartition('\\')[-1]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

show_name = os.path.basename(show_dir)

:param directory:
:return:
"""
if not os.path.exists(directory):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

os.path.isdir(directory)会优于 os.path.exists

input_dir = input("请选择客户文件路径>>>>>>>>>>")
# r'C:\Users\geyij\Desktop\new\AssetIO\example\project\Inbox\20191001'
input_data = {}
for a, b, c in os.walk(input_dir):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不要使用 a,b,c 作为变量名称

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for path, dirs, files in os.walk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants