This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SETUP | |
const obfuscator = require("javascript-obfuscator"); | |
const minifier = require("@minify-html/node"); | |
const archiver = require("archiver"); | |
const fs = require("node:fs"); | |
let HTML; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# (other localSettings.php stuff here) | |
# transform links | |
use MediaWiki\MediaWikiServices; | |
$wgHooks['HtmlPageLinkRendererBegin'][] = function($linkRenderer, $target, &$text, &$extraAttribs, &$query, &$ret) { | |
$title = MediaWikiServices::getInstance()->getParser()->getPage(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# screenshot.sh | |
# v1.2 (11 Mar 2025) | |
# Screenshot and copy | |
grim -g "$(slurp)" - | wl-copy; notify-send "Screenshot copied to clipboard" -i edit-copy | |
# Screenshot and save to ~/Pictures | |
grim -g "$(slurp)" "/home/$USER/Pictures/$(date "+%Y-%m-%d %H:%M:%S").png"; notify-send "Screenshot saved to ~/Pictures/$(date "+%Y-%m-%d %H:%M:%S").png" -i document-save |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# More info | |
# https://anpang54.tumblr.com/post/777156545609957376/20250305. | |
# Stalin sort part is based on | |
# https://github.com/gustavo-depaula/stalin-sort/blob/master/python/simple_loop.py | |
# function | |
def gorbachev_sort(xs): |