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 | |
set -eu -o pipefail | |
function main() { | |
AUTHORIZED_KEYS=${1:-~/.ssh/authorized_keys} | |
while read -r p; do | |
echo -e "\n$p ->" | |
echo "$p" | awk '{ print $2 }' | # Only the actual key data without prefix or comments | |
base64 -d | # decode as base64 | |
sha256sum | # SHA256 hash (returns hex) |
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 | |
# | |
# /etc/rc.d/init.d/node_exporter | |
# | |
# Prometheus node exporter | |
# | |
# description: Prometheus node exporter | |
# processname: node_exporter | |
# Source function library. |
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
# Customize BASH PS1 prompt to show current GIT repository and branch. | |
# by Mike Stewart - http://MediaDoneRight.com | |
# SETUP CONSTANTS | |
# Bunch-o-predefined colors. Makes reading code easier than escape sequences. | |
# I don't remember where I found this. o_O | |
# Reset | |
Color_Off="\[\033[0m\]" # Text Reset |
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 | |
W_PATH="$(xclip -selection clipboard -o)" | |
U_PATH="$(echo "$W_PATH" | sed -e 's/\\/\//g' -e 's/A:/\/media\/accounts/g')" | |
nautilus "$U_PATH" |