Skip to content

Instantly share code, notes, and snippets.

View xmawja's full-sized avatar
🎯
Focusing

Muja Siyam xmawja

🎯
Focusing
View GitHub Profile
@welpo
welpo / pre-commit
Last active July 10, 2024 23:33
git pre-commit script to update the date of Zola's posts
#!/usr/bin/env bash
# Requires Bash 4.0 or newer.
# This script updates the 'updated' field in the front matter of modified .md
# files setting it to their last modified date.
# Function to exit the script with an error message.
function error_exit() {
echo "ERROR: $1" >&2
exit "${2:-1}"
@GnaneshKunal
GnaneshKunal / go-ts-fmt.el
Created December 25, 2022 06:29
Plug go-mode's gofmt to the new go-ts-mode (built-in go mode which uses tree-sitter) in emacs
;; Copyright of the below functions belong to the author/contributors of https://github.com/dominikh/go-mode.el.
;; Usage: Plug go-mode's gofmt to the new go-ts-mode (built-in go mode which uses tree-sitter) in emacs.
;; go-ts-mode landed on emacs `master` branch on 2022-12-16.
(defcustom gofmt-command "gofmt"
"The 'gofmt' command.
Some users may replace this with 'goimports'
from https://golang.org/x/tools/cmd/goimports."
@Nathan-Furnal
Nathan-Furnal / python-setup-init.el
Created May 18, 2022 19:05
Trimmed down python setup for Emacs. This is a basic `init.el` file for Python, you can pick the bits you like.
;;; init.el --- Fun stuff all around -*- lexical-binding: t; -*-
;;; Commentary:
;; This is a simple init.el which offers a Python configuration. Each package
;; usage is annotated with the how and why of its use. `use-package' is used to
;; manage the configuration as it provides lots of facilities to load modes,
;; define custom variables and key-maps, etc.
;;; Code:
@TomasBeuzen
TomasBeuzen / laptop_setup_v2.md
Last active July 11, 2023 12:06
Steps taken when setting up my MacBook Air (M1)

New Mac Setup

This gist documents the setup of my Mac, primarily for personal use and data science.

Hardware/software details:

  • MacBook Air (M1, 2020)
  • Big Sur (11.2.2)

Installs

  • Install HomeBrew
@githubcom13
githubcom13 / Protonmail.md
Last active June 25, 2025 14:00 — forked from ibaiul/Protonmail.md
Configure the protonmail bridge linux client on Ubuntu 20.04 and Debian 10 server

Protonmail on Ubuntu 20.04 and Debian 10 server

#protonmail #debian #linux

Before you start

Currently protonmail bridge for linux is distributed as part of an open beta program, but soon it will be made public (https://protonmail.com/bridge/install).

Consider that the bridge linux client requires a paid protonmail account to work.

Get the protonmail bridge linux installer

@thanatos
thanatos / howto-k8s.md
Created December 7, 2019 19:12
How to init k8s cluster on Gentoo

Install Stuff

Emerge kubelet, kubeadm, kubectl, all the same version. For some reason, Gentoo stablized kubelet and kubectl but not kubeadm.

I'm using Calico, so also emerge net-misc/calico-cni-plugin.

Correct Stuff

@ryo-ARAKI
ryo-ARAKI / starship.toml
Last active November 15, 2025 00:46
Starship configuration file
# ~/.config/starship.toml
[battery]
full_symbol = "🔋"
charging_symbol = "🔌"
discharging_symbol = "⚡"
[[battery.display]]
threshold = 30
style = "bold red"
@nerdyman
nerdyman / README.md
Last active September 4, 2023 19:38
GTA V Working on Steam Play (Proton) on Arch Linux and proprietary Nvidia drivers

Steps for Arch Linux w/ Nividia proprietary driver

  • Install wine-staging (pacman -S wine-staging)
  • Install the latest Nvidia drivers (pacman -S nvidia-dkms nvidia-utils lib32-nvidia-utils)
  • Create a GTA DXVK config file [1]
  • Set GTA 5 launch option in Steam to DXVK_CONFIG_FILE=/<PATH_TO_YOUR_CONFIG>/gta_dxvk.conf %command%
  • Copy steam/steamapps/common/Proton 3.7/user_settings.sample.py to steam/steamapps/common/Proton 3.7/user_settings.py
    • Uncomment "PROTON_NO_ESYNC": "1" in user_settings.py
  • Copy all Windows fonts from a Windows ISO to /usr/share/fonts/WindowsFonts OR install ttf-ms-win10 from the AUR
  • Run fc-cache -vfr to rebuild the font cache
@extremecoders-re
extremecoders-re / qemu-networking.md
Last active September 3, 2025 00:10
Setting up Qemu with a tap interface

Setting up Qemu with a tap interface

There are two parts to networking within QEMU:

  • The virtual network device that is provided to the guest (e.g. a PCI network card).
  • The network backend that interacts with the emulated NIC (e.g. puts packets onto the host's network).

Example: User mode network

@jatcwang
jatcwang / gist:ae3b7019f219b8cdc6798329108c9aee
Created February 2, 2017 23:44
List of all setxkbmap configuration options (including models/layout/etc)
! model
pc101 Generic 101-key PC
pc102 Generic 102-key (Intl) PC
pc104 Generic 104-key PC
pc105 Generic 105-key (Intl) PC
dell101 Dell 101-key PC
latitude Dell Latitude series laptop
dellm65 Dell Precision M65
everex Everex STEPnote
flexpro Keytronic FlexPro