Skip to content

Instantly share code, notes, and snippets.

@apfelchips
apfelchips / macOS-shortcuts.ahk
Last active June 21, 2024 19:13
First remap modifier keys with sharpkeys; AHK script has to run as Administrator to work on System Windows / Apps running as Administrator; see Watchdog ScheduledTask below, when you do this make sure to remove the inherited file permissions from C:/tools and only allow administrators write access.
;#NoTrayIcon
TraySetIcon("accessibilitycpl.dll","6") ; Keyboard Icon
;#Persistent https://www.autohotkey.com/docs/commands/_Persistent.htm
SetWorkingDir(A_ScriptDir) ; Ensures a consistent starting directory.
#SingleInstance force
;#InstallKeybdHook ; see: https://www.autohotkey.com/docs/v1/lib/_HotkeyModifierTimeout.htm
; Debugging
@garaud
garaud / pipe-to-emacs.py
Last active October 3, 2023 13:11
Pipe to Emacs: Insert a result from an UNIX command into a new Emacs buffer
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Author: Damien Garaud
# Date: 2014-2015
# License: Simplified BSD
"""Allow you to pipe command results into an Emacs buffer. Suppose you have an
Emacs server since you launch 'emacsclient'.