Skip to content

Instantly share code, notes, and snippets.

@plu5
plu5 / gs-bilibili-loginwallblock.js
Last active January 20, 2026 12:20
greasemonkey bilibili login wall blocker userscript (but it's a mess)
// ==UserScript==
// @name bilibli login wall blocker
// @namespace Violentmonkey Scripts
// @match https://www.bilibili.com/*
// @grant none
// @version 1.0
// @author -
// @description 24/10/2025, 18:11:04
// ==/UserScript==
// NOTE:
@plu5
plu5 / gs-forvo-loginwallblock.js
Created January 19, 2026 17:36
greasemonkey forvo login wall blocker userscript
// ==UserScript==
// @name Forvo login wall blocker
// @namespace Violentmonkey Scripts
// @match https://forvo.com/*
// @grant none
// @version 1.0
// @author -
// @description 16/09/2025, 12:01:35
// ==/UserScript==
(function() {
@plu5
plu5 / gs-pint-loginwallblock.js
Created January 19, 2026 17:26
greasemonkey pinterest login wall blocker userscript
// ==UserScript==
// @name Browse your interests without registration
// @name:it Naviga i tuoi interessi senza registrazione
// @namespace http://andrealazzarotto.com/
// @description Find more ideas on the web without login/registration
// @description:it Trova altre idee sul web senza accedere o registrarti
// @version 2.4
// @include https://www.pinterest.tld/*
// @copyright 2014+, Andrea Lazzarotto
// @require https://cdnjs.cloudflare.com/ajax/libs/cash/8.1.0/cash.min.js
@plu5
plu5 / ublock-static-filters-plu5.txt
Last active January 24, 2026 13:32
uBlock Origin filters (filter out mind pollution and annoying floating elements)
! uBlock Origin filters
! Youtube sidebar, pause overlay, and endscreen suggestions
www.youtube.com##ytd-watch-next-secondary-results-renderer.ytd-watch-flexy.style-scope
www.youtube.com##.ytp-show-tiles.ytp-endscreen-paginate.videowall-endscreen.ytp-player-content.html5-endscreen
www.youtube.com##.ytp-show-tiles.videowall-endscreen.ytp-player-content.html5-endscreen
www.youtube.com##.ytp-pause-overlay-container
www.youtube.com##.ytp-fullscreen-grid-stills-container
! Stackexchange sidebar suggestions
@plu5
plu5 / ntfs3gcr.py
Created February 11, 2025 12:17
NTFS-3G creation date of a file in Python
import subprocess
from datetime import datetime, timezone
def get_ntfs3g_file_creation_date(path):
# type: (str) -> str
c = subprocess.run([
'getfattr', '--only-values', '--name=system.ntfs_crtime', path
], capture_output=True)
# Convert getfattr output's little-endian bytes to int, and convert
@plu5
plu5 / toggle_kbd.sh
Created January 14, 2025 01:26
Linux X toggle keyboard script
#!/bin/bash
# use `xinput list` to check your keyboard name. this one is for laptop internal keyboard
deviceName="AT Translated Set 2"
builtInId=$(xinput list | grep "$deviceName" | sed 's/^.*id=//' | sed 's/\t.*//')
case $1 in
disable)
xinput disable $builtInId
echo "Keyboard '${deviceName}' disabled"
@plu5
plu5 / line_edit.py
Last active December 11, 2022 20:35
A widget for PyQt5; QPlainTextEdit subclass which mimics QLineEdit. | Adapted from ssokolow’s OneLineSpellTextEdit: https://gist.github.com/ssokolow/abb20a30415fa4debce912c38060ca6a
"""QPlainTextEdit subclass which mimics QLineEdit. The idea is to make it
hotswappable for QLineEdit with no changes needed, so that you can have a
QLineEdit without its inherent limitations, like not being able to modify the
undo behaviour, not being able to use QCursor, etc.
Adapted from ssokolow’s OneLineSpellTextEdit:
https://gist.github.com/ssokolow/abb20a30415fa4debce912c38060ca6a
NOTE:
* textEdited probably works differently from QLineEdit’s textEdited, because I
am not sure yet how to replicate it exactly. For now it emits when the text
@plu5
plu5 / thl-buddenbrooks.py
Created April 10, 2022 09:49
Reddit tally number of comments on a list of threads per user using PRAW [yet yet yet yet again]
import praw
from collections import defaultdict
discussion_threads = \
["https://www.reddit.com/r/thehemingwaylist/comments/rthfhy/buddenbrooks_chapter_1/",
"https://www.reddit.com/r/thehemingwaylist/comments/ru7p9c/buddenbrooks_chapter_2/",
"https://www.reddit.com/r/thehemingwaylist/comments/rv0o67/buddenbrooks_thomas_mann_chapter_3_discussion/",
"https://www.reddit.com/r/thehemingwaylist/comments/rvsc05/buddenbrooks_thomas_mann_chapter_4_discussion/",
"https://www.reddit.com/r/thehemingwaylist/comments/rwluwr/buddenbrooks_thomas_mann_chapter_5_discussion/",
"https://www.reddit.com/r/thehemingwaylist/comments/rxdycb/buddenbrooks_thomas_mann_chapter_6/",
@plu5
plu5 / yodq.py
Created December 22, 2021 01:18
Reddit tally number of comments on a list of threads per user using PRAW [yet yet yet again]
import praw
from collections import defaultdict
discussion_threads = \
["https://www.reddit.com/r/yearofdonquixote/comments/ko1iws/don_quixote_volume_1_chapter_1/",
"https://www.reddit.com/r/yearofdonquixote/comments/kp9k3b/don_quixote_volume_1_chapter_2/",
"https://www.reddit.com/r/yearofdonquixote/comments/kqm5jk/don_quixote_volume_1_chapter_3/",
"https://www.reddit.com/r/yearofdonquixote/comments/ks194a/don_quixote_volume_1_chapter_4/",
"https://www.reddit.com/r/yearofdonquixote/comments/ktfu6a/don_quixote_volume_1_chapter_5/",
"https://www.reddit.com/r/yearofdonquixote/comments/kur1nv/don_quixote_volume_1_chapter_6/",
@plu5
plu5 / yoak.py
Created December 21, 2021 21:27
Reddit tally number of comments on a list of threads per user using PRAW [yet yet again]
import praw
from collections import defaultdict
discussion_threads = \
["https://www.reddit.com/r/yearofannakarenina/comments/ko1iwm/anna_karenina_part_1_chapter_1/",
"https://www.reddit.com/r/yearofannakarenina/comments/kok3s8/anna_karenina_part_1_chapter_2/",
"https://www.reddit.com/r/yearofannakarenina/comments/kpv8vg/anna_karenina_part_1_chapter_3/",
"https://www.reddit.com/r/yearofannakarenina/comments/kr8xw6/anna_karenina_part_1_chapter_4/",
"https://www.reddit.com/r/yearofannakarenina/comments/kvg5vg/anna_karenina_part_1_chapter_5/",
"https://www.reddit.com/r/yearofannakarenina/comments/kw1u5d/anna_karenina_part_1_chapter_6/",