PowerShell 7.2.6:在 GNU 中使用 Linux 和 Windows 命令
當然,在使用時 免費和開放的操作系統 基於 GNU / Linux的, 終端的使用通常比 私有和封閉的操作系統例如 Windows和macOS. 但是,兩個終端都存在,並且每個終端都有各自的終端和外殼。
而且,正如許多人已經從不同的來源知道的那樣, Microsoft微軟 有時間賭他 開源 和它的許多收斂 GNU/Linux 上的 Windows 應用程序. 作為其中之一, PowerShell的. 這是一個現代命令 shell,包含其他流行 shell 的最佳功能。 一,與其他只接受和返回文本不同,接受和返回對象。

而且,在開始這篇文章之前 “PowerShell 7.2.6” 和使用 Linux 和 Windows 命令 超過一個 GNU發行版,我們建議探索以下 相關內容,在閱讀結束時:

在 GNU/Linux 發行版上使用 Windows PowerShell 7.2.6
在 GNU/Linux 上安裝 PowerShell
利用 PowerShell的關於我現在的 GNU / Linux操作系統,叫 奇蹟 (MX Linux 的轉版)我們安裝它 版本 7.2.6 中的“.deb 文件”,使用以下命令:
sudo dpkg -i ./Descargas/powershell_7.2.6-1.deb_amd64.deb

在 GNU 上使用 PowerShell 的 Linux 和 Windows 命令示例
首先,開始 GNU/Linux 上的 PowerShell 我們必須執行 pwsh 命令,如下圖所示:

準備好了! 從這裡我們可以執行幾乎任何 支持 Linux Bash Shell 命令和 Windows PowerShell,如下圖所示,執行以下 5 個命令命令:
在目錄之間移動
Set-Location ./Descargas/cd /home/sysadmin

列出路線內容
Get-ChildItem -Path /home/sysadminls -l /home/sysadmin
請求我們所在的路線
Get-Locationpwd

使用搜索模式查找文件
Get-ChildItem '/opt/milagros/scripts/' -Filter '*milagros*' -Recursefind /opt/milagros/scripts/ -name *milagros*

創建、複製、移動和刪除文件和文件夾
在窗戶上
New-Item -ItemType File FileUbunlog.txtNew-Item -ItemType Directory 'DirUbunlog'Copy-Item ./FileUbunlog.txt ./FileUbunlog2.txtMove-Item ./FileUbunlog2.txt ./FileUbunlog3.txtRemove-Item *.txt

在Linux上
mkdir dirtemptouch filetempmv ./filetemp ./dirtemp/cp ./dirtemp/filetemp ./dirtemp/filetemp2rm ./dirtemp/filetemp2

至 有關 PowerShell 及其命令的更多信息, 你可以從以下開始 官方鏈接. 或者另一個,它位於 GitHub上.


總結
總之,我們希望初步了解一下 “PowerShell 7.2.6” 和使用 Linux 和 Windows 命令 超過一個 GNU發行版,繼續為許多人提供價值和知識,在管理技術領域 GNU/Linux 終端,在 GNU/Linux 或 Windows 發行版上。
如果你喜歡內容, 評論並分享. 請記住,訪問我們的開始 «現場»,除了官方渠道 Telegram 了解更多新聞、教程和 Linux 更新。 西方 組,以獲取有關今天主題的更多信息。

