Skip to content

Instantly share code, notes, and snippets.

View riedel's full-sized avatar

Till Riedel riedel

View GitHub Profile
@Xtr126
Xtr126 / README.md
Last active October 19, 2025 19:17
Android: mirror touchscreen as touchpad (uinput)

Use your phone's touchscreen as a touchpad without root, using termux.
Android recognizes it as a hardware touchpad, so all native gestures work.
Intended for use with Android 10+ Desktop mode to control external displays without a mouse.
Smart dock is recommended.

Install ADB

pkg install android-tools

Developer options > Wireless debugging

adb pair localhost:port1
adb connect localhost:port2

Video: termux/termux-app#2366 (comment)

@steviecoaster
steviecoaster / ConvertFrom-WinGetManifest.ps1
Last active May 24, 2025 09:43
ConvertFrom-WinGetManifest - A function to create a chocolateyInstall.ps1 file from a WinGet manifest
function ConvertFrom-WinGetManifest {
<#
.SYNOPSIS
Generates a Chocolatey install script for a WinGet manifest
.DESCRIPTION
Generate a Chocolatey package from a WinGet manifest, even though it'll probably already be on the CCR.
.PARAMETER WinGetManifestRawUrl
The Github raw url of the WinGet YAML manifest
@FabulousCupcake
FabulousCupcake / windows-bluetooth-autoconnect.md
Created August 27, 2021 18:49
Actually Disabling Bluetooth Autoconnect on Startup in Windows

Actually Disabling Bluetooth Autoconnect on Startup in Windows

Situation

I use multiple devices with my bluetooth earphone connected to my mac machine, phone, or tablet.
When I boot my windows machine, it automatically connects to and snatches my bluetooth earphone. This is very annoying.

Results from google on ways to disable this are unhelpful:

  • Unpair the device (???)
  • Disable bluetooth support system service via services.msc
  • Disable the device via Device Manager
@riedel
riedel / sshagent-bridge
Last active June 3, 2024 14:37
Bridge Windows 10 buildin OpenSSH agent to cygwin using socat and putty plink
#!/bin/sh
SOCKDIR=`mktemp.exe -d /tmp/ssh-XXXXXXXXX`
SSH_AUTH_SOCK=$SOCKDIR/agent.$$;export SSH_AUTH_SOCK;
[ -z ${1+x} ] && echo "SSH_AUTH_SOCK=$SSH_AUTH_SOCK;export SSH_AUTH_SOCK;"
socat UNIX-LISTEN:$SSH_AUTH_SOCK,umask=066,fork EXEC:"PLINK.EXE -serial //./pipe/openssh-ssh-agent",pipes &
SSH_AGENT_PID=$!; export SSH_AGENT_PID;
@kekru
kekru / 01nginx-tls-sni.md
Last active November 27, 2025 08:33
nginx TLS SNI routing, based on subdomain pattern

Nginx TLS SNI routing, based on subdomain pattern

Nginx can be configured to route to a backend, based on the server's domain name, which is included in the SSL/TLS handshake (Server Name Indication, SNI).
This works for http upstream servers, but also for other protocols, that can be secured with TLS.

prerequisites

  • at least nginx 1.15.9 to use variables in ssl_certificate and ssl_certificate_key.
  • check nginx -V for the following:
    ...
    TLS SNI support enabled