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
--- | |
- name: execute playbook_debug.yml | |
import_playbook: playbook_debug.yml | |
vars: | |
hosts: ':&~f\d.*-imap00\d$' |
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
function fzf_maillog(){ | |
logfile=$1 | |
cat ${logfile}|fzf -i -e --preview="grep -F \$(awk '{print \$6}' {+f}) ${logfile}" --preview-window=up:50%:wrap -m --bind ctrl-t:toggle-all | |
} |
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 | |
file=$1 | |
iconv --from-code=ISO-8859-1 --to-code=UTF-8 $file | \ | |
mlr --icsv --ifs ';' --omd cat| \ | |
fzf -e -i --preview="echo {}|tr '|' '\n'" -m --bind ctrl-o:select-all | \ | |
awk -F'|' '{sum += $9}END{print sum}' | |
# requirements: mlr (miller), fzf (fuzzy finder), iconv (convert codesets) |
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 ruby | |
require 'openssl' | |
require "json" | |
fullchain = ARGV[0] | |
cmd = %(openssl crl2pkcs7 -nocrl -certfile #{fullchain} | openssl pkcs7 -print_certs) | |
# if problems with empty lines occur, use this: | |
# cmd = %(openssl crl2pkcs7 -nocrl -certfile #{fullchain} | openssl pkcs7 -print_certs | perl -pe 's/^\n$//mg; s/-----END CERTIFICATE-----/-----END CERTIFICATE-----\n/' ) |
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/ruby | |
require "json"; | |
class Ress | |
attr_reader :eload, :feedin, :gridcharge, :ppv, :soc, :userpower, :measure_time, :token_valid_to, :token, :now_s, :now_str | |
def initialize(sn, u, p) |