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
# https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html | |
$dlurl = "https://awscli.amazonaws.com/AWSCLIV2.msi" | |
$installerPath = Join-Path $env:TEMP (Split-Path $dlurl -Leaf) | |
$ProgressPreference = 'SilentlyContinue' | |
Invoke-WebRequest $dlurl -OutFile $installerPath | |
Start-Process -FilePath msiexec -Args "/i $installerPath /passive" -Verb RunAs -Wait | |
Remove-Item $installerPath | |
$env:Path += ";C:\Program Files\Amazon\AWSCLIV2" |
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
$dlurl = 'https://7-zip.org/' + (Invoke-WebRequest -UseBasicParsing -Uri 'https://7-zip.org/' | Select-Object -ExpandProperty Links | Where-Object {($_.outerHTML -match 'Download')-and ($_.href -like "a/*") -and ($_.href -like "*-x64.exe")} | Select-Object -First 1 | Select-Object -ExpandProperty href) | |
# modified to work without IE | |
# above code from: https://perplexity.nl/windows-powershell/installing-or-updating-7-zip-using-powershell/ | |
$installerPath = Join-Path $env:TEMP (Split-Path $dlurl -Leaf) | |
Invoke-WebRequest $dlurl -OutFile $installerPath | |
Start-Process -FilePath $installerPath -Args "/S" -Verb RunAs -Wait | |
Remove-Item $installerPath |
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
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 | |
# Common Windows Server Setup (code downloaded from another Gist) | |
Invoke-Expression ((Invoke-WebRequest "https://gist.githubusercontent.com/dansmith65/010e9ae85a09ce9855206b7558a67b37/raw/WindowsServerSetup.ps1").Content) | |
# Open FileMaker-specific ports | |
# NOTE: you might want to add 80 and 443 to the list of ports below, but I haven't needed to in my testing on AWS yet | |
New-NetFirewallRule -DisplayName "FileMaker Server" -Direction Inbound -Action Allow -Protocol TCP -LocalPort 5003,16000 | |
# Install FileMaker Server: CONFIG |
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
# https://docs.aws.amazon.com/cli/latest/userguide/awscli-install-windows.html | |
$dlurl = "https://s3.amazonaws.com/aws-cli/AWSCLI64PY3.msi" | |
$installerPath = Join-Path $env:TEMP (Split-Path $dlurl -Leaf) | |
$ProgressPreference = 'SilentlyContinue' | |
Invoke-WebRequest $dlurl -OutFile $installerPath | |
Start-Process -FilePath msiexec -Args "/i $installerPath /passive" -Verb RunAs -Wait | |
Remove-Item $installerPath | |
$env:Path += ";C:\Program Files\Amazon\AWSCLI\bin" |
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
OnExit, ExitSub | |
;AUTO LOAD SCRIPTS | |
;============================================================================== | |
Loop, AutoHotkey.d\*.ahk | |
{ | |
OutputVarPID = | |
Run, %A_AhkPath% "%A_LoopFileFullPath%", , , OutputVarPID | |
CloseProcessesOnExit = %CloseProcessesOnExit%%OutputVarPID%`n | |
} |
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
# Install Google Chrome (code downloaded from another Gist) | |
Invoke-Expression ((Invoke-WebRequest "https://gist.githubusercontent.com/dansmith65/4c012304ed96596dbbcad8e4a15f7583/raw/Install-GoogleChrome.ps1").Content) | |
# Install Nodepad++ (code downloaded from another Gist) | |
Invoke-Expression ((Invoke-WebRequest "https://gist.githubusercontent.com/dansmith65/a862f301fce553b26db9689ad0f87b6a/raw/Install-NotepadPlusPlus.ps1").Content) | |
# Install 7-zip (code downloaded from another Gist) | |
Invoke-Expression ((Invoke-WebRequest "https://gist.githubusercontent.com/dansmith65/7dd950f183af5f5deaf9650f2ad3226c/raw/Install-7zip.ps1").Content) | |
# Install AWS CLI (code downloaded from another Gist) |
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
$InstallerPath = Join-Path $env:TEMP "chrome_installer.exe"; Invoke-WebRequest "https://dl.google.com/chrome/install/latest/chrome_installer.exe" -OutFile $InstallerPath; Start-Process -FilePath $InstallerPath -Args "/silent /install" -Verb RunAs -Wait; Remove-Item $InstallerPath |
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
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 | |
$homeUrl = 'https://notepad-plus-plus.org' | |
$res = Invoke-WebRequest -UseBasicParsing $homeUrl | |
if ($res.StatusCode -ne 200) {throw ("status code to getDownloadUrl was not 200: "+$res.StatusCode)} | |
$tempUrl = ($res.Links | Where-Object {$_.outerHTML -like "*Current Version *"})[0].href | |
if ($tempUrl.StartsWith("/")) { $tempUrl = "$homeUrl$tempUrl" } | |
$res = Invoke-WebRequest -UseBasicParsing $tempUrl | |
if ($res.StatusCode -ne 200) {throw ("status code to getDownloadUrl was not 200: "+$res.StatusCode)} | |
$dlUrl = ($res.Links | Where-Object {$_.href -like "*x64.exe"})[0].href | |
if ($dlUrl.StartsWith("/")) { $dlUrl = "$homeUrl$dlUrl" } |
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
# Get-TodoistBackup.ps1 | |
# Created By: Daniel Smith [email protected] | |
# | |
# Download the latest backup from Todoist | |
# | |
$token = "" | |
# get list of backups from Todoist |
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
/** | |
* ===================================== | |
* VerifyVariablesNotEmpty ( nameList ) | |
* | |
* RETURNS: | |
* True (1) if a locally scoped $variable matching each value in nameList | |
* is not empty; False (0) otherwise. | |
* | |
* PARAMETERS: | |
* nameList: A return-limited list of names to check. Names do not need to |
NewerOlder