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
put.your.domain.here { | |
@local { | |
file | |
not path / | |
} | |
log { | |
output file /var/log/caddy/mastodon.log | |
} |
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
# install sd-webui on CUDA enabled linux distro | |
export URL_TO_MODEL=https://huggingface.co/....there_are_lots_of_options_here....ckpt | |
ln -fs /usr/share/zoneinfo/Etc/GMT /etc/localtime | |
dpkg-reconfigure --frontend noninteractive tzdata | |
adduser sd --disabled-password --gecos "" | |
apt update -y | |
apt install -y software-properties-common | |
add-apt-repository -y ppa:deadsnakes/ppa | |
apt update -y |
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
# notice the cheating technique of selecting all, | |
# copying to clipboard, then reading the | |
# clipboard back via JavaScript(!!) | |
# there's also some stuff to rip content out of | |
# shadow roots which can be useful if a page | |
# is doing dynamic rendering | |
# | |
# MIT licensed, (c) 2022 Peter Cooper | |
require 'ferrum' |
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
# Scan screencast videos for (sensitive) text | |
# MIT licensed – Copyright (c) 2022 Peter Cooper – @cooperx86 | |
# Quite a bit of the code comes from | |
# https://github.com/RhetTbull/osxphotos/blob/master/osxphotos/text_detection.py | |
# which is itself MIT licensed and copyright (c) 2019-2021 Rhet Turnbull | |
import tempfile | |
import subprocess |
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
source "https://rubygems.org" | |
gemspec |
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 'eventmachine' | |
class FingerServer < EM::Connection | |
def receive_data(data) | |
data.strip! | |
if data =~ /\A\w+\z/ && data.length <= 100 | |
puts "Got a request for user #{data}" |
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
mlr --csv filter 'strptime($pushed_at,"%Y-%m-%d %H:%M:%S %Z") > strptime("2021-09-01", "%Y-%m-%d") && $stargazers >= 2' then sort -nr stargazers list.csv > goodlist.csv |
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
lines = File.readlines("3.txt") | |
def dl(lines, m) | |
12.times do |pos| | |
rs = lines.map(&:chars).map { |s| s[pos] }.tally | |
.sort_by { |k, v| [v * m, k.ord * m] } | |
lines.select! { |l| l[pos] == rs[1][0] } | |
break lines.first.to_i(2) if lines.size == 1 | |
end | |
end |
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 | |
# | |
# Backs up my entire website, in case Tumblr or CloudApp goes down someday. | |
# Last time I ran this, it took 18 minutes. | |
# | |
wget \ | |
--mirror `# turns on recursion and timestamping, basically says we want to "mirror" the whole site` \ | |
--convert-links `# after download, convert all links to point to localhost` \ |
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
I'm trying to migrate from my own spreadsheet to Letterboxd without | |
much success so far.. so this is just a total mess of a list, | |
but broadly in order watched this year. | |
Favourites have been all the Gasper Noe ones (Enter The Void, | |
Irreversible, etc.) | |
Only Tenet, The Father and A Quiet Place 2 were at the cinema 🙁 | |
Some are rewatches (e.g. 2001, 1408, Alien) due to getting them |