···11+---
22+title: Full website Update
33+date: 2023-01-12
44+---
55+## New Website
66+77+### Saait
88+99+I got a little bit tired of the old site, so changed it to something more ~websit-y~
1010+1111+Now its made using [Saait](https://git.codemadness.org/saait/) and what a treat it is.
1212+1313+More Updates coming.
1414+
+11
posts/001-bash_blogger.md
···11+---
22+title: Creating posts with bash and git from terminal
33+date: 2023-01-13
44+---
55+Since updating this website with Saait, I have decided to create a tool to streamline page creation from the terminal.
66+77+Inspired by [bash_blog](https://github.com/j0m/bash_blog) and [bashblog](https://github.com/cfenollosa/bashblog) especially bash was chosen.
88+99+It is goofy, not as practical as I would think, but neat nevertheless.
1010+1111+Source at my [git](https://git.technoduck.me) repo.
+32
posts/002-services.md
···11+---
22+title: List of Services running on the server
33+date: 2023-01-13
44+---
55+66+### This blog
77+88+Self explanatory. This is my [website](/), my little corner of the internet.
99+1010+### Email
1111+1212+Self hosted email server using Dovecot + Posfix.
1313+1414+### Git
1515+1616+[forgejo](https://git.technoduck.me) instance for my personal projects.
1717+1818+### Etebase
1919+2020+An [Etebase](https://etebase.technoduck.me) instance for syncing my tasks, to-do's and contacts between devices.
2121+2222+### Grocy
2323+2424+[Grocy](https://grocy.technoduck.me) instance for keeping track of food and grocery lists ( and literally anything else in your house including batteris in devices? ) it's really cool give it a check.
2525+2626+### Wiki
2727+2828+A [wikimedia](https://wiki.cold-metal.technoduck.me) instance running for a friend for categorizing all the lore of the world that is being created for a soft fiction story.
2929+3030+### WIP
3131+3232+Work in progress of a [website](https://wip.technoduck.me) I am making for a photographer/photography business.
+41
posts/003-led_hoop.md
···11+---
22+title: PCB LED hoop earring project
33+date: 2024-01-02
44+---
55+## LED Hoops
66+77+### What?
88+99+First, a blog post by [mitxela](https://mitxela.com) came upon my eyes, and piqued my interest.
1010+1111+Inspired by the [industrial piercing](https://mitxela.com/projects/scaffold) and the electronics that went into it, I though if other pieces of jewelry can be made with electronics (they can, it was specifically a question if my measly hands could craft them).
1212+1313+Since for the first time, I didn't want to experiment with absolute microscopic sizes, I decided that a 4 cm hoop was an adequate project to attempt.
1414+1515+
1616+1717+An Attiny 24/44/84A can be used, I went with a -M variant, since it is slightly larger then the -MM variant, by a whole mm, which I assume will be easier to solder.
1818+1919+Placing them all in a nice hoop looking pcb, we obtain this:
2020+2121+
2222+2323+The test version comes with ISP pins for debugging and programming the chip when it's already installed.
2424+2525+0603 LED's were chosen for the same reason, they are small enough to be not that noticeable, but large enough to be not an incredible pain to work with.
2626+2727+### Why??
2828+2929+It looked and sounded fun, my only previous projects related to PCB production before this was edition a split [Sweep](https://github.com/davidphilipbarr/Sweep) keyboard.
3030+3131+And so I did.
3232+3333+### Cool. What now?
3434+3535+You can take your chance and go to [the git repository](https://git.technoduck.me/technoduck/led_hoop) for the project, `git pull`, and try your own luck.
3636+3737+3838+3939+4040+Batteries not included.
4141+
+16
posts/004-pantheon.md
···11+---
22+title: Pantheon
33+date: 2024-03-03
44+---
55+# WATCH PANTHEON
66+77+## I DO NOT CARE WHAT DAY IT IS
88+99+### HERE'S YOUR PLAN
1010+1111+1. Wake up.
1212+2. Open whatever device you watch things on.
1313+3. Obtain, legally or illegaly, by any means necessary, 2 (two) seasons of Pantheon, created by Craig Silverstein based on short stories by Ken Liu.
1414+4. Binge the 2 sesons in a single night (it is feasable I checked)
1515+1616+Thank you for coming to my Ted Talk.
+36
posts/005-regenesis.md
···11+---
22+title: Full website Re-Update
33+date: 2024-08-29
44+---
55+## New Website?
66+77+### Rust
88+99+The time has come and another re-write is upon us.
1010+1111+This time inspied by [this article](https://blog.transrights.art/blogs/2024_Screw-Frameworks-New-Site-2),
1212+[theprimeagen](https://www.youtube.com/watch?v=rcZSOLAI1lM), and everpresent desire to rewrite everything in Rust,
1313+the new website is a complete rewrite using rust and adjacent techniques.
1414+1515+Using only
1616+```
1717+[dependencies]
1818+askama = { version = "0.12.1", features = ["with-axum"] }
1919+askama_axum = "0.4.0"
2020+axum = "0.7.5"
2121+comrak = "0.27.0"
2222+markdown-parser = "0.1.2"
2323+rand = "0.8.5"
2424+serde = { version = "1.0.209", features = ["derive"] }
2525+serde_yaml = "0.9.34"
2626+tokio = { version = "1.39.3", features = ["macros", "rt-multi-thread"] }
2727+tower-http = { version = "0.5.2", features = ["fs"] }
2828+```
2929+3030+as dependancies in the end we get a clean~ish, 2.8MB executable.
3131+3232+All markdown compilation gets done every time page is loaded, which is sub-optimal,
3333+But reading time for all posts is non-significant compared to other loading times.
3434+3535+And voila, there is the new post.
3636+
+40
src/blog_entries.rs
···11+use std::{fs::read_dir, path::Path};
22+33+use markdown_parser::*;
44+55+use crate::structs::{BlogInfo, IndexPostEntry};
66+77+pub fn get_blog_entry_markdown(path:&String) -> Result<Markdown,Error> {
88+ let location = format!("posts/{path}.md").to_string();
99+ read_file(Path::new(&location))
1010+}
1111+1212+pub fn get_all_markdowns() -> Vec<IndexPostEntry> {
1313+ let mut post_vec:Vec<IndexPostEntry> = Vec::new();
1414+ let mr_dir_iter = match read_dir("posts/") {
1515+ Ok(iter) => iter,
1616+ Err(err) => panic!("could ls files, err {err}")
1717+ };
1818+1919+ for entry in mr_dir_iter {
2020+ if let Ok(entry) = entry {
2121+2222+ let filename = entry.file_name().into_string().unwrap().split(".").collect::<Vec<_>>()[0].to_string();
2323+2424+2525+ let front_matter_string = get_blog_entry_markdown(&filename).unwrap();
2626+2727+ let front_matter:BlogInfo = serde_yaml::from_str(&front_matter_string.front_matter()).unwrap();
2828+2929+ post_vec.push(IndexPostEntry{
3030+ title: front_matter.title,
3131+ date: front_matter.date,
3232+ path: format!("/blog/{filename}"),
3333+ });
3434+3535+ }
3636+ }
3737+ post_vec.sort_by_key(|e| e.path.clone() );
3838+ post_vec.reverse();
3939+ post_vec
4040+}
···11+use rand::Rng;
22+33+pub fn get_quote() -> &'static str {
44+ let vs = vec![
55+"Silliness and tomfooler are afoot, and who am I to stop it.",
66+"Low entropy self replicating phenomenon that generates a binding force called compassion.",
77+"I was born in the late Holocene and I've seen some shit.",
88+"If there's a deal meant for you, any wild place on earth will do.",
99+"Live long and prosper.",
1010+"Prometheus they say brought gods fire down to man and we've caught it tamed it trained it since our history began.",
1111+"Oh, so, wenn PETER PARKER eine Reizüberflutung hat, dann sind es \"Spidey-Sinne\", aber wenn ich es tue, ICH HABE AUTISM.",
1212+"Guess we are doing Rust now",
1313+];
1414+ let mut rng = rand::thread_rng();
1515+ match vs.get(rng.gen_range(0..vs.len())) {
1616+ Some(quote) => quote,
1717+ None => "You have caught me off guard.",
1818+ }
1919+}