Skip to content

Instantly share code, notes, and snippets.

View jsabater's full-sized avatar
💭
Ubi sapientas ibi libertas

Jaume Sabater jsabater

💭
Ubi sapientas ibi libertas
View GitHub Profile
@olih
olih / jq-cheetsheet.md
Last active March 12, 2025 00:35
jq Cheet Sheet

Processing JSON using jq

jq is useful to slice, filter, map and transform structured json data.

Installing jq

On Mac OS

brew install jq

#!/usr/bin/python
# SPDX-License-Identifier: MIT
import sys,json,base64,binascii
with open(sys.argv[1]) as fp:
pkey=json.load(fp)
def enc(data):
missing_padding = 4 - len(data) % 4
if missing_padding:
@v0lkan
v0lkan / nginx.conf
Last active February 26, 2025 09:35
Configuring NGINX for Maximum Throughput Under High Concurrency
user web;
# One worker process per CPU core.
worker_processes 8;
# Also set
# /etc/security/limits.conf
# web soft nofile 65535
# web hard nofile 65535
# /etc/default/nginx