Skip to content

Instantly share code, notes, and snippets.

View domingoladron's full-sized avatar
💭
alive

Chris Laine domingoladron

💭
alive
View GitHub Profile
@domingoladron
domingoladron / get-and-delete-ecr-repository.sh
Created August 5, 2019 09:10
get-and-delete-ecr-repository.sh
echo "Retrieving the first ECR Repository"
aws ecr describe-repositories --query "repositories[0]"
echo "Retrieving the first ECR Repository's name as a variable in BASH"
REPOSITORY_NAME=$(aws ecr describe-repositories --query "repositories[0].[repositoryName]" --output text)
echo "Retrieved Name for first repository in my ECR Registry: $REPOSITORY_NAME"
echo "Deleting repository..."
# NOTE: THIS IS A DELETE COMMAND. DON'T UNCOMMENT THE LINE BELOW AND RUN IT
@domingoladron
domingoladron / get-and-delete-ecr-repository-response.sh
Last active August 5, 2019 09:12
get-and-delete-ecr-repository-response.sh
$ ./get-and-delete-ecr-repo.sh
Retrieving the first ECR Repository
{
"repositoryArn": "arn:aws:ecr:us-west-2:xxxxxxxxxxxx:repository/temporary/slow-cooker-api",
"registryId": "xxxxxxxxxxxx",
"repositoryName": "temporary/slow-cooker-api",
"repositoryUri": "xxxxxxxxxxxx.dkr.ecr.us-west-2.amazonaws.com/temporary/slow-cooker-api",
"createdAt": 1564993261.0
}
Retrieving the first ECR Repository's name as a variable in BASH
@domingoladron
domingoladron / dotnet-tool-roundhouse-install
Created August 19, 2019 06:24
dotnet-tool-roundhouse-install
dotnet tool install -g dotnet-roundhouse
@domingoladron
domingoladron / dotnet-tool-roundhouse-install-response
Created August 19, 2019 06:27
dotnet-tool-roundhouse-install-response
You can invoke the tool using the following command: rh
Tool 'dotnet-roundhouse' (version '1.1.0') was successfully installed.
@domingoladron
domingoladron / dotnet-tool-install-sample
Created August 19, 2019 06:34
dotnet-tool-install-sample
dotnet tool install -g <NugetPackageName>
@domingoladron
domingoladron / dotnet-tool-create-csproj-example
Created August 20, 2019 08:34
dotnet-tool-create-csproj-example
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.2</TargetFramework>
<PackAsTool>true</PackAsTool>
<ToolCommandName>sayhowdy</ToolCommandName>
<PackageOutputPath>./nupkg</PackageOutputPath>
<AssemblyName>SayHowdy</AssemblyName>
<RootNamespace>SayHowdy</RootNamespace>
@domingoladron
domingoladron / dotnet-tool-create-program-cs
Created August 20, 2019 08:40
dotnet-tool-create-program-cs
using System;
using System.Reflection;
//namespace matches what is in the csproj attributes
namespace SayHowdy
{
class Program
{
static void Main(string[] args)
{
@domingoladron
domingoladron / dotnet-tool-create-package
Created August 20, 2019 08:43
dotnet-tool-create-package
D:\Dev\github\DotNetTool.SayHowdy>dotnet pack
Microsoft (R) Build Engine version 16.2.32702+c4012a063 for .NET Core
Copyright (C) Microsoft Corporation. All rights reserved.
Restore completed in 36.42 ms for D:\Dev\github\DotNetTool.SayHowdy\DotNetTool.SayHowdy.csproj.
DotNetTool.SayHowdy -> D:\Dev\github\DotNetTool.SayHowdy\bin\Debug\netcoreapp2.2\SayHowdy.dll
DotNetTool.SayHowdy -> D:\Dev\github\DotNetTool.SayHowdy\bin\Debug\netcoreapp2.2\SayHowdy.dll
DotNetTool.SayHowdy -> D:\Dev\github\DotNetTool.SayHowdy\bin\Debug\netcoreapp2.2\publish\
Successfully created package 'D:\Dev\github\DotNetTool.SayHowdy\nupkg\SayHowdy.1.0.0.nupkg'.
@domingoladron
domingoladron / dotnet-tool-install-tool
Created August 20, 2019 08:46
dotnet-tool-install-tool
D:\Dev\github\DotNetTool.SayHowdy>dotnet tool install --global --add-source ./nupkg sayhowdy
You can invoke the tool using the following command: sayhowdy
Tool 'sayhowdy' (version '1.0.0') was successfully installed.
@domingoladron
domingoladron / dotnet-tool-run-tool
Created August 20, 2019 08:48
dotnet-tool-run-tool
D:\Dev\github\DotNetTool.SayHowdy>sayhowdy Medium
Howdy, Medium