This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Set-ExplorerOptions -showHidenFilesFoldersDrives -showProtectedOSFiles -showFileExtensions | |
Enable-RemoteDesktop | |
cinst IIS-WebServerRole -source windowsfeatures | |
cinst IIS-HttpCompressionDynamic -source windowsfeatures | |
cinst IIS-ManagementScriptingTools -source windowsfeatures | |
cinst IIS-WindowsAuthentication -source windowsfeatures | |
cinst GoogleChrome | |
cinst Console2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cinst sublimetext3 | |
cinst BareTail |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')) | |
choco install gitextensions -y | |
choco install tortoisesvn -y | |
choco install baretail -y | |
choco install sublimetext3 -y | |
choco install googlechrome -y | |
choco install procexp -y | |
choco install Silverlight -y | |
choco install 7zip -y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$PSVersionTable.PSVersion | |
[Environment]::Is64BitProcess | |
(Get-Process -Id $PID).StartInfo.EnvironmentVariables["PROCESSOR_ARCHITECTURE"] | |
C:\Windows\SysNative\WindowsPowerShell\v1.0\powershell.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select-string -Path *.lnk -Pattern '(c|C):[- \w.\\_]+\.jpg' -AllMatches | % { $_.Matches } | % { $_.Value } | copy-item -destination .\copy\$_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Function Add-LocalUserAccount{ | |
param ( | |
[parameter(Mandatory=$true)] | |
[string[]]$ComputerNames=$env:computername, | |
[parameter(Mandatory=$true)] | |
[string[]]$UserNames, | |
[parameter(Mandatory=$true)] | |
[string]$Password | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$context = New-AzureStorageContext -StorageAccountName foobar -StorageAccountKey gsdfgdsfGSDFGsdFGSdfgSDFGSDFGsdfg | |
$imeis = Select-String -Path .\foo.txt -Pattern "." | ForEach-Object {$_.Line} | |
$dateResultMap = @{} | |
#echo "xxx70" | |
$MAXSIZE = 150 | |
for($i=0; $i -lt $imeis.Count; $i++){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; + = shift | |
; ^ = ctrl | |
; # = windows | |
; ! = alt | |
::pw1::password1 | |
; #v::Run "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe" | |
^+Down::send ^{End} | |
^+Up::send ^{Home} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git log --branches --remotes --tags --graph --oneline --decorate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
write-host "Apply the certName cert" -ForegroundColor Green | |
$cert = dir cert:\localmachine\my | where-object{$_.subject -like "*.certName.*"} | |
if(!$cert){ | |
$cert = dir cert:\localmachine\webhosting | where-object{$_.subject -like "*.certName.*"} | |
} | |
if(!$cert){ | |
throw [System.Exception] "No ssl cert found that matches the search '*.certName.*'" | |
} | |
new-item "IIS:\SslBindings\0.0.0.0!443" -Value $cert |
OlderNewer