日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

能运行shell吗_terminal, shell, bash, zsh

發(fā)布時間:2023/12/20 编程问答 39 豆豆
生活随笔 收集整理的這篇文章主要介紹了 能运行shell吗_terminal, shell, bash, zsh 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

##秋天的第一杯奶茶梗?

Terminal:

shell運行在里面。A terminal refers to a wrapper program that runs a shell.

Shell:

The shell is the program that actually processes commands and returns outputs.

Most shells also manage foreground and background processes, command history, and command-line editing. These features are standard in bash, the most common shell in modern Linux systems.

shell 是一個命令行解釋器,是人機交互的端口。

用戶輸入一條命令,shell 就立即解釋執(zhí)行一條(interactive)。

  • 編譯器: 輸入A語言的源代碼,輸出是B語言;如C++,被編譯成匯編語言;
  • 解釋器:輸入A語言的源代碼,直接執(zhí)行A語言;可以理解為“編譯器+機器,編譯器把輸入語言編譯成中間語言,然后機器執(zhí)行。

Command: 在黑框框里輸入的命令--> command-line interface (CLI);

GUI: 在屏幕上戳戳-->graphical user interface (GUI)

shell類型

常見的 shell 解釋器有 sh、bash這兩種,其他有 ksh、csh 和 zsh。

一門語言有解釋器,就可以作為 shell 使用。比如Java 有第三方解釋器 Jshell,PHP有 PHP Shell。windows有 windows shell( command interpreter)

Bash

Bash 是最常見的 shell。
喚醒 bash shell 時方式不同,加載不同文件:

login shell 加載 ~/.bash_profile

non-login shell 加載 ~/.bashrc 。

zsh

zsh兼容 bash,還有自動補全等功能

zsh 的配置文件~/.zshrc

配置 shell

shell 在啟動時都會去找配置文件,然后運行它。

你安裝的一些腳本,如果想讓它能夠全局運行,就需要在配置文件中設(shè)置路徑。

有過設(shè)置路徑后還是不管用的經(jīng)歷嗎?多半是因為把配置寫在了錯誤的配置文件里。* 應(yīng)該在配置shell(最常見的是配置默認命令)之前,使用 echo $SHELL,確認自己現(xiàn)在用的是什么shell后,再去編輯對應(yīng)的配置文件 *

Console:

能輸入命令的界面. 比如Chrome中的console可以輸入JavaScript;

Shell也是種console但只能輸入Linux command

Python & IPython:

Python is a high-level general-purpose programming language.

IPython is an interactive shell that is built with python.

IDE:

An integrated development environment(IDE) is software for building applications that combines common developer tools into a single graphical user interface (GUI)

  • Python IDE: Pycharm, Jupyter, Spider

PyCharm is an IDE developed by JetBrain, the team responsible for one of the most famous Java IDE.

Anaconda is a package manager.

總結(jié)

以上是生活随笔為你收集整理的能运行shell吗_terminal, shell, bash, zsh的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。