Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
# trivially sync git + submodules
submodule="${1}"
check_sneaky_paths "${submodule}"
# jump into password store dir now and commit (or not)
cd "${PREFIX}" || exit 1
git commit -am "gitsync $(date +%s)"
@arrjay
arrjay / gpg.bash
Created November 22, 2023 16:43
pass extension for gpg shenanigans
#!/bin/bash
# Created by argbash-init v2.10.0
# Rearrange the order of options below according to what you would like to see in the help message.
# ARG_OPTIONAL_SINGLE([id],[u],[gpg/pass id to use],[])
# ARG_OPTIONAL_SINGLE([name],[N],[gpg identity name for creation],[])
# ARG_OPTIONAL_SINGLE([email],[E],[gpg identity email for creation],[])
# ARG_OPTIONAL_SINGLE([ciphertype],[C],[gpg key cipher type (ecc/rsa)],[ecc])
# ARG_OPTIONAL_SINGLE([passlength],[L],[password length for generated passphrase],[32])
# ARG_OPTIONAL_BOOLEAN([nosym],[X],[exclude symbols in generated password],[off])
# this file goes in $HOME/.config/systemd/user
[Unit]
Description=beepy backlight controller
[Service]
Type=simple
# adjust this path to where you wrote the script out
ExecStart=/home/rj/bin/noarch/beepy-bl.sh
Restart=on-failure
@arrjay
arrjay / pull_zyx_poe.expect
Created July 24, 2023 02:58
expect script to munge Zyxel poe status from telnet into a json blob
#!/usr/bin/env expect
#exp_internal 1
#log_user 1
# hi! we're hand-crafting JSON, fuckit
puts "{"
log_user 0
set timeout 5
set host [lindex $argv 0]
@arrjay
arrjay / ssh.bash
Created July 10, 2023 22:12
password store extension for ssh wrangles
#!/bin/bash
# Created by argbash-init v2.10.0
# Rearrange the order of options below according to what you would like to see in the help message.
# ARG_OPTIONAL_SINGLE([host],[h],[actual host to connect to],[])
# ARG_OPTIONAL_SINGLE([port],[p],[port number for SSH daemon on actual host],[22])
# ARG_OPTIONAL_SINGLE([labelname],[l],[value of SSH matching label for ProxyCommand use],[])
# ARG_OPTIONAL_SINGLE([agentpath],[A],[path to SSH agent for ProxyCommand use (IdentityAgent)],[])
# ARG_OPTIONAL_SINGLE([exec],[c],[for exec/run/shell, execute command string],[$SHELL -i])
# ARG_OPTIONAL_SINGLE([item],[i],[password item to use],[])
Terminal ready [235/1869]
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 6.1.21-v7l+ (dom@buildbot) (arm-linux-gnueabihf-gcc-8 (Ubuntu/Linaro 8.4.0-3ubuntu1) 8.4.0, GNU ld (GNU Binutils for Ubuntu) 2.34)
#1642 SMP Mon Apr 3 17:22:30 BST 2023
[ 0.000000] CPU: ARMv7 Processor [410fd083] revision 3 (ARMv7), cr=30c5383d
[ 0.000000] CPU: div instructions available: patching division code
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, PI
@arrjay
arrjay / output.log
Created July 2, 2023 20:46
rock64 okay boot
U-Boot TPL 2022.07-armbian (May 27 2023 - 19:26:49)
LPDDR3, 800MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS=1 Die BW=16 Sizeot from BOOTROM
Returning to boot ROM...
U-Boot SPL 2022.07-armbian (May 27 2023 - 19:26:49 +0000)
Trying to boot from MMC1
@arrjay
arrjay / output.log
Created July 2, 2023 20:36
rock64 boot failure
U-Boot TPL 2022.07-armbian (May 27 2023 - 19:26:49)
LPDDR3, 800MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS=1 Die BW=16 Size=1024MB
Trying to boot from BOOTROM
Returning to boot ROM...
U-Boot SPL 2022.07-armbian (May 27 2023 - 19:26:49 +0000)
@arrjay
arrjay / output.txt
Created June 17, 2023 02:11
booting openbsd on the ESPRESSObin
TIM-1.0
mv_ddr-devel-g541616b DDR3 16b 1GB 2CS
WTMI-devel-18.12.1-a3e1c67
WTMI: system early-init
CPU VDD voltage default value: 1.108V
Setting clocks: CPU 600 MHz, DDR 600 MHz
CZ.NIC's Armada 3720 Secure Firmware v2022.06.11-9-g604f8f5 (Jun 16 2023 21:46:09)
Running on ESPRESSObin
NOTICE: Booting Trusted Firmware
NOTICE: BL1: v2.9(release):v2.9.0-178-gbf1e58e73
@arrjay
arrjay / gitconfig
Last active May 20, 2023 16:34
transient ssh agent proxy, loading keys from pass, *and* ssh configuration to trivialize it
[url "s.github.com.arrjay.github.com"]
insteadof = github.com
insteadof = https://github.com/
insteadof = git@github.com