Skip to content

Instantly share code, notes, and snippets.

View saschaludwig's full-sized avatar

Sascha Ludwig saschaludwig

View GitHub Profile
@b0gdanw
b0gdanw / Disable-Sequoia-Bloatware.sh
Last active September 6, 2025 00:06
Disable Sequoia Bloatware
#!/bin/zsh
# WARNING! The script is meant to show how and what can be disabled. Don’t use it as it is, adapt it to your needs.
# Credit: Original idea and script disable.sh by pwnsdx https://gist.github.com/pwnsdx/d87b034c4c0210b988040ad2f85a68d3
# Disabling unwanted services on macOS Big Sur (11), macOS Monterey (12), macOS Ventura (13), macOS Sonoma (14) and macOS Sequoia (15)
# Disabling SIP is required ("csrutil disable" from Terminal in Recovery)
# Modifications are written in /private/var/db/com.apple.xpc.launchd/ disabled.plist, disabled.501.plist
# To revert, delete /private/var/db/com.apple.xpc.launchd/ disabled.plist and disabled.501.plist and reboot; sudo rm -r /private/var/db/com.apple.xpc.launchd/*
# user
#!/bin/bash
USER="[email protected]"
# The path in dovecote mail folder to put the subfolders to
ARCHIVE_ROOT="INBOX.Archives"
# The paths of the folders to be processed during archive
BOXES_TO_ARCHIVE=("INBOX.Archive" "Archive*")
@yorickdowne
yorickdowne / friday.md
Last active September 15, 2025 08:52
Debian 13 trixie upgrade

Debian 13

Caution Upgrading from Debian 12 to Debian 13 on machines with mdadm has intermittently failed for me; symptom is that grub EFI is not up to date and system boots into BIOS. Root cause under investigation; it might not be related to mdadm.

To start, read the official release notes.

If your install fits into "vanilla Debian plus maybe a handful of 3rd-party repos", then this guide for a simple upgrade to Debian 13 "trixie" from Debian 12 "bookworm" can be helpful. 3rd-party repos are handled with a find command.

Note upgrade is only supported from Debian 12 to Debian 13. If you are on Debian 11, upgrade to Debian 12 first. Then once on Debian 12, you can upgrade to Debian 13.

@clydebarrow
clydebarrow / .gitignore
Last active July 18, 2025 08:36
ESPHome LVGL samples
# Gitignore settings for ESPHome
# This is an example and may include too much for your use-case.
# You can modify this file to suit your needs.
/.esphome/
/secrets.yaml
/wifi.yaml
@SinanMQTT
SinanMQTT / firstcode.txt
Last active March 5, 2024 22:09
HA Phone Dashboard by Sinan
square: false
type: grid
cards:
- type: horizontal-stack
cards:
- type: custom:mushroom-chips-card
chips:
- type: entity
entity: person.sinan_ibrahim
content_info: none
#EXTM3U
#EXTINF:-1,BBC - Radio 1
http://a.files.bbci.co.uk/media/live/manifesto/audio/simulcast/hls/nonuk/sbr_low/ak/bbc_radio_one.m3u8
#EXTINF:-1,BBC - Radio 2
http://a.files.bbci.co.uk/media/live/manifesto/audio/simulcast/hls/nonuk/sbr_low/ak/bbc_radio_two.m3u8
#EXTINF:-1,BBC - Radio 3
http://a.files.bbci.co.uk/media/live/manifesto/audio/simulcast/hls/nonuk/sbr_low/ak/bbc_radio_three.m3u8
#EXTINF:-1,BBC - Radio 4
http://a.files.bbci.co.uk/media/live/manifesto/audio/simulcast/hls/nonuk/sbr_low/ak/bbc_radio_fourfm.m3u8
#EXTINF:-1,BBC - Radio 4 LW
To communicate with your AC over LAN network without connection to internet you need:
https://github.com/kueblc/midea-msmart/tree/support-8370
In example.py fill:
device = ac('YOUR_AC_IP', YOUR_AC_ID)
device.authenticate('YOUR_AC_MAC', 'YOUR_SSID', 'YOUR_WIFI_PW')
Then you must run this code on something computer:
#!/usr/bin/python3

Introduction

Sometimes you may want to use a DNS server for specific domain requests and another DNS server for all other requests. This is helpful, for instance, when connected to a VPN. For hosts behind that VPN you want to use the VPN's DNS server but all other hosts you want to use Google's public DNS. This is called "DNS splitting."

Here, we run dnsmasq as a background service on macOS. The dnsmasq configuration described below implements DNS splitting.

Install

brew install dnsmasq
@wturnerharris
wturnerharris / xinitrc
Created January 20, 2015 20:35
X initialization script. This configures matchbox, resets chrome profile data, instructs the framebuffer to conform to explicit configuration, and starts an instance of chromium.
#!/bin/sh
while true; do
# Clean up previously running apps, gracefully at first then harshly
killall -TERM chromium 2>/dev/null;
killall -TERM matchbox-window-manager 2>/dev/null;
echo "Chrome and Matchbox terminated";
sleep 2;
killall -9 chromium 2>/dev/null;
@EarlGray
EarlGray / tone.py
Created September 12, 2012 14:13
A small WAV visualisation using PyQt
#! /usr/bin/python
from PyQt4 import QtCore
from PyQt4 import QtGui
import sys
import math
import struct
import wave