Skip to content

Instantly share code, notes, and snippets.

@CyberHippo
CyberHippo / tmux.conf
Created March 4, 2022 14:14 — forked from spicycode/tmux.conf
The best and greatest tmux.conf ever
# 0 is too far from ` ;)
set -g base-index 1
# Automatically set window title
set-window-option -g automatic-rename on
set-option -g set-titles on
#set -g default-terminal screen-256color
set -g status-keys vi
set -g history-limit 10000
@CyberHippo
CyberHippo / gcr-purge.py
Created August 14, 2020 10:08
Python script to purge from Google Cloud Registry all untagged digests created before a certain date with the option to keep some untagged digests.
#!/usr/bin/python3
import argparse
import json
from subprocess import PIPE, Popen
from datetime import datetime, timezone
def get_images(registry):
process = Popen("gcloud container images list --repository=%s --format=json" % registry,
shell=True, stdout=PIPE, stderr=PIPE)