Skip to content

Instantly share code, notes, and snippets.

View rare-magma's full-sized avatar

Nuno rare-magma

View GitHub Profile
@damru
damru / ikea-rodret_E2201_ZHA-Z2M_control-anything.yaml
Last active February 3, 2025 18:46
IKEA RODRET Dimmer Remote (E2201) - ZHA/Z2M - Control anything
blueprint:
name: IKEA Rodret Dimmer Controls (ZHA/Z2M)
description: "## Control anything with IKEA RODRET Dimmer remote (v1.2)
Only for use with [ZHA](https://www.home-assistant.io/integrations/zha/)
or Zigbee2MQTT (cf [MQTT](https://www.home-assistant.io/integrations/mqtt)
+ [Z2M addon](https://www.zigbee2mqtt.io/guide/installation/03_ha_addon.html)).

Moved to repo: /quenhus/uBlock-Origin-dev-filter

In order to keep filters up to date, please use this repo.

@m-radzikowski
m-radzikowski / script-template.sh
Last active January 27, 2025 07:00
Minimal safe Bash script template - see the article with full description: https://betterdev.blog/minimal-safe-bash-script-template/
#!/usr/bin/env bash
set -Eeuo pipefail
trap cleanup SIGINT SIGTERM ERR EXIT
script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P)
usage() {
cat <<EOF
Usage: $(basename "${BASH_SOURCE[0]}") [-h] [-v] [-f] -p param_value arg1 [arg2...]
@MaxXor
MaxXor / btrfs-guide.md
Last active February 7, 2025 05:24
Btrfs guide to set up an LUKS-encrypted btrfs raid volume with included maintenance & recovery guide

Encrypted Btrfs storage setup and maintenance guide

Initial setup with LUKS/dm-crypt

This exemplary initial setup uses two devices /dev/sdb and /dev/sdc but can be applied to any amount of devices by following the steps with additional devices.

Create keyfile:

dd bs=64 count=1 if=/dev/urandom of=/etc/cryptkey iflag=fullblock
chmod 600 /etc/cryptkey
@joaofl
joaofl / Clean Samsung Galaxy A40 bloatwares
Last active January 20, 2024 16:36
Script I used to clean preinstalled shit out of my brand new Samsung A40 (while there is still no LineageOS for it)
#!/bin/sh
# ref: https://piunikaweb.com/2019/03/25/samsung-galaxy-s10-remove-bundled-bloatwares-without-root/
# install the following app to see the packages names:
# use the following command to generate the unistall command, for easy copy and paste:
# adb shell 'pm list packages' | sed -e 's/^/adb uninstall --user 0 /' | grep FILTER_HERE | sort
#things to install if removing keyboard
# F-Droid
# APK Analyser