Skip to content

Instantly share code, notes, and snippets.

@joseph0x45
joseph0x45 / service.service
Created May 9, 2026 17:26
Service file template
[Unit]
Description=test
After=network.target
Wants=network.target
[Service]
Type=simple
User=joseph
@joseph0x45
joseph0x45 / blabla.md
Last active April 7, 2026 20:46
Explaining my Go setup to LLMs

Here is the structure of my project.

.
โ”œโ”€โ”€ go.mod
โ”œโ”€โ”€ go.sum
โ”œโ”€โ”€ internal
โ”‚ย ย  โ”œโ”€โ”€ buildinfo
โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ buildinfo.go
โ”‚ย ย  โ”œโ”€โ”€ cli
โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ cli.go
@joseph0x45
joseph0x45 / pwa.go
Last active April 6, 2026 12:25
Setup PWA support for Go SSRd apps
package main
import (
"bytes"
"embed"
"html/template"
"github.com/go-chi/chi/v5"
"github.com/joseph0x45/goutils"
)
@joseph0x45
joseph0x45 / build.md
Last active June 23, 2025 16:00
Build Python from source on Void Linux

How to build Python from source

Download the source code from Python's website

Instsall required dependencies for compiling Python

sudo xbps-install -S \
  gcc make libffi-devel zlib-devel \
  bzip2-devel xz-devel sqlite-devel \
 openssl-devel readline-devel ncurses-devel \

C Programmer Competency Roadmap

A plan to become a somewhat competent C programmer through meaningful projects.


๐ŸŒŸ Overview

These projects build your skills progressively:

@joseph0x45
joseph0x45 / void.md
Last active May 24, 2025 23:30
Everything I learned about while installing and configuring Void Linux

Void Linux

Updating the system with xbps-install -Syu

  • We update the system with xbps-install -Syu
  • -S to sync the repository index
  • -y to answer yes to all the confirmation requests
  • -u to update all packages

Installing tools we might need to setup X and i3

Install base-devel git curl wget unzip tar

Learn Go

  • The Go Programming language: Go basics and fundamentals Download link
  • Let's Go: How to write HTTP services with Go Download link

Learn about HTTP and networking

@joseph0x45
joseph0x45 / main.go
Last active March 25, 2024 11:34
Go json.Marshaler and json.Unmarshaler interfaces
package main
import (
"encoding/json"
"fmt"
"strconv"
)
func pigeonAgeToHumanYears(pigeonYears int) int {
if pigeonYears <= 1 {
@joseph0x45
joseph0x45 / index.md
Last active January 28, 2024 19:31
Bargaining with the mean voice - Dealing with failure to meet goals

8dvnd8

Have you ever failed to reach a goal you set? well most likely you have. We are humans after all and failure is built in our existence. However, we are also different in the way that we deal with such failure, regardless of that difference, I believe most of us have what I call the mean voice in our head, or have had it. I have it, from time to time, it comes up to remind me of my failures, to tell me what I could have done better. If you have such a voice in your head, I think it is a good thing, to some extent. That mean voice could be inner moral or ethical guidance that helps you make positive and righteous decisions, it could also be the result of a toxic relationship you have with yourself. Whether that is a good thing or not is yours to decide. In this post I want to talk about how I feel about that mean voice, and how I have learned to bargain with it so that we can both live together in the same body without h

@joseph0x45
joseph0x45 / pain.md
Last active January 24, 2024 13:33
Writing arithmetic operations from scratch in C: Part 1

Hello reader, this is the first article of a series where I will be trying to recreate arithmetic operations in binary using C Lets' get into the good stuff.

What the heck am I doing exactly

Well, as I said, arithmetic operations, I will start with integers first, so the goal is to have functions for every operations (addition, division, substraction and multiplication) that would take in 2 integers and return the result of the corresponding operation. The catch is that we are not allowed to use the "built in" arithmetic operations in C, meaning this

int add(int a, int b){