Skip to content

Instantly share code, notes, and snippets.

View reo101's full-sized avatar
πŸ…±οΈ

Pavel Atanasov reo101

πŸ…±οΈ
View GitHub Profile
@b-studios
b-studios / handlers.rkt
Last active July 17, 2024 10:49
Effect handlers in Racket
#lang racket
(require racket/control)
(require racket/syntax)
(struct operation (name effect))
(struct effect-call (op args cont))
(define (do op . args)
(control0-at (operation-effect op) k (effect-call op args k)))
@romainl
romainl / path.md
Last active March 12, 2025 11:05
Off the beaten path

Off the beaten path

What is &path used for?

Vim uses :help 'path' to define the root directories from where to search non-recursively for files.

It is used for:

  • gf, gF, <C-w>f, <C-w>F, <C-w>gf, <C-w>gF,
  • :find, :sfind, :tabfind,
@duairc
duairc / net.nix
Last active May 8, 2025 09:27
IP address arithmetic and validation in Nix
{ lib ? null, ... }:
let
net = {
ip = {
# add :: (ip | mac | integer) -> ip -> ip
#
# Examples:
@pta2002
pta2002 / colors.h
Last active May 24, 2024 17:08
ANSI colors in a single header file
#ifndef COLORS_H
#define COLORS_H
#define BOLD "\e[1m"
#define DIM "\e[2m"
#define UNDERLINED "\e[4m"
#define BLINK "\e[5m"
#define REVERSE "\e[7m"
#define HIDDEN "\e[8m"
@luuk00000000000000000000000000000000000
luuk00000000000000000000000000000000000 / tutorial.md
Last active January 19, 2024 11:04
This is a tutorial on how you can backup and restore your Discord favorite gifs (on windows)

This won't work anymore because Discord moved to cloud storage for the gifs

Backup

  1. Open Discord.
  2. Press CTRL, SHIFT and I on your keyboard at the same time.
  3. In the newly opened window, at the top, click the >> button, and then click on Application.
    Image 1
  4. Once in the Application tab, click the little triangle next to Local Storage, and then click on https://discordapp.com.
    Image 2
@FreddieOliveira
FreddieOliveira / docker.md
Last active June 2, 2025 13:51
This tutorial shows how to run docker natively on Android, without VMs and chroot.

Docker on Android πŸ‹πŸ“±

Edit πŸŽ‰

All packages, except for Tini have been added to termux-root. To install them, simply pkg install root-repo && pkg install docker. This will install the whole docker suite, left only Tini to be compiled manually.


Summary

@jfm535
jfm535 / .clang-tidy
Last active November 12, 2023 13:03
clion default tidy
---
Checks: 'clang-diagnostic-*,clang-analyzer-*,-*,bugprone-argument-comment,bugprone-assert-side-effect,bugprone-bad-signal-to-kill-thread,bugprone-branch-clone,bugprone-copy-constructor-init,bugprone-dangling-handle,bugprone-dynamic-static-initializers,bugprone-fold-init-type,bugprone-forward-declaration-namespace,bugprone-forwarding-reference-overload,bugprone-inaccurate-erase,bugprone-incorrect-roundings,bugprone-integer-division,bugprone-lambda-function-name,bugprone-macro-parentheses,bugprone-macro-repeated-side-effects,bugprone-misplaced-operator-in-strlen-in-alloc,bugprone-misplaced-pointer-arithmetic-in-alloc,bugprone-misplaced-widening-cast,bugprone-move-forwarding-reference,bugprone-multiple-statement-macro,bugprone-no-escape,bugprone-not-null-terminated-result,bugprone-parent-virtual-call,bugprone-posix-return,bugprone-reserved-identifier,bugprone-sizeof-container,bugprone-sizeof-expression,bugprone-spuriously-wake-up-functions,bugprone-string-constructor,bugprone-string-integer-assignme
@capezotte
capezotte / Replacing_Udev.md
Last active October 13, 2024 22:15
Instructions on replacing udev/eudev on Artix

Replacing udev on Artix Linux

Reminder this is UNSUPPORTED. Reproduce bugs on a stock install with xudev/eudev before reporting them.

Preparations

Do not reboot until you've done them all.

Step 1 - remove udev

@agnostic-apollo
agnostic-apollo / Android-Phantom,Cached-And-Empty-Processes.md
Last active February 23, 2025 01:52
Android Phantom, Cached And Empty Processes