Fixing Aqara Smart Hub M3 High Volume System Crashes and Reboots

After purchasing an Aqara Smart Hub M3 to manage my smart home ecosystem, I configured its security features, set the internal alarm volume to 100 percent, and armed the system by switching it to Away mode to test the built-in 95dB loudspeaker. The moment the alarm triggered, the hub completely crashed and rebooted. My initial thought was that I had received a defective unit. However, after extensive troubleshooting, I found the solution to this surprising behavior. Understanding the reboot issue When the Aqara Smart Hub M3 unexpectedly restarts the moment an alert sound is triggered at a high volume, it … Continue reading

The Definitive Guide to Code Folding in Emacs

Navigating large source files containing thousands of lines of code with Emacs makes it difficult to perceive the underlying structure. For a software engineer spending the majority of the day reading and writing code, reliable folding is a requirement for maintaining focus and managing complexity. Before we dive in, please consider sharing this article on your website/blog, Mastodon, Reddit, X, or your preferred social media platforms. Sharing it will help fellow Emacs users discover better ways to manage code folding. In this article, we explore: Why code folding? Code folding is about managing cognitive load, preserving spatial memory, and controlling … Continue reading

buffer-guardian.el - Automatically Save Emacs Buffers Without Manual Intervention (When Buffers Lose Focus, Regularly, or After Emacs is Idle)

The buffer-guardian Emacs package provides buffer-guardian-mode, a global mode that automatically saves buffers without requiring manual intervention. By default, buffer-guardian-mode saves file-visiting buffers when: - Switching to another buffer. - Switching to another window or frame. - A frame is closed. - The window configuration changes (e.g., window splits). - The minibuffer is opened. - Emacs loses focus. (Skip to: Installation) Beyond standard file-visiting buffers, buffer-guardian-mode provides built-in support for: Isolated inline code buffers: It fully supports specialized editing environments like org-src (for Org mode) and edit-indirect (commonly used for Markdown code blocks). Since these temporary buffers are dynamically linked … Continue reading

update-iptables - A low-level Linux firewall for advanced users

The update-iptables script implements a firewall for managing network traffic and routing. It supports a modular configuration model through drop-in scripts located in /etc/update-iptables.d/. Each file is a shell script executed sequentially during firewall initialization. This low-level firewall script is intended for Linux system administrators who require precise control over packet states, network address translation, and custom routing chains. Rules are defined directly through iptables without the abstraction layers commonly introduced by modern firewall management tools. If this low-level firewall proves useful, please support the project by ⭐ starring update-iptables on GitHub, helping more developers discover it. Requirements bash iptables … Continue reading

Vim Plugin: pathaction - A Vim plugin for executing pathaction, the universal Makefile, for any file in your filesystem

The vim-pathaction Vim plugin provides an interface for executing .pathaction.yaml rules directly from Vim through the pathaction cli, a flexible tool for running commands on files and directories. Think of pathaction like a Makefile for any file or directory in the filesystem. It uses a .pathaction.yaml file to figure out which command to run, and you can even use Jinja2 templating to make those commands dynamic. You can also use tags to define multiple actions for the exact same file type, like setting up one tag to run a script, and another to debug it. This tool is for software … Continue reading

Emacs Package: pathaction.el - An Emacs plugin for executing pathaction, the universal Makefile, for any file in your filesystem

The pathaction.el Emacs package provides an interface for executing .pathaction.yaml rules directly from Emacs through the pathaction cli, a flexible tool for running commands on files and directories. Think of pathaction like a Makefile for any file or directory in the filesystem. It uses a .pathaction.yaml file to figure out which command to run, and you can even use Jinja2 templating to make those commands dynamic. You can also use tags to define multiple actions for the exact same file type, like setting up one tag to run a script, and another to debug it. This tool is for software … Continue reading

ultisnips-mode.el - An Emacs major mode for editing Ultisnips snippet files (*.snippets files)

The ultisnips-mode.el is an Emacs major mode for editing Ultisnips snippet files (*.snippets files). This mode provides syntax highlighting to facilitate editing Ultisnips snippets. (Vim's UltiSnips is a snippet solution for Vim, and its snippets can be used in Emacs by converting them to the Yasnippet format using Ultyas.) Features Syntax highlighting for UltiSnips: snippet, endsnippet, global, endglobal, priority, comments, and placeholders in the form of ${1:value} or $1... Integration with outline-minor-mode or hs-minor-mode to enable folding of snippet -> endsnippet and global -> endglobal blocks. Support for commenting and uncommenting UltiSnips snippets using standard Emacs commands, such as comment-or-uncomment-region. … Continue reading

kirigami.el - A Unified Method to Fold and Unfold Text in Emacs Across a Diverse Set of Modes

The kirigami Emacs package provides a unified method to fold and unfold text in Emacs across a diverse set of Emacs modes. Supported modes include: outline-mode, outline-minor-mode, outline-indent-minor-mode, org-mode, markdown-mode, gfm-mode, outli-mode, embark-collect-mode, vdiff-mode, vdiff-3way-mode, hide-ifdef-mode, vimish-fold-mode, TeX-fold-mode (AUCTeX), fold-this-mode, origami-mode, yafolding-mode, folding-mode, ts-fold-mode, treesit-fold-mode, hs-minor-mode (hideshow), ibuffer-mode (M-x ibuffer), and profiler-report-mode (M-x profile-report). With Kirigami, folding key bindings only need to be configured once. After that, the same keys work consistently across all supported major and minor modes, providing a unified and predictable experience for opening and closing folds. The available interactive commands include: - kirigami-open-fold: Open the fold … Continue reading

Google Home Script for announcing door open and close events using Matter door/window sensors

The Matter standard enables smart home devices from different manufacturers to work together in a reliable and secure way. One common use case is detecting when a door is opened or closed and announcing this event through Google Home speakers or sending notifications to connected devices. This article demonstrates how to configure Google Home to announce door events using Matter-compatible sensors such as the Aqara Door and Window Sensor P2. The example uses Google Home script automations to broadcast voice announcements and trigger mobile notifications whenever the entrance door changes state. Requirements Door Closed Announcement Script The following script broadcasts … Continue reading

ansible-role-auto-upgrade - Ansible role for automated upgrades of Linux systems

The ansible-role-auto-upgrade Ansible role automates regular upgrades of supported operating systems: - Debian-based systems (e.g., Ubuntu, Debian, Linux Mint). This role provides a simpler alternative to unattended-upgrades for applying system updates. (In future versions, Arch Linux and Gentoo will also be supported.) License Copyright (c) 2025-2026 James Cherti. Distributed under terms of the MIT license. Do you like ansible-role-auto-upgrade? Please star ansible-role-auto-upgrade on GitHub. Links The GitHub repository of 'auto-upgrade'

ansible-role-reniced - An Ansible role that configures reniced

The ansible-role-reniced Ansible role configures reniced on Debian and Ubuntu based operating systems. Customizations When reniced_conf is defined, it is used as the configuration content. Include the role using: - name: Import role reniced when: ansible_facts.os_family == "Debian" ansible.builtin.import_role: name: reniced Variables: reniced_conf: | # high prio network services 0 ^apache 0 ^nfsd 0 ^ntpd 0 ^openvpn 0 ^portmap 0 ^ppp 0 ^rpc. 0 ^sshd # medium prio network services 5 ^inn$ 5 ^mysqld # low prio network services 15i ^amavisd-new 15i ^clamd 15 ^controlchan 15 ^exim4 15 ^freshclam 15 ^innwatch 12 ^mailman 15 ^rc.news 15i ^spamd # long running … Continue reading

ansible-role-apt - An Ansible role that manages the APT configuration and updates the /etc/apt/sources.list for Debian and Ubuntu systems

The ansible-role-apt Ansible role manages the APT configuration and updates the /etc/apt/sources.list for Debian and Ubuntu systems. Role variables Important variables: Variable Description Default apt_debian_community Enables community repositories (Debian contrib and main, or Ubuntu universe) true apt_debian_nonfree Enables non-free repositories (Debian non-free, non-free-firmware, or Ubuntu multiverse) true apt_debian_backports Enables the backports repository on Debian (no effect on Ubuntu systems) false apt_deb_src Enables source package repositories (deb-src entries) false Other variables: Variable Description Default apt_mirror_url_debian Debian mirror URL "http://deb.debian.org/debian" apt_mirror_url_debian_security Debian security mirror URL "http://deb.debian.org/debian-security" apt_mirror_url_ubuntu Ubuntu mirror URL "http://archive.ubuntu.com/ubuntu" Author and license The ansible-role-apt role has been written by James … Continue reading

quick-sdcv.el - Emacs offline dictionary using 'sdcv'

The quick-sdcv.el package provides a lightweight interface for the sdcv command-line tool, enabling Emacs to function as an offline dictionary. This package allows for immediate word definitions and translations without requiring an internet connection. Key interactive functions include: quick-sdcv-search-at-point: Searches the word under the cursor and displays the result in a dedicated buffer. quick-sdcv-search-input: Prompts for a custom input string and presents the corresponding dictionary entry in a buffer. If this package enhances your workflow, please show your support by ⭐ starring quick-sdcv on GitHub to help more Emacs users discover its benefits. Prerequisite The sdcv command. (It can usually … Continue reading

inhibit-mouse.el - Deactivate mouse input in Emacs

The inhibit-mouse package allows the disabling of mouse input in Emacs using inhibit-mouse-mode. Instead of modifying the keymap of its own mode as the disable-mouse package does, enabling inhibit-mouse-mode only modifies input-decode-map to disable mouse events, making it more efficient and faster than disable-mouse. Additionally, the inhibit-mouse package allows for the restoration of mouse input when inhibit-mouse-mode is disabled. If this enhances your workflow, please show your support by ⭐ starring inhibit-mouse on GitHub to help more Emacs users discover its benefits. Installation To install inhibit-mouse from MELPA: If you haven't already done so, add MELPA repository to your Emacs … Continue reading

Why failing to create backups and test them lead to regret

Data loss is an inevitable reality in the digital age. It is not a question of if, but when. Whether you're managing infrastructure for a large enterprise or simply storing personal documents, photos, and legal files on your own computer, the risk of data loss is ever-present. Despite this, many people and organizations fail to prioritize backups until it is too late. Throughout my career as an IT specialist, I have witnessed this problem repeatedly. The pattern is always the same: individuals and companies lose data, panic ensues, and attempts are made to recover what could have been easily protected … Continue reading