Skip to content

Instantly share code, notes, and snippets.

View KnIfER's full-sized avatar

knziha KnIfER

View GitHub Profile
@KnIfER
KnIfER / 单文件保存纯文本网页.user.js
Last active June 27, 2024 03:34
Save web pages into one html file. It keeps original image urls and the result is lightweight, readable and extendable.
// ==UserScript==
// @name SingleFile Pure - Pure html downloader
// @name:zh SingleFile Pure - 保存纯HTML
// @namespace https://gist.github.com/KnIfER
// @version 2.2.x
// @description 将当前网页保存为一个纯文本的.html网页文件,不保存二进制
// @description:en Save webpages into one pure html file, without binary data.
// @author PY-DNG
// @license MIT
// @grant GM_registerMenuCommand
@KnIfER
KnIfER / novel_guard.user.js
Last active April 27, 2023 08:57
novel_guard.user.js
// ==UserScript==
// @name 小说守护神
// @namespace https://gist.github.com/KnIfER
// @description 首次访问小说网站时,自动开启以下两项设置:-- ①禁止跨域跳转 -- ② 自动开启无图模式
// @version 1
// @match *://*/*
// @run-at document-start
// @run-at document-end
// @grant GM_blockImage
// @grant GM_blockCorsJump
@KnIfER
KnIfER / easy_scrollbar.ahk
Created April 12, 2023 10:07
ahk how to make scrollbar drag more easily by middle button down.
#IfWinActive ahk_exe chrome.exe
$MButton::
MouseGetPos, xpos, ypos
WinGetPos,x,y,w,h
if (xpos<w && xpos >= w-30 && ypos>0 && ypos<h) {
global tmp:=1
Send +{LButton down}
}
else MouseClick, M
@KnIfER
KnIfER / JavaTestUtility.java
Created March 4, 2023 05:23
FIX IDEA -- "Focus on Start-up" option doesn't work in Intellij IDEA Ultimate
package hunxiao;
import org.junit.Test;
import java.io.*;
import java.nio.charset.StandardCharsets;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Objects;
// ==UserScript==
// @name B站学习机 | Bilibili+Youtube字幕全文阅读 | coursera-like subtitles fulltext reader
// @namespace https://gist.github.com/KnIfER/9e43ffa31c3b9831a500edf35595c1dc
// @version 6
// @description 在线字幕阅读或下载,B站油管秒变cousera! - Read & learn subtitles full text online!
// @author KnIfER
// @match https://*.bilibili.com/video/*
// @match https://*.youtube.com/*
// @match https://*/watch?v=*
// @match https://*/embed/*?si=*