This file contains hidden or 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/sh | |
ls_file() { | |
file_path="${1%%/}" | |
file_basename=$(basename "${file_path}") | |
ls_tree_opt= | |
if [ -d "${file_path}" ]; then | |
file_basename="${file_basename}/" | |
ls_tree_opt='-d' | |
fi |
This file contains hidden or 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 python3 | |
import argparse | |
import crypt | |
from crypt import METHOD_SHA256, METHOD_SHA512, METHOD_BLOWFISH, crypt, mksalt | |
from getpass import getpass | |
parser = argparse.ArgumentParser(description='Hash passwords') | |
parser.add_argument('-5', | |
action='store_const', |
This file contains hidden or 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
_ssh_known_hosts() | |
{ | |
local cur prev | |
_get_comp_words_by_ref cur prev | |
COMPREPLY=($(compgen -W 'find forget list' -- "${cur}")) | |
} | |
complete -F _ssh_known_hosts ssh-known-hosts |
This file contains hidden or 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/sh | |
CURL="curl -s --cacert ${HOME}/.local/etc/pki/ca/ca.crt" | |
REGISTRY='https://docker-registry.svc.internal.readonly.xyz/v2' | |
listImages() | |
{ | |
repo="$1" | |
tags=$(${CURL} "${REGISTRY}/${repo}/tags/list" | jq -r '.tags[]') |
OlderNewer