RSSAmplifier

Blog

Chris Hughes dot Dev

A Developer blog for Chris Hughes. Specializes in JavaScript, Rust, Web development, SQL

chris-hughes.devRSS feed ↗19 posts

Latest posts

Quadlet Homelab

I recently decided to improve upon my homelab setup. The entire thing was running on an old Thinkpad t480 (This is now being used in a Proxmox cluster for a Kubernetes adventure! Post coming soon!) under my desk. It was running a Factorio server and a FoundryVTT server that were managed with Docker and Docker compose. The setup worked fine for several months, but there were some pain points. First…

Subtle problems with AI

I recently did a Google search for the word ashuddha vikalpa. This term originates from the Shaiva tantra branch of tantra, referring to “impure” vikalpas. Vikalpas is a broader term used in both Buddhism and Hinduism that refers to mental constructs that are shaped by thoughts or emotions. In other words, mental constructs that are shaped and colored by karma. ’Ashuddha…

Go Emacs Static Blog Generator

Go Emacs is a static blog site generator written in Go that leverages Emacs Org mode’s HTML exporting functionality. This is the most recent evolution of my Emacs CMS idea to use Org mode as a content management system for my blog. Go Emacs comes with the source code needed to generate a go-emacs binary that is used with the included go.emacs.el to generate blog posts. Configuration The…

ZNC Bouncer with Doom Emacs

IRC is a great chat protocol, but it has some annoying limitations when compared to other modern chat protocols. First and foremost, it lacks the ability to see messages that are sent on servers when you are not connected to a server via a client. Messages are sent to your client when you are connected, but there is no obvious way to log messages that are sent while you are offline. This means…

Paper Picker Update

Several months ago after switching to Hyrpland, I started using their wallpaper utility, Hyprpaper . I have multiple monitors and like to spice my life up by cycling through wallpapers once an hour or so. I created some bash scripts and a cron job to run the scripts on a timely basis, and choose which directory to pull the images from using wofi. While it worked, it had several problems associated…

Emissions Tracker

I have recently launched a new website, emissionstracker.ca ( repo ), with two colleagues, Rose Scoville and Nick Richardson . Rose and Nick were primarily focused on the front end and visual design, while I focused on the back end, server, containerization, and design of the overall stack. The data for the application is taken from open source data provided by the Canadian federal government on…

Nuts

What’s NUTS? NUTS , Naokotani’s Unusable Text Software (I am also playing with the idea of PEANUTS, Portable Executable Application: Naokotani’s Unusable Text Software), is my new hobby coding project to create a rudimentary TUI text editor similar to Vi or Nano in C. The plan is to create a text editor that stores text in a rope-like data structure based on logical text…

Bun Blog Update

The problem When I created my blog app, I decided to use PM2 to manage the node application that runs my blog. This created a few small problems. First my blog is a Node application, which PM2 handles quite well, but my other applications are a mixture of Rust binaries, Java jars, and Node applications. Additionally, my blog relied on git to pull some data from a git repository, which was…

Reagent

After having used Emacs for over five years now, I have been becoming increasingly interested in trying out Lisp dialects other than Emacs Lisp (or “Elisp”). My first impression of Lisp was one of confusion. I found it utterly incomprehensible, and most of my time spent configuring Emacs was copying and pasting snippets of code from other people’s setups or documentation. In…

Paper Picker

I recently made the switch from Windows 11 using WSL to Arch using Hyprland as my desktop environment, and I couldn’t be happier with the change. Windows 11 came pre-installed on my laptop, and I didn’t initially get around to changing the OS. WSL is impressive in a sense, it’s very good at what it does, but Windows in general is a pain and small issues kept cropping up, so I…

Bun SQLite

I recently had a school project where I needed to build a simple web application by taking some sample data from a CSV file to build a book web store. I quickly determined that I didn’t want to deal with parsing a CSV files throughout my application every time I needed the data, and I was even less interested in trying to update that data. I decided that the best route would be to just parse…

Diesel Database

When I decided to start work on this project, I knew it would be important to carefully design the database. I did some research into software to draw an entity relationship diagram and a UML diagram to help me map out the project, and a friend suggested that I try PlantUML . PlantUML is a java based application that builds diagrams from a very intuitive but powerful text based description syntax.…

Trying Deno

Deno, as well as Node’s other competitor Bun, attempt to compete with Node by solving some of the headaches that arise from the complexity of the Node ecosystem. Probably the biggest issue that Deno tries to solve is dealing with the complexity of and time wasted by the need to compile TypeScript before it can be run by Node. The Deno runetime is able to run TypeScript files directly without…

Bun Blog

I wasn’t entirely happy with my Emacs CMS blog project. It felt like a bit of a disorganized prototype. I had HTML lurking around in my index.js along with all of the logic for the whole app, it could only handle uploading .png files. Using a web framework like Express also felt really excessive for such a simple application. I had a few people suggest that the Bun JavaScript runtime as an…

Rust Web Scraper

In order to be able to build the PF2e Encounter Builder I needed to collect data for the database. I wrote a web scraper in rust that used the scraper crate to collect the data from the list of monsters on pf2srd.com . This involved three separate but related tasks: Parsing through the table in order to get the URLs for the individual monsters, scraping the data for each individual monster and…

Emacs Emmet React

emmet-react-mode is my first attempt at creating a minor mode in Emacs. It is designed as an extension for emmet-mode though it doesn’t rely on it. I find myself frequently writing out components for Svelte and React that have several props and I wanted a convenient way to quickly write them in Emacs. Expand Component The minor mode is centered around three interactive functions. The first,…

Emacs CMS

New Implementation The following in this blog all remains the case for the current production version of the blog, but I have recently started a new version using Bun in Place of Node and I am using TypeScript in place of vanilla JS. Instead of using Express, I am creating a new API from scratch with the built in Bun.serve() . I also decided to replace squirrelly templates with mustache.js…

Quizbot

Quizbot is a task management bot written with discord.js that is designed to be used for students or discords that are devoted to a university or college program. The bot allows users to interact with four commands, one of which is restricted to server admins. Class Class is the admin only command. It allows users to create, add, remove and change the status of classes by using interactive…

Pathfinder Encounter Builder

PF2e Encounter Builder is a Rust and Svelte web application that uses a Rust API and a Svelte front-end. The web application is designed to dynamically create encounters for a popular table top roll playing game called Pathfinder 2e. Using an HTML form on the front-end, users are able to configure their search constraints and then fetch() sends a query data to the Rust API. The rust back-end…