使用Remove-Module -Name Functions2 只是移除當前會話的模塊
並且Import-Module -Name Functions2與 Remove-Module -Name Functions2是相對應的,只有先import才能remove,不然會提示找不到模塊
使用get-module -ListAvailable是得到當前PC上所有的模塊
使用get-module是得到當前會話下的模塊
創建一個測試模塊很簡單
官方的例子:
如果你只是想快速的創建一個測試模塊,那就在C:\Users\names\Documents\WindowsPowerShell\Modules下創建一個空文件夾,在文件夾中創建一個后綴為.psm1的文檔
