Skip to content

Instantly share code, notes, and snippets.

View kwmiebach's full-sized avatar

kwmiebach kwmiebach

View GitHub Profile
@kwmiebach
kwmiebach / core.pl
Last active February 18, 2026 21:02
portable perl
#!/usr/bin/perl
###############################################################################
#
# ONLY USE STANDARD TRADITIONAL CORE PERL.
# NO CPAN MODULES. NO MODERN PERL. NO use v5.XX. NO Moose, Moo, Try::Tiny,
# Path::Tiny, or ANY non-core module. Stick to what ships with perl itself:
# strict, warnings, File::Basename, File::Path, File::Copy, Getopt::Long,
# Cwd, POSIX, etc.
#
###############################################################################
@kwmiebach
kwmiebach / .tmux.conf
Last active May 17, 2026 09:59
.tmux.conf
# V15
# This file versioned as gist:https://gist.github.com/kwmiebach/b0d03afde427a33acf62f994c8f960fa
# For the latest version go to above link, then click `raw`, then copy paste from the browser.
# Deep linking it does not work.
# INSTALL FROM GIST as tmux conf file if none exists yet (this could probably fetch an old version):
# curl https://gist.githubusercontent.com/kwmiebach/b0d03afde427a33acf62f994c8f960fa/raw/.tmux.conf > ~/.tmux.conf && cat ~/.tmux.conf | head -n5 | grep V
# RELOAD: tmux source-file ~/.tmux.conf
@kwmiebach
kwmiebach / odoo18_website_settings_and_fields.py
Last active February 18, 2026 21:02
Available website settings and website fields in Odoo 18
'''
Find out available website settings and website fields.
The fields are recognized with a fuzzy algorythm, so there might be
too many and some might be missing?
Run this in an odoo shell of the odoo instance:
'''
installed_langs = env['res.lang'].search([('active', '=', True)])
print("Installed languages:", installed_langs.mapped('code'))
@kwmiebach
kwmiebach / v17.css
Created December 18, 2024 12:42
Styles V17
/* chrome n3 */
a.fw-bold.text-truncate {
font-size: 30px
}
span.min-w-0.text-truncate {
font-size: 30px
}
@kwmiebach
kwmiebach / gitkeys.pl
Last active April 5, 2026 11:45
Add public keys for a user to ~/.ssh/authorized_keys - previously addkeys bash script
#!/usr/bin/env perl
use strict;
use warnings;
# This file is now tracked as part of the servertools repository
# Only use traditional core Perl — no CPAN or external dependencies.
# Compatible with old Perl versions — do not use features or depend
# on anything that needs a Perl version newer than 5.10.x
#
@kwmiebach
kwmiebach / make-system-folder.cmd
Last active January 1, 2025 15:29
Create a `Windows Master Control Panel' / 'All Tasks Folder on the Desktop'. The so called 'god mode '
@echo off
cd %USERPROFILE%\Desktop
mkdir "system.{ED7BA470-8E54-465E-825C-99712043E01C}"
@kwmiebach
kwmiebach / smnetscanner.sh
Last active January 1, 2025 15:30
If you can't use angryipscanner from a command line
#!/bin/bash
# (c) CompuMatter, LLC, ServerMatter
# no warranty expressed or implied - use as is.
# See https://www.youtube.com/watch?v=4hjskxkapYo
# versioned here: https://gist.github.com/kwmiebach/6565ad1b43f3c781b23fce6ba80f59ea
# history of the gist:
# 2023-09-28 downloaded from https://cloud.compumatter.biz/s/fxfYM9SkamBtGqG - unchanged
# purpose of this script:
@kwmiebach
kwmiebach / get_toml_value.sh
Last active May 29, 2026 11:04
Read values from a simple toml file in bash
#######################################################################################
# Bash function get_toml_value() to get the value of a key in a section of a TOML file.
# Versioned here: https://gist.github.com/kwmiebach/e42dc4a43d5a2a0f2c3fdc41620747ab
# Call it like this:
# value=$(get_toml_value "./conf/config.toml" "server_b" "domain")
# Result should be "my123.example.com" in the case of this example file:
# ---------------------------
# [server_a]
# proto = "https"
# domain = "test.example.net"
@rockavoldy
rockavoldy / 0-odoo-cheatsheet.md
Last active December 3, 2025 13:19
Odoo Cheatsheet
@gitanat
gitanat / sendreceive.py
Created November 9, 2012 09:00
send and receive python objects through network with integrity and authentication
'''this module implements two functions, send() and receive(), capable
of sending arbitrary objects through the network (with pickle), with
authentication and integrity assurance'''
import socket
try:
import cPickle as pickle
except ImportError:
import pickle
import hmac