Skip to content

Instantly share code, notes, and snippets.

@fardjad
fardjad / how-to-install-homebrew-on-debian-based-distros.md
Last active April 23, 2024 23:02
[How to Install Homebrew on Debian-based Distros] Steps required to install homebrew on MX Linux (and other Debian-based distros) #linux #debian #mxlinux #homebrew

How to Install Homebrew on Debian-based Distros

Steps required to install Homebrew on MX Linux (and other Debian-based distros)

Steps

  1. Update apt cache and optionally do a full upgrade

     apt update
    

apt full-upgrade # optional, reboot if needed

@fardjad
fardjad / how-to-install-homebrew-on-manjaro.md
Last active March 18, 2024 16:09
[How to Install Homebrew on Manjaro] Steps required to install homebrew on Manjaro Linux #linux #manjaro #homebrew
@fardjad
fardjad / batch-m4a-to-mp3.md
Last active February 28, 2024 16:37
[How to Convert m4a Files to mp3, Preserving Bitrate and ID3 Tags Using ffmpeg] #ffmpeg #bash

How to convert m4a files to mp3, preserving bitrate and id3 tags using ffmpeg

Prerequisites

  1. ffmpeg
  2. cygwin (on windows)

Commands

cd /path/to/m4a/files
mkdir out
for f in *.m4a; do 
@fardjad
fardjad / debian-sid-with-systemd-on-wsl2.md
Last active February 10, 2024 05:48
[Debian sid with systemd on WSL2] Instructions for running Debian sid with systemd on WSL2 #windows #wsl2 #debian #sid #linux
@fardjad
fardjad / how-to-start-colima-automatically-on-macos.md
Last active February 2, 2024 05:09
[How to start Colima automatically on macOS] Instructions for starting Colima automatically on macOS similar to Docker Desktop #macos #colima #docker

⚠️ Note: Since the merge of commit Homebrew/homebrew-core#149670, starting Colima is as easy as running brew services start colima. You can skip the following work-around.

Steps

  1. Create an executable script to run in foreground and manage colima:
cat <<-EOF | sudo tee /usr/local/bin/colima-start-fg
#!/bin/bash
@fardjad
fardjad / considerations-for-running-postgres-on-nfs.md
Last active January 25, 2024 14:06
[Considerations for Running Postgres on NFS] #postgres #nfs #fsync #fsexport #mount
@fardjad
fardjad / colima-multi-platform-config.md
Last active January 18, 2024 05:04
[Colima Multi-Platform Config] Colima configuration for building images for multiple platforms on Apple silicon with buildx #colima #docker #buildx #config #apple #aarm64

Instructions

Run the following and replace the config file:

colima start --edit

Build a docker image:

docker buildx build --platform linux/amd64,linux/arm64 .
@fardjad
fardjad / dsl-lte-auto-switch-setup.md
Last active January 17, 2024 16:11
[DSL/LTE Auto-switch Setup] #openwrt #dsl #lte #multiwan

DSL/LTE Auto-switch Setup

Synopsis

This is how I setup my home router to share a 4G/LTE connection at day and switch to a DSL connection overnight.

It also falls back to DSL connection whenever the 4G/LTE connection dies.

Why?

A selected list of my gists that are written in the style of a blog post
@fardjad
fardjad / debugging-and-authoring-helm-charts-and-post-renderer-hooks-with-viddy.md
Last active December 29, 2023 03:47
[Debugging and Authoring Helm Charts and Post Rendering Hooks with Viddy] #helm #viddy #watch #kubernetes #yaml #less #pager