Skip to content

Instantly share code, notes, and snippets.

View veox's full-sized avatar
💭
Being skeptical of status feature.

Noel Maersk veox

💭
Being skeptical of status feature.
View GitHub Profile
@vmikk
vmikk / sbx.sh
Created November 10, 2025 09:02
Run shell commands in a lightweight sandbox (using `bubblewrap`)
sbx() {
: '
sbx - run a command in a minimal bubblewrap sandbox
Overview:
- Only the current working directory has read-write permissions and allows persistent changes
- Host filesystem mounted read-only
- /proc and /dev are also sandboxed
- Existing PATH/env are kept, so system + conda tools work normally
@sebastiancarlos
sebastiancarlos / sway-popup-listener.bash
Last active June 9, 2026 13:37
sway-popup-listener
#!/usr/bin/env bash
# This script listens for new windows and makes them floating if it thinks they
# are popups. Meant to be used when regular i3 criteria are not enough to
# identify popup windows. It uses hardcoded dimensions.
# print usage on --help/-h
if [[ "$1" == "--help" || "$1" == "-h" ]]; then
echo "Usage: $0"
echo "This script listens for new windows and makes them floating if it thinks they"
@doolio
doolio / .dir-locals.el
Last active October 6, 2026 09:51
.dir-locals.el for use with the Emacs Eglot LSP client and python-lsp-server (pylsp) LSP server
;;; Directory Local Variables
;;; For more information see (info "(emacs) Directory Variables")
;;; Commentary:
;; .dir-locals.el for use with the Emacs Eglot LSP client and
;; python-lsp-server (pylsp) LSP server v1.10.0.
;; Default values in accordance with
;; https://github.com/python-lsp/python-lsp-server/blob/v1.10.0/CONFIGURATION.md
@EdoaLive
EdoaLive / patch_19.07.patch
Created September 13, 2021 15:59
[PARTIAL] Patch to OpenWRT 19.07 for ASUS RT-AC52U B1
diff --git a/target/linux/ramips/dts/RT-AC52U-B1.dts b/target/linux/ramips/dts/RT-AC52U-B1.dts
new file mode 100644
index 0000000..aad625c
--- /dev/null
+++ b/target/linux/ramips/dts/RT-AC52U-B1.dts
@@ -0,0 +1,184 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
@ychaouche
ychaouche / Spamassassin rules description
Last active September 11, 2026 00:51
Spamassassin rules description
Note:
to keep this list automatically updated,
I turned it into a repo which is automatically updated via cron.
see https://github.com/ychaouche/spamassassin-rules-description
AC_BR_BONANZA Too many newlines in a row... spammy template
ACCESSDB Bericht zou gevangen zijn door accessdb
ACCESSDB Ce message aurait �t� bloqu� par accessdb
ACCESSDB Mensagem teria sido pega pela accessdb
ACCESSDB Message would have been caught by accessdb

ZSH CheatSheet

This is a cheat sheet for how to perform various actions to ZSH, which can be tricky to find on the web as the syntax is not intuitive and it is generally not very well-documented.

Strings

Description Syntax
Get the length of a string ${#VARNAME}
Get a single character ${VARNAME[index]}
pragma solidity ^0.5.11;
/*
* @author Agustin Aguilar <@agusx1211>
*/
library ChunkStorage {
struct Storage {
mapping(bytes32 => address) slots;
}
@ritzdorf
ritzdorf / EIP1884.md
Last active February 1, 2026 01:18
Recently Executed Transactions affected by EIP1884

Recently Executed Contracts with Issues in EIP 1884

EIP 1884 is set to be implemented into the upcoming Ethereum 'Istanbul' hard fork. It

  • increases the cost of opcode SLOAD from 200 to 800 gas
  • increases the cost of BALANCE and EXTCODEHASH from 400 to 700 gas
  • adds a new opcode SELFBALANCE with cost 5.
@cburgdorf
cburgdorf / gist:1d4678f135dea129147c3627dd609c4e
Created May 10, 2019 08:43
rocksdb_vs_leveldb_against_single_peer
Supervisord config:
[program:trinity]
user=ubuntu
environment=HOME="/home/ubuntu"
command=/home/ubuntu/trinity/venv/bin/trinity track-perf --track-perf-interval 1 --track-perf-trinity-exec '/home/ubuntu/trinity/venv/bin/trinity' --track-perf-pre-exec-cmd 'cd /home/ubuntu/trinity && git checkout -' --track-perf-report-path '/home/ubuntu/trinity/performance_report.txt' --track-perf-target-block 20000 --track-perf-run-count 10 --track-perf-trinity-args='--disable-discovery --preferred-node="enode://9a1cda701a98a08065b950a87c20df7d076c7e2b11dfcd489a66efd8cbb9fb9894c7788461d6140cf0f312794098917e952f173c09bbbddf848b97afad962d61@40.118.145.245:30303" --max-peers 1'
autostart=false
autorestart=false
redirect_stderr=true
stdout_logfile=/var/log/supervisor/trinity.log
import logging
import multiprocessing
from multiprocessing.managers import (
BaseManager,
)
import tempfile
import time
import pytest