Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

In the Shell of my Shell study notes & quot

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

SHELL "#!":

In Shell, when the first two characters in a file are "#!" The kernel scans the rest of the line to see if there is a full path to the interpreter that can be used to execute the program

(any white space is skipped in the middle.) the kernel also scans to see if there is an option to pass to the interpreter, along with the rest of the command line.

For example:

The first line of the script / aa/bb/cc.sh is #! / bin/csh-f

So when the user executes / aa/bb/cc.sh, the kernel is explaining #! After this line, the csh is referenced as follows:

/ bin/csh-f / aa/bb/cc.sh

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report