脚本和shell之间有什么区别? [英] What's the difference between script and shell?

查看:120
本文介绍了脚本和shell之间有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

为了更好地理解这一点,我希望有一个非常强大的基础,这些基础将会起作用。我的一些问题可能看起来很愚蠢,但我只是寻求平等。





我说的是你如何定义这些词?

To understand this well, I would like to have very strong foundations that will work their way up. Some of my questions might appear foolish, but I am just seeking equanimity.


I am speaking as how you would define these words?

推荐答案

为了简单起见, 脚本 shell 执行的命令。在大多数Linux环境中,终端只是shell解释器的名称。 Shell解释您传递脚本的命令。然后执行它们以极快的速度



大多数情况下,例如,你执行一个命令来安装一个包,

To keep things simple, "script is the command that shell executes". In most of the Linux environments, terminal is just the name given to a shell interpreter. Shell interprets the commands, that you pass a script. Then executes them "in a blazing fast speed".

Most of the times, for example, you execute a command to install a package,
sudo apt-get install package-name



这只是脚本。它在任何环境中都没有意义,但 shell ; 终端 Shell 将逐个解释该命令。然后它将构建一个要执行的命令。在这种情况下,它是安装包。 Shell脚本有时也称为BASH脚本。



请阅读以下有用资源,以了解有关这些主题的更多信息。



http:// askubuntu.com/questions/111144/are-terminal-and-shell-the-same [ ^ ]

http://superuser.com/questions/144666/what-is-the-difference-between-shell-console-and-terminal [< a href =http://superuser.com/questions/144666/what-is-the-difference-between-shell-console-and-terminaltarget =_ blanktitle =New Window> ^ ]

https://en.wikipedia.org/wiki/Bash_(Unix_shell) [ ^ ]


This is just the script. It has no meaning in any environment, but shell; the terminal. Shell would interpret the command, one by one. Then it would build a command to be executed. In this case, it is an "install the package". Shell script is sometimes also called BASH script.

Please read the following helpful resources to learn more on these topics.

http://askubuntu.com/questions/111144/are-terminal-and-shell-the-same[^]
http://superuser.com/questions/144666/what-is-the-difference-between-shell-console-and-terminal[^]
https://en.wikipedia.org/wiki/Bash_(Unix_shell)[^]


这篇关于脚本和shell之间有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆