【发布时间】:2021-12-13 05:14:56
【问题描述】:
它说“批处理命令执行成功”,但命令行上没有打印任何内容。我错过了什么吗?我正在使用 Windows。
gimp-console-2.10.exe -idf --batch-interpreter python-fu-eval -b "import test; test.main(\"print this out\")"
文件名为test.py
#!/usr/bin/env python
from gimpfu import *
def main(mystring):
print(mystring)
【问题讨论】:
-
我不确定转义字符 \ 在 Windows 上是如何工作的。尝试将数字而不是
str传递给main。或者尝试将print(1)作为-b参数传递
标签: python cmd printing arguments gimp