Get the service principal for an application by app ID:
az ad sp list --filter "appId eq 'APP-GUID-HERE'" --query "[].objectId" -o tsv
| $duti = Get-Command "duti" -ErrorAction SilentlyContinue | |
| If ($Null -eq $duti) { | |
| throw "You must install 'duti' before running this script: brew install duti" | |
| } | |
| $duti = $duti.Source | |
| # $vscode = com.microsoft.VSCode | |
| $vscode = osascript -e "id of app `"Visual Studio Code`"" |
| git config -f ~/.gitconfig-personal user.name "Travis Illig" | |
| git config -f ~/.gitconfig-personal user.email "[email protected]" | |
| git config --global includeIf.gitdir:~/dev/tillig/.path ~/.gitconfig-personal | |
| git config --global includeIf.gitdir:~/dev/autofac/.path ~/.gitconfig-personal |
| #!/usr/local/bin/bash | |
| # <bitbar.title>Homebrew Updates</bitbar.title> | |
| # <bitbar.author>killercup</bitbar.author> | |
| # <bitbar.author.github>killercup</bitbar.author.github> | |
| # <bitbar.desc>List available updates from Homebrew (OS X)</bitbar.desc> | |
| # Modified by tillig to account for: | |
| # - brew 3 outputs brew update info to stderr | |
| # - putting a 🍺 emoji in the bar helps so it's not just a floating number | |
| exit_with_error() { |
| <# | |
| .SYNOPSIS | |
| Copies all the container images from one Azure Container Registry to another. | |
| .DESCRIPTION | |
| The az CLI offers the ability to import one container registry image into an | |
| ACR instance at a time. The artifact transfer mechanism that might be used | |
| to bulk copy container images is in preview and is difficult to set up. This | |
| script offers the best of all worlds - a bulk execution of the `az import` | |
| command to bring all the images from one ACR into another. |
| <# | |
| .SYNOPSIS | |
| Trims down the set of images in an Azure Container Registry. | |
| .DESCRIPTION | |
| There isn't really a retention policy setting on ACR such that the last X | |
| tags will be retained for a given repository. This script helps bridge that gap by | |
| going through all the repositories in an ACR, selecting the latest X tags to ignore, | |
| then removing tags that were created after that time. | |
| .PARAMETER Registry | |
| The name of the container registry with the images to prune. |
| <# | |
| .SYNOPSIS | |
| Creates a new Azure Container Registry. | |
| .DESCRIPTION | |
| Creates a new Azure Container Registry instance with customer managed key | |
| encryption enabled. Generates keys and identities for the registry. | |
| The location of the registry is inferred from the location of the specified | |
| Key Vault. This is because, when using customer managed keys, the Key Vault | |
| and the resource being encrypted must be in the same geographic location. |
| NAME="Travis Illig" | |
| EMAIL="[email protected]" | |
| USER="tillig" | |
| echo "MAC ENVIRIONMENT SETUP" | |
| echo "----------------------" | |
| echo "Sign in to Mac App Store before proceeding. Homebrew package restore may need to restore app store items." | |
| read -p "Press any key to continue… " -n1 -s | |
| echo "" |
| # From | |
| # https://medium.com/@katopz/how-to-install-specific-nodejs-version-c6e1cec8aa11 | |
| # See node versions | |
| brew search node | |
| # Remove the existing symlinks | |
| brew unlink node | |
| # Install node at specific version |
| [ | |
| { | |
| "caption": "Unit Test: NUnit to XUnit", | |
| "command": "nunit_to_xunit" | |
| }, | |
| { | |
| "caption": "Unit Test: NUnit to XUnit (Batch)", | |
| "command": "nunit_to_xunit_batch" | |
| } | |
| ] |