随笔分类 - PowerShell
摘要:之前的快捷方式设置,是开始菜单找到程序,open file location,找到的快捷方式 C:\ProgramData\Microsoft\Windows\Start Menu\Programs\PowerShell\PowerShell 7 (x64).lnk 在Shortcut里面设置的管理
阅读全文
摘要:https://www.opentechguides.com/how-to/article/powershell/105/powershel-security-error.html Set-ExecutionPolicy Set-ExecutionPolicy -ExecutionPolicy Re
阅读全文
摘要:https://github.com/dahlbyk/posh-git#step-2-import-posh-git-from-your-powershell-profile $profile.AllUsersCurrentHost C:\Program Files\PowerShell\7-pre
阅读全文
摘要:获取路径 https://superuser.com/questions/1132288/windows-command-prompt-get-relocated-users-documents-folder 执行powershell命令 [Environment]::GetFolderPath('
阅读全文
摘要:一共需要3个文件,把这3个文件放在一个路径下 UTF8NoBOM.bat 这个文件是为了调用ps1 pwsh -file "%cd%\UTF8NoBOM.ps1" UTF8NoBOM.ps1 这个文件是为了导入自定义的module,使用自定义module中定义的Powershell函数 Import
阅读全文
摘要:https://docs.microsoft.com/en-us/powershell/gallery/getting-started https://www.powershellgallery.com/packages?q=PowerShell-Beautifier Get-PSRepositor
阅读全文
摘要:Auto Formatting PowerShell in Visual Studio Code 1.安装visual studio code 2.安装powershell extension 3.打开脚本文件 4.F1,然后输入format,找到format document的选项 但是这个用起来
阅读全文
摘要:在看https://github.com/PowerShell/PowerShell/releases的时候发现,已经发布了6.2.0的preview版本的情况下,还会继续发布6.1.3。 在ReadMe中,stable是6.1.3的版本。preview是6.2.0的版本。
阅读全文
摘要:Find-Package PM> Find-Package autofac https://docs.microsoft.com/en-us/nuget/tools/ps-ref-find-package Id Versions Description -- Autofac {4.9.0} Auto
阅读全文
摘要:https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_environment_variables?view=powershell-6 查看所有的环境变量 Get-ChildIt
阅读全文
摘要:How to See if Process is 32-bit or 64-bit in Windows 10 OPTION ONE To See if Process is 32-bit or 64-bit in Processes tab in Task Manager 1 Open Task
阅读全文
摘要:relevant command list Write-EventLog Write-EventLog -Source "SupperSocketService" -LogName "TestLog" -Message "test on 20180928" -EventId 3001 New-Eve
阅读全文
摘要:https://stackoverflow.com/questions/571429/powershell-web-requests-and-proxies
阅读全文
摘要:$PROFILE C:\Users\clu\Documents\PowerShell\Microsoft.PowerShell_profile.ps1 Import-Module 'C:\Users\clu\source\repos\GitHub\Other\posh-git\src\posh-gi
阅读全文
摘要:unapproved verbs WARNING: The names of some imported commands from the module 'todo' include unapproved verbs that might make them less discoverable.
阅读全文
摘要:https://superuser.com/questions/598163/powershell-touch-all-files-newer-than Powershell to use Unix touch seems silly to me. Instead, just use native
阅读全文
摘要:pwsh -file C:\Users\clu\source\repos\Edenred\LISA_5.0.0.0\LISA.ControlPanel\LISA.ControlPanel\bin\Release\en-US\Resources.ps1 C:\Users\clu\source\repo
阅读全文
摘要:https://blogs.technet.microsoft.com/heyscriptingguy/2014/07/15/keep-your-hands-clean-use-powershell-to-glue-strings-together/ powershell concat string
阅读全文
摘要:https://github.com/dahlbyk/posh-git/blob/master/src/Utils.ps1#L102 https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/
阅读全文
摘要:https://4sysops.com/archives/use-powershell-to-execute-an-exe/ https://stackoverflow.com/questions/714877/setting-windows-powershell-path-variable# 临时
阅读全文