Skip to content.
Joe Heaton's Webzone
🥐 ☕
Online since 2011

my Vim

This is my .vimrc, I find it benefitial to use this where I do development to normalise my editor across different operating systems, and to enable some useful untapped features to make Vim feel a bit less prehistoric.

Read more →

SSH port forwarding

The following command connects to our server and forwards a specific port on our local machine to the server. In this case we forward port 5432 which belongs to PostgreSQL, so when we connect to localhost:5432 on the desktop, the connection is forwarded through the secure tunnel to the server.

Read more →

Dynamically load fonts

I’ve added a Dyslexia accessibility feature to my website which loads a Dyslexia-friendly font, woo! This involved creating a small toggle function to turn the feature on and off, but when I reload the page it’s gone, so I had it bake a cookie so the function could trigger automatically on-reload. This still wasn’t enough I didn’t want every visitor to load the font, only users who click the toggle button, so I added a section to dynamically load the font. Read more →

Windows 10 Revamp

My notes on wiping Windows 10, which configuration options to watch out for and a list of useful programs. The whole process of wiping, installing and provisioning with a basic set of programs can be complete in an hour with a fast Solid-State Drive and modern hardware.

Read more →

Windows Terminal - Change default profile

Open the new tab dropdown, found to the right of your tabs: Windows Terminal new tab dropdown Click “Settings”, this will open a JSON file (for now) which looks something like this: { "defaultProfile": "{987-654-321}", "profiles": [ { "guid": "{987-654-321}", "hidden": false, "name": "Debian", "source": "Windows.Terminal.Wsl" }, { "guid": "{123-456-789}", "name": "Windows PowerShell", "commandline": "powershell.exe", "hidden": false }, Copy the guid value from whichever flavour of Linux you want to set as default. Read more →

Useful Unixisms

Here’s a list of useful piped commands or just commands for which I need a refresher on which arguments to use. For example, using Awk to print between two known lines, or seleting a line in sed are good examples of infrequently used commands which are really useful.

Read more →

Pixelfed - self-hosted & federated photo hosting

In addition to a typical PHP server, you will need to install the php-bcmath package. Install image processing libraries apt install jpegoptim optipng pngquant. Following PixelFed’s Manual Setup instructions. git clone https://github.com/pixelfed/pixelfed cd pixelfed composer install chown -c www-data:www-data -R storage/ Set the website domain name for the following variables in .env: APP_URL, with protocol (https://) APP_DOMAIN ADMIN_DOMAIN SESSION_DOMAIN Using the Laravel “Artisan” console we prepare the app & database. Read more →

Github CLI headless install

Download & Install Github CLI. Run gh pr status, you will be prompted to connect gh to your Github account, open the github.com link it generates in a web browser, login and authorize the application. You will be redirected to a localhost address, copy the full address. Now you will need another terminal open one the same system, use wget/curl to pass the authorization onto the gh client: wget -O- GITHUB_URL Read more →

TimescaleDB SQL in Grafana

Grafana supports SQL through MySQL/MariaDB, PostgreSQL & SQL Server. Additionally Grafana supports the PostgreSQL extension TimescaleDB, this database is the best fit of all the SQL databases for Grafana since it is built specifically for large-scale time-series datasets.

Read more →

SFTP instead of SCP

SCP suffered from weak input validation for decades until CVE-2019-6111, the maintainers recommended using SFTP until patched versions can be deployed. I, like many others, were reminded SFTP existed!

Read more →

Git feature branch & merge

Start with your master branch git checkout master git fetch origin If your local master has been modified, you can reset its state. git reset --hard origin/master Checkout a new feature branch. git checkout -b my-feature Make changes in this branch, committing as usual. git add file.txt git commit -m "add my file.txt" You can push your branch to allow others and yourself to evaluate and commit further to it. Read more →
avatar
Joe Heaton

Email: [email protected]

Web:

Joe’s technology-focused murmurings.

Settings!