openpgp4fpr:65242c0e477f13ccb2b0120e722a501d95610dd5
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 bash | |
# Registry name to transfer to | |
REGISTRY="${1:?Registry name is required as argument}" | |
# Check that this actually looks like a registry host and not an image URL. | |
if [[ $REGISTRY == *"/"* ]]; then | |
echo "\"${REGISTRY}\" looks like an image location, not the registry host. Exiting." | |
exit 1 | |
fi |
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
# I was having problems with the standard setup, this is to remind me what was needed: | |
#debug=yes # Uncomment to debug | |
#verbose=yes # Uncomment for verbose output | |
daemon=600 # Checking every 10 minutes instead of 5 | |
syslog=yes | |
pid=/var/run/ddclient/ddclient.pid | |
ssl=yes |
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
# Put this in .bash_profile to have ssh-agent running in a cli environment | |
# From https://stackoverflow.com/a/18915067 | |
# and https://web.archive.org/web/20210506080335/https://mah.everybody.org/docs/ssh | |
SSH_ENV="$HOME/.ssh/agent-environment" | |
function start_agent { | |
echo "Initialising new SSH agent..." | |
/usr/bin/ssh-agent | sed 's/^echo/#echo/' > "${SSH_ENV}" | |
echo succeeded |
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
## Path section | |
# Set $PATH if ~/.local/bin exist | |
if [ -d "$HOME/.local/bin" ]; then | |
export PATH=$HOME/.local/bin:$PATH | |
fi | |
eval "$(starship init zsh)" | |
function set_win_title(){ | |
echo -ne "\033]0; $USER@$HOST:${PWD/$HOME/~} \007" | |
} |
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
# From: https://stackoverflow.com/a/246128 | |
# Basic script path information | |
SOURCE=${BASH_SOURCE[0]} | |
while [ -L "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink | |
K1_BIN_DIR=$( cd -P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd ) | |
SOURCE=$(readlink "$SOURCE") | |
[[ $SOURCE != /* ]] && SOURCE=$K1_BIN_DIR/$SOURCE # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located | |
done |
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
# To awscli is configured and connects to an actual account | |
aws sts get-caller-identity |
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
package utils | |
import ( | |
"regexp" | |
"strings" | |
) | |
// SnakeCaseToCamelCase | |
// This will convert snake case to camelCased | |
// @return camelCased string, number of parts |
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
#!/bin/bash | |
# Infinite loop | |
for (( ; ; )) | |
do | |
for arg in "${@}" | |
do | |
if [ ! -e "${arg}" ] | |
then | |
echo "'${arg}' is gone" |
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
Computer Information: | |
Manufacturer: Unknown | |
Model: Unknown | |
Form Factor: Desktop | |
No Touch Input Detected | |
Processor Information: | |
CPU Vendor: AuthenticAMD | |
CPU Brand: AMD Ryzen 5 5600X 6-Core Processor | |
CPU Family: 0x19 |
NewerOlder