Skip to content

Instantly share code, notes, and snippets.

@SkyyySi
SkyyySi / watch.sh
Last active May 17, 2025 20:37
A small bash script to rebuild and rerun a mod for Zelda 64: Recompiled whenever a change is made to a C source file
#!/usr/bin/env bash
# Zero-Clause BSD
# =============
#
# Permission to use, copy, modify, and/or distribute this software for
# any purpose with or without fee is hereby granted.
#
# THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL
# WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
# OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE

Zero-Clause BSD

Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted.

THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY

@SkyyySi
SkyyySi / redditAiTranslationDisabler.user.js
Last active April 15, 2025 10:07
A small userscript for automatically redirecting to the original english version whenever Reddit auto-translates a post
// ==UserScript==
// @name Reddit AI-translation disabler
// @namespace github.com/SkyyySi
// @match *://reddit.com/*
// @match *://www.reddit.com/*
// @grant none
// @version 1.0.0
// @author SkyyySi
// @description Automatically redirect to the original english version whenever Reddit auto-translates a post
// @license 0BSD; https://opensource.org/license/0bsd
@SkyyySi
SkyyySi / microsoftLearnEnglishSwitcher.user.js
Created April 10, 2025 05:47
A simple userscript to switch the shitty AI translations for most Microsoft documentation over to english
// ==UserScript==
// @name English language switcher for Microsoft documentation
// @namespace http://tampermonkey.net/
// @version 2025-04-10
// @description Switches the shitty AI translations for most Microsoft documentation over to english
// @author SkyyySi
// @match https://learn.microsoft.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=microsoft.com
// @grant none
// @license 0BSD
@SkyyySi
SkyyySi / Test-Printer.ps1
Last active March 27, 2025 11:07
A small PowerShell script to check if one or more shared printer(s) is known on a given printer server
# SPDX-License-Identifier: 0BSD
# Author: Simon Buschendorf (github.com/SkyyySi)
#
# To invoke this script, run it like this:
#
# powershell.exe -File '.\Test-Printer.ps1' -Name 'foo'
#
# Or, for multiple printers, like this:
#
# powershell.exe -Command "& '.\Test-Printer.ps1' -Name @('foo', 'bar')"
@SkyyySi
SkyyySi / benchmark.lua
Last active March 18, 2025 07:27
A quick performance test comparing closures and regular functions in Lua
local function benchmark(func, name, times, ...)
name = name or "<anonymous>"
times = times or 100000
io.write(name, " --> ")
io.flush()
local time_start = os.clock()
for i = 1, times do
local lfs = require("lfs")
local _M = {}
function _M.list_child_files(directory_path)
local function get_full_child_paths(child_name)
if (child_name == ".") or (child_name == "..") then
return {}
end

UI-less Firefox

This is a short guide on how to set up a Firefox profile with no UI (no tabs, no address-bar, no bookmarks, etc.). Note that it is written for and only tested on Arch Linux. You'll probably need to perform different steps on Windows.

  1. Create a new Firefox profile
    1. Run this shell command:

firefox --no-remote --profilemanager

#!/usr/bin/env lua
local type = type
local print = print
local pcall = pcall
local select = select
local string = string
local io = io
local string_format = string.format
@SkyyySi
SkyyySi / ihk-fixes.user.styl
Last active January 6, 2025 16:02
Ein UserCSS / UserStyle, um die Webseite der Niederrheinischen IHK zumindest ein bisschen weniger fürchterlich zu machen.
/* ==UserStyle==
@name IHK Azubiheft Fix
@namespace github.com/SkyyySi
@version 1.0.0
@description Ein UserCSS / UserStyle, um die Webseite der Niederrheinischen IHK zumindest ein bisschen weniger fürchterlich zu machen.
@author SkyyySi
@preprocessor stylus
==/UserStyle== */
$header_padding = 1em