Skip to content

Instantly share code, notes, and snippets.

@awoodruff
awoodruff / MarkerCluster.css
Last active May 17, 2024 22:20
Leaflet cluster map + choropleth
.marker-cluster-small {
background-color: rgba(181, 226, 140, 0.6);
}
.marker-cluster-small div {
background-color: rgba(110, 204, 57, 0.6);
}
.marker-cluster-medium {
background-color: rgba(241, 211, 87, 0.6);
}
@TRB-Exe
TRB-Exe / windowsfastactivation.md
Last active May 17, 2024 22:18
Windows 10 fast activation from cmd

Super easy and fast activation from command prompt

Run cmd.exe with Admin permissions and enter commands for your system

windows 10/11

slmgr /ipk W269N-WFGWX-YVC9B-4J6C9-T83GX
slmgr /skms kms.digiboy.ir
slmgr /ato

Docker Swarm in LXC Containers

Part of collection: Hyper-converged Homelab with Proxmox

After struggling for some days, and since I really needed this to work (ignoring the it can't be done vibe everywhere), I managed to get Docker to work reliable in privileged Debian 12 LXC Containers on Proxmox 8

(Unfortunately, I couldn't get anything to work in unprivileged LXC Containers)

There are NO modifications required on the Proxmox host or the /etc/pve/lxc/xxx.conf file; everything is done on the Docker Swarm host. So the only obvious candidate who could break this setup, are future Docker Engine updates!

@felipecsl
felipecsl / restart coreaudio daemon
Last active May 17, 2024 22:17
Restart Mac OS X coreaudio daemon. Useful if you cannot change the audio output device to Airplay.
sudo kill `ps -ax | grep 'coreaudiod' | grep 'sbin' |awk '{print $1}'`
# or...
sudo killall coreaudiod
For a trial reset remove the entire key:
Windows Registry Editor Version 5.00
HKEY_CURRENT_USER\Software\Classes\CLSID\{dc8137d7-6d72-3550-a000-ae9c2affc92}
after that reboot. :)
@mathcodes
mathcodes / dsa_pattern.md
Last active May 17, 2024 22:13
14 DSA Patterns to Master

14 Coding Patterns To Master

This is a collection of coding patterns I have learned to solve not only some of the most common problems, but the 14 patterns (yes, there are way more than 14, but the point here is taking 6 months of preparation and condensing it into a 30 minute read that would not take more than 1-2 weeks to master. I have found these problems and patterns to be the most useful in that the data structures and algorithms are used in many other problems and become familiar over time. Good luck!

Please feel free to comment if you got some value or find any errors!

Thanks!

Table of Contents

@demirdegerli
demirdegerli / ubuntu_debloater.sh
Last active May 17, 2024 22:10
Ubuntu Debloater
#!/bin/sh
if [ "$(whoami)" != "root" ]; then
echo "Please run this script as root."
exit
fi
printf "This script will\n\n- Remove Snap\n- Install the deb version of Firefox\n- Install Flatpak\n- Optionally replace Ubuntu Desktop with GNOME\n\n"
read -p "Continue? (Y/n) " start_prompt
case $start_prompt in
[nN] | [nN][oO] )
exit
@VictorTaelin
VictorTaelin / sat.md
Last active May 17, 2024 22:08
Simple SAT Solver via superpositions

Solving SAT via interaction net superpositions

I've recently been amazed, if not mind-blown, by how a very simple, "one-line" SAT solver on Interaction Nets can outperform brute-force by orders of magnitude by exploiting "superposed booleans" and optimal evaluation of λ-expressions. In this brief note, I'll provide some background for you to understand how this works, and then I'll present a simple code you can run in your own computer to observe and replicate this effect. Note this is a new observation, so I know little about how this algorithm behaves asymptotically, but I find it quite

@yamnikov-oleg
yamnikov-oleg / calling_conventions.md
Created February 20, 2016 09:19
Linux Syscalls Reference

Source: man syscall

Architecture calling conventions

Every architecture has its own way of invoking and passing arguments to the kernel. The details for various architectures are listed in the two tables below.

The first table lists the instruction used to transition to kernel mode, (which might not be the fastest or best way to transition to

@genesysflow
genesysflow / ingress.yml
Created September 20, 2022 15:28
k3s expose kubernetes dashboard through traefik ingress
apiVersion: traefik.containo.us/v1alpha1
kind: ServersTransport
metadata:
name: insecure-transport
namespace: default
spec:
insecureSkipVerify: true
---
apiVersion: networking.k8s.io/v1
kind: Ingress