Skip to content

Instantly share code, notes, and snippets.

@clintel
clintel / gist:1155906
Created August 19, 2011 02:40
Fenced code in bullet lists with GitHub-flavoured MarkDown??

Fenced code blocks inside ordered and unordered lists

  1. This is a numbered list.

  2. I'm going to include a fenced code block as part of this bullet:

    Code
    More Code
    
@trey
trey / git-commit-author-rewrite.md
Last active July 3, 2024 15:56
Change the email address for a git commit.

Change the email address for a git commit.

$ git commit --amend --author="Author Name <email@address.com>"

or

$ git commit --amend --reset-author
@rdump
rdump / kubectl-multi-version-brews.md
Last active April 4, 2024 15:20
kubectl multi-version brews (kubernetes-cli formula)

kubectl multi-version brews

Applicability

The instructions below apply to older versions of Homebrew which still provide switch capability.

For current Homebrew, you'll likely need to keep Versions around, and build locally. Here's my versions repository https://github.com/rdump/homebrew-versions

MacPorts is now keeping versioned installations available as well, by default.

@JoelPM
JoelPM / get_all_gcp_cluster_creds.sh
Created June 20, 2019 16:23
A small script for getting cluster credentials for all GKE clusters in the given GCP projects.
#/bin/sh
# Usage: ./get_all_gcp_cluster_creds.sh PROJECT1 [PROJECT2 ...]
for project in "$@"
do
echo "Getting cluster credentials for project $project"
gcloud container clusters list --project $project --format="table[no-heading](name,location)" | while read cluster location
do
gcloud container clusters get-credentials $cluster --project $project --region $location