https://docs.microsoft.com/en-us/powershell/module/powershellget/install-module?view=powershell-6

https://docs.microsoft.com/en-us/powershell/developer/module/understanding-a-windows-powershell-module

Get-Module

https://docs.microsoft.com/en-us/powershell/module/Microsoft.PowerShell.Core/Get-Module?view=powershell-6

~\Desktop> Get-Module

ModuleType Version Name ExportedCommands
---------- ------- ---- ----------------
Manifest 6.1.0.0 Microsoft.PowerShell.Management {Add-Content, Clear-Content, Clear-Item, Clear-ItemProperty...}
Manifest 6.1.0.0 Microsoft.PowerShell.Utility {Add-Member, Add-Type, Clear-Variable, Compare-Object...}
Script 1.0.0.0 posh-git {Add-PoshGitToProfile, Expand-GitCommand, Format-GitBranchName, Get-GitBranchStatusColor...}
Script 2.0.0 PSReadLine {Get-PSReadLineKeyHandler, Get-PSReadLineOption, Remove-PSReadLineKeyHandler, Set-PSReadLineKeyHandler...}

Find-Module

https://docs.microsoft.com/en-us/powershell/module/PowerShellGet/Find-Module?view=powershell-6

Finds modules from an online gallery that match specified criteria.

Install-Module

https://docs.microsoft.com/en-us/powershell/module/PowerShellGet/Install-Module?view=powershell-6

Downloads one or more modules from an online gallery, and installs them on the local computer.

需要显式指定代理

Install-Module -Name WindowsCompatibility -Proxy "http://domain:port"

Import-Module

https://docs.microsoft.com/en-us/powershell/module/Microsoft.PowerShell.Core/Import-Module?view=powershell-6

Adds modules to the current session.

The Import-Module cmdlet adds one or more modules to the current session.

The modules that you import must be installed on the local computer or a remote computer.

Import-Module imports a module only into the current session.

To import the module into all sessions, add an Import-Module command to your PowerShell profile.

For more information about profiles, see about_Profiles.

Update-Module

Update-Module -Name PowerShellGet -Proxy "http://domain:port" -Verbose -MaximumVersion 2.1.2 -Force

$PROFILE

C:\Users\clu\Documents\PowerShell\Microsoft.PowerShell_profile.ps1

文件内容

Import-Module 'C:\Users\clu\source\repos\GitHub\Other\posh-git\src\posh-git.psd1'
Import-Module 'C:\Users\clu\source\repos\GitHub\Other\PowerShell\build.psm1'

Module in powershell的更多相关文章

  1. PowerShell Notes

    1.  概要 - PowerShell 是cmdlet(command-let)的指令集合,类似unix的bash. - IDE: Windows PowerShell ISE,不区分大小写,可以用命 ...

  2. 使用 PowerShell 自动化 CloudServices 发布

    在软件的开发过程中,自动化的编译和部署能够带来很多的优势.如果可以通过一个脚本实现软件的自动化部署,那么就可以节省大量的时间去做其它事情. 下面介绍如何将云应用程序通过 PowerShell 自动发布 ...

  3. 使用PowerShell实时查看日志文件的变化

    开发过程中,会有好多的日志输出到日志文件中了,每次看日志都需要打开,log文件,觉得麻烦 找了个省事的方法 使用PowerShell 使用命令:Get-Content D:\www\webapp1\L ...

  4. Jenkins入门之执行Powershell脚本

    之前章节提到过powershell,如果需要构建复杂的任务时,使用cmd不是很方便(也可能是由于笔者不太熟悉cmd命令,这里见笑了),这时候powershell就派上用场了,这里并不详细介绍power ...

  5. 利用powershell进行windows日志分析

    0x00 前言 Windows 中提供了 2 个分析事件日志的 PowerShell cmdlet:一个是Get-WinEvent,超级强大,但使用起来比较麻烦:另一个是Get-EventLog,使得 ...

  6. 设置powershell ExecutionPolicy

    Get-ExecutionPolicy -List Set-ExecutionPolicy -Scope CurrentUser AllSigned Policies: Restricted/AllS ...

  7. Active Directory PowerShell模块收集AD信息

    0x00 前言简介 Microsoft为Windows Server 2008 R2(以及更高版本)提供了多个Active Directory PowerShell cmdlet,这大大简化了以前需要 ...

  8. powershell如何查看以及设置环境变量

    https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_environment ...

  9. PowerShell收发TCP消息包

    PowerShell收发TCP消息包 https://www.cnblogs.com/fuhj02/archive/2012/10/16/2725609.html 在上篇文章中,我们在PSNet包中创 ...

随机推荐

  1. ArrayLIst练习之获取满足要求的元素

    ArrayListTest2.java import java.util.ArrayList; /* * 1.给定一个字符串数组;{"张三丰","宋远桥",&q ...

  2. 大数据学习——hive数仓DML和DDL操作

    1 创建一个分区表 create table t_partition001(ip string,duration int) partitioned by(country string) row for ...

  3. Spring Boot Reactive Streams

    1 响应式编程规范 目标:provide a standard for asynchronous stream processing with non-blocking backpressure ht ...

  4. [codevs2495]水叮当的舞步

    [codevs2495]水叮当的舞步 试题描述 水叮当得到了一块五颜六色的格子形地毯作为生日礼物,更加特别的是,地毯上格子的颜色还能随着踩踏而改变. 为了讨好她的偶像虹猫,水叮当决定在地毯上跳一支轻盈 ...

  5. 假面舞会(codevs 1800)

    题目描述 Description 一年一度的假面舞会又开始了,栋栋也兴致勃勃的参加了今年的舞会. 今年的面具都是主办方特别定制的.每个参加舞会的人都可以在入场时选择 一个自己喜欢的面具.每个面具都有一 ...

  6. linux下库文件的编程

    编程到了一定的时候,总喜欢追求新的东西.将代码尽量模块化就是我的追求之一,原来只是满足于将代码从单文件中分离,通过头文件和实现文件实现模块化,后来发现最好的方法是打包成库文件,使用更加方便.尽管在li ...

  7. POJ 2438 哈密顿回路

    Children's Dining Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 4730   Accepted: 754 ...

  8. topcoder 649 DIV2

    8 A:模拟 9:B:终于看懂题目... 题意:最多分解K次 每分钟一个数可以分解成两个数 或者-1: 关键字:DP,记忆花搜索. DP[I][J]=min(dp[i][j],1+max(dp[ii] ...

  9. Windows如何在cmd命令行中查看、修改、删除与添加、设置环境变量

    首先明确一点: 所有的在cmd命令行下对环境变量的修改只对当前窗口有效,不是永久性的修改.也就是说当关闭此cmd命令行窗口后,将不再起作用.永久性修改环境变量的方法有两种:一种是直接修改注册表(此种方 ...

  10. http返回写入问题

    1.服务器返回写的数据全是通过response对象,response.getWriter().print(msg);这样就返回写出数据了. 比如: logger.info("encrypte ...