Module in powershell
https://docs.microsoft.com/en-us/powershell/module/powershellget/install-module?view=powershell-6
Get-Module
~\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
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的更多相关文章
- PowerShell Notes
1. 概要 - PowerShell 是cmdlet(command-let)的指令集合,类似unix的bash. - IDE: Windows PowerShell ISE,不区分大小写,可以用命 ...
- 使用 PowerShell 自动化 CloudServices 发布
在软件的开发过程中,自动化的编译和部署能够带来很多的优势.如果可以通过一个脚本实现软件的自动化部署,那么就可以节省大量的时间去做其它事情. 下面介绍如何将云应用程序通过 PowerShell 自动发布 ...
- 使用PowerShell实时查看日志文件的变化
开发过程中,会有好多的日志输出到日志文件中了,每次看日志都需要打开,log文件,觉得麻烦 找了个省事的方法 使用PowerShell 使用命令:Get-Content D:\www\webapp1\L ...
- Jenkins入门之执行Powershell脚本
之前章节提到过powershell,如果需要构建复杂的任务时,使用cmd不是很方便(也可能是由于笔者不太熟悉cmd命令,这里见笑了),这时候powershell就派上用场了,这里并不详细介绍power ...
- 利用powershell进行windows日志分析
0x00 前言 Windows 中提供了 2 个分析事件日志的 PowerShell cmdlet:一个是Get-WinEvent,超级强大,但使用起来比较麻烦:另一个是Get-EventLog,使得 ...
- 设置powershell ExecutionPolicy
Get-ExecutionPolicy -List Set-ExecutionPolicy -Scope CurrentUser AllSigned Policies: Restricted/AllS ...
- Active Directory PowerShell模块收集AD信息
0x00 前言简介 Microsoft为Windows Server 2008 R2(以及更高版本)提供了多个Active Directory PowerShell cmdlet,这大大简化了以前需要 ...
- powershell如何查看以及设置环境变量
https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_environment ...
- PowerShell收发TCP消息包
PowerShell收发TCP消息包 https://www.cnblogs.com/fuhj02/archive/2012/10/16/2725609.html 在上篇文章中,我们在PSNet包中创 ...
随机推荐
- [SHELL]awk的用法举例
从初学awk到现在小有所成,非常感谢CUers的帮助,总结了下自己曾经遇到的问题和犯的错误,供初学者借鉴,因本人非计算机专业,对专业词汇可能有表述不对的地方,还请指正和补充! 1. awk '{cod ...
- POJ-1067取石子游戏,威佐夫博弈范例题/NYOJ-161,主要在于这个黄金公式~~
取石子游戏 Time Limit: 1000MS Memory Limit: 10000K Description 有两堆石子,数量任意,可以不同.游戏开始由两个人轮流取 ...
- 【链表】2017多校训练三 HDU 6058 Kanade's sum
acm.hdu.edu.cn/showproblem.php?pid=6058 [题意] 给定一个排列,计算 [思路] 计算排列A中每个数的贡献,即对于每个ai,计算有ni个区间满足ai是区间中的第k ...
- ubuntu 18.04取消自动锁屏以及设置键盘快捷锁屏
1:操作设置取消自动锁屏: setting-->power--->never 2: 设置自动锁屏快捷键: 快捷键设置一般在setting-->devices--->keybo ...
- POJ 1741 树上 点的 分治
题意就是求树上距离小于等于K的点对有多少个 n2的算法肯定不行,因为1W个点 这就需要分治.可以看09年漆子超的论文 本题用到的是关于点的分治. 一个重要的问题是,为了防止退化,所以每次都要找到树的重 ...
- jquery的ajax提交时“加载中”提示的处理方法
方法1:使用ajaxStart方法定义一个全局的“加载中...”提示 $(function(){ $("#loading").ajaxStart(function(){ ...
- 2017CodeM复赛
A.配对游戏(loj6191) 题目: https://loj.ac/problem/6191 分析: g[i][j]表示前i个位置尽可能合并,合并到最后右边剩下j个>,这样情况的概率 那么g[ ...
- 转: 使用valgrind检查内存问题
作者:gfree.wind@gmail.com 博客:blog.focus-linux.net linuxfocus.blog.chinaunix.net 本文的copyleft归gfree ...
- Myeclipse配置jad
下载地址:http://pan.baidu.com/s/1bnpMEuF 1.下载jad158g.win.zip 下载后解压.解压缩后将jad.exe拷贝到自定义的文件夹内:我这里用的是D:/jad/ ...
- 我被C++开发欺辱的岁月
前言 人被压迫了,为什么不斗争?——鲁迅 作为一个C#开发者,我经历了,也见证了很多同行饱受C++开发的歧视和欺辱. 而且,这种行为,现在依然持续的发生在C#开发者的身上,就目前为止,绝大部分C#开发 ...