Skip to content

Instantly share code, notes, and snippets.

@vasanthk
vasanthk / System Design.md
Last active May 12, 2024 18:13
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@beerpiss
beerpiss / 0.readme.md
Last active May 12, 2024 18:10
3simai
@ioqy
ioqy / tutorial.md
Last active May 12, 2024 18:08
Free Let's Encrypt certificate without opening any ports

With this tutorial you will get a valid SSL certificate from Let's Encrypt without having to open any incoming ports. You can use the certificate to enable HTTPS with your reverse proxy (Apache, Nginx, Caddy, ...) or other self hosted service. Since it only uses acme.sh which is a shell script it should work on everything that runs linux.

The tutorial was written for and tested with Duck DNS and deSEC, but you can (in theory, because I did sadly encounter a few bugs/incompatibilities here and there) use every of the 150+ DNS provider supported by acme.sh (there is also a second page at the end!). If you want to use a wildcard certificate I would recommend deSEC because Duck DNS currently has a bug/incompatibility with acme.sh.

If you want to use another DNS provider you can skip right to 2. Install acme.sh, but need to change the parameter --dns YOURDNS in all the commands and set all necessary variables yourself according to t

@udf
udf / write_up.md
Last active May 12, 2024 18:05
A Trick To Use mkMerge at The Top Level of a NixOS module

The Setup

I wanted to write a module that generates multiple systemd services and timers to scrub some zfs pools at certain intervals. The default scrub config does not support individual scrub intervals for each pool.

I want the config to look like this:

{
  services.zfs-auto-scrub = {
 tank = "Sat *-*-* 00:00:00";
@Batimius
Batimius / README.md
Last active May 12, 2024 18:04
Transfer HotGames.GG history to other services

Genshin Impact Pity Converter

A simple website for converting your Genshin Impact wish history from HotGames.GG to other platforms. A simple guide to transfering your Genshin Impact wish history from HotGames.GG to other services (directly fetched from the main repo because I was too lazy to write a new set of instructions)

Instructions

Step 1

  1. Go to https://genshin.hotgames.gg/wish-counter
  2. Make sure you are either signed in or you have imported your history
  3. Open your console window (Ctrl + Shift + J [Windows], Cmd + Shift + J [Mac] for Chrome / Edge, Ctrl + Shift + K [Windows], Cmd + Shift + K [Mac] for Firefox)
Aimbot Range 4.4
Aimbot TurnSpeed 2.0
Aimbot FOV 180.0
Aimbot Center false
Aimbot Lock true
Aimbot OnClick false
Aimbot Jitter false
AntiBot Tab false
AntiBot TabMode Contains
AntiBot EntityID false
@wkliwk
wkliwk / btt.sh
Last active May 12, 2024 18:00
BTT reset trial time
# BetterTouchTool reset trial time
# ** All preference will reset
echo "remove ~/Library/Preferences/com.hegenberg.BetterTouchTool.plist"
rm -rf ~/Library/Preferences/com.hegenberg.BetterTouchTool.plist
echo "Done"
echo "remove ~/Library/Application\ Support/BetterTouchTool/"
rm -rf ~/Library/Application\ Support/BetterTouchTool/
echo "Done"
@rutcreate
rutcreate / README.md
Last active May 12, 2024 17:59
Install Python 3.10.x on Ubuntu 20.04

Prerequisite

sudo apt update
sudo apt install software-properties-common -y

Add custom APT repository

@bmaupin
bmaupin / free-database-hosting.md
Last active May 12, 2024 17:59
Free database hosting
@wojteklu
wojteklu / clean_code.md
Last active May 12, 2024 17:57
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules