Skip to content

Instantly share code, notes, and snippets.

View LoLei's full-sized avatar
:octocat:
Hello people of GitHub

Lorenz Leitner LoLei

:octocat:
Hello people of GitHub
View GitHub Profile
@LoLei
LoLei / youtube-auto-theater-mode.userscript.js
Created December 16, 2022 15:29
Make the YT video player theather mode after 5 seconds, if it is not already
// ==UserScript==
// @name YouTube Auto Theater Mode
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Make the YT video player theather mode after 5 seconds, if it is not already
// @author Lorenz Leitner
// @match https://www.youtube.com/watch?v=**
// @icon https://www.google.com/s2/favicons?sz=64&domain=youtube.com
// @grant none
// ==/UserScript==
class WordCloudCommand(Command):
helptext_ = "<user> [title] generate a word cloud for a user"
# Receiver = Invoker
def __init__(self, receiver):
self.receiver_ = receiver
def execute(self, args):
trigger_nick = args[0]
@LoLei
LoLei / opencvi3imshow.py
Created August 8, 2020 13:27
Fix opencv imshow in i3wm
"""
Fix opencv imshow in i3wm
- Use namedWindow with WINDOW_NORMAL
- Only close when Esc (==27) is pressed
(For some reason it triggers on Alt/i3 mod as well otherwise)
- 50% chance the window is opened in tiled mode or floating mode
Just change mode to liking after the fact with keybind
"""
import cv2
@LoLei
LoLei / test-rmdir.js
Last active June 20, 2020 07:25
Script to test experimental functionality of node.js rmdir recursive removal
/*
* Script to test experimental functionality of
* node rmdir recursive removal
* https://nodejs.org/api/fs.html#fs_fs_rmdirsync_path_options
* >Stability: 1 - Recursive removal is experimental.
*
* Calling:
* node test-rmdir.js true (recursive rmdir true)
* node test-rmdir.js false (recursive rmdir false)
*/
@LoLei
LoLei / tux.png
Last active June 4, 2019 09:55
Tux
tux.png
@LoLei
LoLei / welcome.md
Created June 4, 2019 09:36
Welcome

Welcome

Welcome to my GitHub profile

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">