哪种脚本语言是最好的?

哪种脚本语言是最好的?

问题描述:

要编写用于Linux平台中流程自动化的脚本,哪种脚本语言会更好? Shell脚本,Perl或Python还是其他内容?我是所有人的新手.所以,我只是在考虑去哪一个?

For writing scripts for process automisation in Linux platform, which scripting language will be better? Shell script, Perl or Python or is there anything else? I am new to all of them. So, am just thinking to which one to go for?

答案是:最适合的工作!

The answer is: Whatever best fits the job!

我的经验法则;

重击-用于可能需要for循环重复执行某些操作的简短脚本.

Bash - for a short script that might need a for loop to do something repetitively.

Perl -与某种文本处理或文件处理有关的任何事情,尤其是一次性的情况下.只是做一个肮脏的讨厌的Perl脚本并完成它

Perl - anything to do with some kind of text processing or file processing, especially if it's a one off. Just do a dirty nasty perl script and be done with it

Python -如果您需要再次执行此操作或非常类似的操作.然后,至少您有机会重用脚本.

Python - If it's something you might want to do again or something very like it. Then at least you have a chance of being able to reuse the script.