Skip to content

Instantly share code, notes, and snippets.

View jdevera's full-sized avatar

Jacobo de Vera jdevera

View GitHub Profile
import sys
def get_size(obj, seen=None):
"""Recursively finds size of objects"""
size = sys.getsizeof(obj)
if seen is None:
seen = set()
obj_id = id(obj)
if obj_id in seen:
return 0
@tombarys
tombarys / better-search.clj
Last active February 27, 2024 09:48
Better-search for Roam (V 2.11 improved + sorting)
(ns better-search-V2.1
(:require [reagent.core :as r]
[roam.datascript :as rd]
[roam.util :refer [parse]]))
(defn query-list [s-type search]
"creates a list of pages"
(sort (case s-type
:starts (rd/q '[:find ?fulltitle
:in $ ?search
@NorkzYT
NorkzYT / README.md
Last active July 8, 2025 02:58
Proxmox CIFS Share Mount Wizard Script

Proxmox LXC ⇆ CIFS Mount Wizard

proxmox-lxc-cifs-share.sh is an interactive helper that mounts a network CIFS/SMB share on a Proxmox VE node and bind-mounts it into one or more unprivileged LXC containers in one pass.
It automates:

  1. Creating a host-side mountpoint under /mnt/lxc_shares/<folder>.
  2. Writing a properly-tuned /etc/fstab entry (systemd.automount, uid/gid mapping, etc.).
  3. Mounting the share immediately.
  4. Injecting the bind-mount (mpX:) into the live LXC configuration with pct set.
  5. Stopping and restarting each container to apply the mount.