Claude Code 2.1.27 occasionally drops long-running chats from /resume even though
the per-session .jsonl files still exist. This script rescans a given ~/.claude/ projects/<project> directory, re-derives every entry’s metadata, and rewrites
sessions-index.json so /resume can list every session again.
Create image in host shell:
mkdir -p /var/lib/vz/images/102/
qemu-img create -f raw /var/lib/vz/images/102/win11recovery.raw 32G
In PVE monitor:
device_add nec-usb-xhci,addr=0x1B,bus=pci.1,id=xhci
# alternatively use qemu-xhci which should be faster (not tested)
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
| // ==UserScript== | |
| // @name Auto Wayback | |
| // @description Automatically save the page you're on to the Internet Archive's Wayback Machine. | |
| // @version 1.0.0 | |
| // | |
| // @match https://wsj.com/* | |
| // @match https://cnn.com/* | |
| // @match https://*.cnn.com/* | |
| // @match https://theguardian.com/* | |
| // @match https://snopes.com/* |
After a whole day of struggles, I finally managed to convert a wordnet3 infused dictionary (that you can get here: http://eb.lv/) from .mobi format to .dict format (suitable for KOReader).
I tested this process on Arch Linux, so your process might be different from mine.
- Download the KindleUnpack program from here: https://github.com/kevinhendricks/KindleUnpack
- Extract the .zip
- Start the GUI with python 2 (IMPORTANT: python3 doesn't work!):
python2 KindleUnpack.pyw - Select the .mobi file as input and choose your output directory
- (optional) I don't know if it is necessary, but select ePub Output type: Auto-Detect
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
| ### | |
| ### [2023-06-19] UPDATE: Just tried to use my instructions again on a fresh install and it failed in a number of places. | |
| ###. Not sure if I'll update this gist (though I realise it seems to still have some traffic), but here's a list of | |
| ###. things to watch out for: | |
| ### - Check out the `nix-darwin` instructions, as they have changed. | |
| ### - There's a home manager gotcha https://github.com/nix-community/home-manager/issues/4026 | |
| ### | |
| # I found some good resources but they seem to do a bit too much (maybe from a time when there were more bugs). | |
| # So here's a minimal Gist which worked for me as an install on a new M1 Pro. |
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/bash | |
| ssh2append() { | |
| ssh -G "$@" | sed -n 's/^hostname /Host /p' | |
| comm -23 <(ssh -G "$@" 2>/dev/null | sort) <(ssh -G . 2>/dev/null | sort) | sed 's/^/ /' | |
| # This loop+if is for remote command, -N, -W as -G lacks support | |
| while getopts '1246AaCfGgKkMNnqsTtVvXxYyB:b:c:D:E:e:F:I:i:J:L:l:m:O:o:p:Q:R:S:W:w:' opt; do | |
| #shellcheck disable=SC2254 | |
| case "$opt" in |
Here is a work around to automate OCSP stapling on Opnsense with HAproxy plugin.
Hope it helps :)
I created a script based on acme.sh's haproxy deploy hook.
As /tmp is emptied on reboot you need to regenerate ocsp files on startup so I put the script as a startup script: /usr/local/etc/rc.syshook.d/start/99-ocsp (symoblic links in rc.syshook.d don't work).
#!/bin/sh NewerOlder