start dither post

This commit is contained in:
David Eisinger
2024-02-05 10:00:36 -05:00
parent ff15d58c41
commit 55c1010ce2
5 changed files with 6571 additions and 0 deletions

View File

@@ -3,6 +3,11 @@ title: "Email Photos to an S3 Bucket with AWS Lambda (with Cropping, in Ruby)"
date: 2021-04-07T00:00:00+00:00
draft: false
canonical_url: https://www.viget.com/articles/email-photos-to-an-s3-bucket-with-aws-lambda-with-cropping-in-ruby/
references:
- title: "Ditherpunk — The article I wish I had about monochrome image dithering — surma.dev"
url: https://surma.dev/things/ditherpunk/
date: 2024-02-05T14:50:25Z
file: surma-dev-e4sfuv.txt
---
In my annual search for holiday gifts, I came across this [digital photo

View File

@@ -0,0 +1,67 @@
---
title: "Encrypt and Dither Photos in Hugo"
date: 2024-02-05T09:47:45-05:00
draft: false
references:
- title: "Elliot Jay Stocks | 2023 in review"
url: https://elliotjaystocks.com/blog/2023-in-review
date: 2024-02-02T15:51:48Z
file: elliotjaystocks-com-fcit8u.txt
- title: "Encrypt and decrypt a file using SSH keys"
url: https://www.bjornjohansen.com/encrypt-file-using-ssh-key
date: 2024-02-05T14:50:24Z
file: www-bjornjohansen-com-hqud3x.txt
- title: "Ditherpunk — The article I wish I had about monochrome image dithering — surma.dev"
url: https://surma.dev/things/ditherpunk/
date: 2024-02-05T14:50:25Z
file: surma-dev-e4sfuv.txt
- title: "About the Solar Powered Website | LOW←TECH MAGAZINE"
url: https://solar.lowtechmagazine.com/about/the-solar-website/
date: 2024-02-05T14:50:28Z
file: solar-lowtechmagazine-com-vj7kk5.txt
---
* https://github.com/gohugoio/hugo/issues/8598
A more ambitions version of me would take a crack at adding this functionality to Hugo and opening a PR.
```sh
openssl rand -hex -out secret.key 32
```
---
```sh
openssl \
aes-256-cbc \
-in secretfile.txt \
-out secretfile.txt.enc \
-pass file:secret.key \
-iter 1000000
```
---
```ruby
Dir.glob("content/**/*.{jpg,jpeg,png}").each do |path|
`openssl aes-256-cbc -in #{path} -out #{path}.enc -pass file:secret.key -iter 1000000`
end
```
* https://gohugo.io/content-management/image-processing/#remote-resource
## Deleting images out of Git history
* https://stackoverflow.com/a/64563565
* https://github.com/newren/git-filter-repo
* https://formulae.brew.sh/formula/git-filter-repo
```ruby
Dir.glob("content/**/*.{jpg,jpeg,png}") do |path|
`git filter-repo --invert-paths --force --path #{path}`
end
```
***
I'm 41 years old, and this stuff still gives me a buzz like it did when I was 14.