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
on run {input, parameters} | |
do shell script "open /Applications/Preview.app" | |
set importFromPhoneText to "Import from iGeoff" | |
tell application "System Events" to tell process "Preview" | |
set frontmost to true | |
delay 2 | |
click (menu item 1 where its name starts with importFromPhoneText) of menu 1 of menu bar item "File" of menu bar 1 |
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
#!/usr/bin/env pwsh | |
# ./move-ios-media.ps1 '/Users/hudgeo/Desktop/camera' | |
# ./move-ios-media.ps1 '/Users/hudgeo/Desktop/camera', '/Users/hudgeo/Desktop/iGeoffCamera' | |
param( [Parameter(Mandatory=$true)] [string[]] $directories ) | |
Write-Host "Using Powershell $($PSVersionTable.PSEdition) v $($PSVersionTable.PSVersion)" | |
$logFile = "$HOME/Scripts/move-ios-media.txt" | |
$picsRoot = "$HOME/Pictures/By Year"; $vidRoot = "$HOME/Movies/By Year" | |
$preview = $false; $autoOpenPathFinder = $true |
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
param([switch]$all, [int]$top) | |
Push-Location $PSScriptRoot | |
# Eureka takes longest. start first in new window, takes a while, lots of continual Eureka output | |
"Launching Eureka startup in another process" | |
Invoke-Expression 'cmd /c start powershell -NoProfile -Command { .\eureka-start.ps1 }' | |
"" | |
# Start Spring Cloud Config server for Producer and Consumer configuration. |
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
$image = "hyness/spring-cloud-config-server" | |
$name = "river-cloud-config" | |
$attempts = 0 | |
$startSuccess = $false | |
$maxAttempts = 3 | |
$configPath = (Get-Item (Join-Path $PSScriptRoot "../../river-flow-config/local")).FullName.Replace("\", "/") | |
do { |
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
param ([switch]$mount) | |
$image = "mysql" | |
$containerName = "river-mysql" | |
$hostPort = 3306 | |
$containerPort = 3306 | |
$attempts = 0 | |
$maxAttempts = 3 | |
$startSuccess = $false |
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
$image = "rabbitmq" | |
$containerName = "river-queue" | |
$attempts = 0 | |
$maxAttempts = 3 | |
$startSuccess = $false | |
# https://stackoverflow.com/questions/54217076/docker-port-bind-fails-why-a-permission-denied | |
do { |
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
$image = "redis" | |
$containerName = "river-cache" | |
$hostPort = 6379 | |
$containerPort = 6379 | |
$attempts = 0 | |
$maxAttempts = 3 | |
$startSuccess = $false | |
do { |
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
$eurekaLocalPath = "C:\Projects\eureka" | |
# JAVA_HOME must be set for maven build | |
# needs to be set to a JDK dir not JRE otherwise: | |
# No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? | |
$env:JAVA_HOME = "C:\Program Files\Java\jdk1.8.0_191" | |
if (!(Test-Path $eurekaLocalPath)) { | |
"Cloning Eureka" | |
git clone https://github.com/spring-cloud-samples/eureka.git $eurekaLocalPath |
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
$eurekaUrl = "http://localhost:8761/eureka/apps/" | |
"Checking Eureka status..." | |
$attempts = 0 | |
$maxAttempts = 20 | |
do { | |
Start-Sleep ($attempts + 2) | |
$status = -1 |
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
param([switch]$all, [int]$top) | |
Push-Location $PSScriptRoot | |
# Eureka takes longest. start first in new window, takes a while, lots of continual Eureka output | |
"Launching Eureka startup in another process" | |
Invoke-Expression 'cmd /c start powershell -NoProfile -Command { .\eureka-start.ps1 }' | |
"" | |
# Start Spring Cloud Config server for Producer and Consumer configuration. |