Skip to content

Instantly share code, notes, and snippets.

View Rhilip's full-sized avatar
👻
I may be slow to respond.

Rhilip Rhilip

👻
I may be slow to respond.
View GitHub Profile
@Rhilip
Rhilip / update_layout_houda.user.js
Created October 7, 2024 12:59
厚大-考试排版优化(仅错题)
// ==UserScript==
// @name 厚大-考试排版优化(仅错题)
// @namespace http://tampermonkey.net/
// @version 2024-04-16
// @description try to take over the world!
// @author You
// @match https://www.youkaoshi.cn/doexam.html?*
// @grant none
// ==/UserScript==
@Rhilip
Rhilip / speedup_houdask.user.js
Created October 7, 2024 12:57
厚大-真题卷讲解加速
// ==UserScript==
// @name 厚大-真题卷讲解加速
// @namespace rhilip.info
// @version 2024-09-09
// @description try to take over the world!
// @author Rhilip
// @match https://online.houdask.com/video*
// @grant none
// ==/UserScript==
@Rhilip
Rhilip / Announce.php
Created March 14, 2024 13:08
某sysop写的PT Tracker(Announce部分)
<?php
/**
* Created by PhpStorm.
* User: pov
* Date: 05/04/2018
* Time: 09:45 AM
*/
namespace App\Http\Controllers\Traits\Tracker;
@Rhilip
Rhilip / download.js
Created February 3, 2021 13:37
download.js from DSM 7.0 beta
/* Copyright (c) 2020 Synology Inc. All rights reserved. */
Ext.namespace("SYNO.SDS.DownloadStation.DLM");
SYNO.SDS.DownloadStation.DLM.Util = {};
Ext.apply(SYNO.SDS.DownloadStation.DLM.Util, {
timeleftCalc: function(c, b, a) {
return (c === 0 ? -1 : Math.floor((b - a) / c))
},
convertTimeLeft: function(f, b) {
var j = 0;
@Rhilip
Rhilip / cnipa_pdf.user.js
Created January 4, 2021 14:29
中国专利公布公告 PDF 版
// ==UserScript==
// @name 中国专利公布公告 PDF 版
// @namespace blog.rhilip.info
// @version 0.1
// @description 抛弃Flash,展示PDF
// @author Rhilip
// @match http://epub.sipo.gov.cn/pam.action
// @match http://epub.cnipa.gov.cn/pam.action
// @grant GM_xmlhttpRequest
// ==/UserScript==
@Rhilip
Rhilip / DSM_6.2_API.json
Last active February 5, 2024 10:45
DSM API list
{
"data": {
"SYNO.API.Auth": {
"maxVersion": 6,
"minVersion": 1,
"path": "auth.cgi"
},
"SYNO.API.Encryption": {
"maxVersion": 1,
"minVersion": 1,
@Rhilip
Rhilip / _vultr-snapshot.md
Created December 8, 2018 13:45
Automatic snapshots using Vultr API (Python3)

Thanks to Automated Snapshots / Backups via Vultr API And this is Python3 version script used to Automatic snapshots using Vultr API


A more customizable alternative to Vultr's backup feature using Vultr API v1. Tested on Ubuntu 16.04. Run this python3 script on Anywhere to create a snapshot of VPS (which you know IP or it's subid) and rotate out the oldest snapshot(s). Use the BACKUP_TAG_PREFIX prefix field to uniquely id a set of snapshots.

Notice: You can only create 11 snapshots by default.


@Rhilip
Rhilip / cloudflare_limit.conf
Last active July 23, 2018 21:28 — forked from todiadiyatmo/nginx cloudflare
nginx cloudflare
# Conection Limit
# http://serverfault.com/questions/177461/how-to-rate-limit-in-nginx-but-including-excluding-certain-ip-addresses
# http://gadelkareem.com/2015/01/18/limiting-connections-requests-wordpress-nginx/
geo $whitelist {
default 0;
# CIDR in the list below are not limited ( 1 )
127.0.0.1/32 1;
}
@Rhilip
Rhilip / aria2.bat
Last active February 27, 2018 02:31 — forked from aa65535/aria2.bat
Aria2的配置文件 & 启动脚本
:: 启动后需要保留窗口, 关闭窗口则结束进程
aria2c --conf-path=aria2.conf -D