Skip to content

Instantly share code, notes, and snippets.

View adongy's full-sized avatar
🚧

Anthony Dong adongy

🚧
  • France
View GitHub Profile
@kquinsland
kquinsland / dummy0.netdev
Created December 3, 2019 02:54
How to get consul-agent and systemd.resolvd to co-exist peicefully and still be able to resolve *.consul hostsnames from within docker
# Creates a "dummy" network interface
# we'll configure this interface with a link-local address
# See: https://www.freedesktop.org/software/systemd/man/systemd.netdev.html
##
[NetDev]
Name=dummy0
Kind=dummy
@probonopd
probonopd / CX300.md
Last active October 21, 2022 21:44
Polycom CX300 Linux HID

Polycom CX300 under Linux

The Polycom CX300 and similar Plantronics Calisto 540 (P540-M), snom UC600 are originally optimized for Microsoft Lync (Skype for Business) for Windows and Mac but can also be used with Linux. It shows up as a USB audio playback and recording device (this part works immediately out of the box) plus some USB HID (this needs to be made work; see below).

polycom

Questions

Please use the comments function below if you know the answer to any of the questions

from tkinter import *
import asyncio
from functools import wraps
import websockets
def runloop(func):
'''
This decorator converts a coroutine into a function which, when called,
runs the underlying coroutine to completion in the asyncio event loop.
'''
@mbostock
mbostock / .block
Last active December 17, 2023 21:17
Save SVG as PNG
license: gpl-3.0
@sedm0784
sedm0784 / CapsLockCtrlEscape.ahk
Last active May 10, 2024 23:10
AutoHotkey script to map Caps Lock to Escape when it's pressed on its own and Ctrl when used in combination with another key, à la Steve Losh. Adapted from one that does something similar with the Ctrl Key on the Vim Tips Wiki (http://vim.wikia.com/wiki/Map_caps_lock_to_escape_in_Windows?oldid=32281). (Plus contribs from @randy909 & @mmikeww.)
g_LastCtrlKeyDownTime := 0
g_AbortSendEsc := false
g_ControlRepeatDetected := false
*CapsLock::
if (g_ControlRepeatDetected)
{
return
}