Would Python make a good substitute for the Windows command-line/batch scripts?

后端 未结 12 872
醉酒成梦
醉酒成梦 2021-01-30 07:21

I\'ve got some experience with Bash, which I don\'t mind, but now that I\'m doing a lot of Windows development I\'m needing to do basic stuff/write basic scripts using the Wind

12条回答
  •  走了就别回头了
    2021-01-30 07:52

    Python is certainly well suited to that. If you're going down that road, you might also want to investigate SCons which is a build system itself built with Python. The cool thing is the build scripts are actually full-blown Python scripts themselves, so you can do anything in the build script that you could otherwise do in Python. It makes make look pretty anemic in comparison.

    Upon rereading your question, I should note that SCons is more suited to building software projects than to writing system maintenance scripts. But I wouldn't hesitate to recommend Python to you in any case.

提交回复
热议问题