Skip to content

Instantly share code, notes, and snippets.

View thianda91's full-sized avatar
😆
Coding for happy

YrUqx thianda91

😆
Coding for happy
  • Suzhou, China
View GitHub Profile
@thianda91
thianda91 / BaiduPCS-appid-getter.py
Last active March 31, 2019 19:06 — forked from pcmid/BaiduPCS-appid-getter.py
获取有效的百度app_id
from __future__ import print_function
import requests
import threading
import sys
def eprint(*args, **kwargs):
print(*args, file=sys.stderr, **kwargs)
@thianda91
thianda91 / cmcc-ln-4a.user.js
Created July 13, 2018 09:34
CMCC ln 网络安全管控平台(4a)调优
// ==UserScript==
// @name cmcc-ln-4a
// @name:zh CMCC ln 网络安全管控平台(4a)调优
// @name:zh-CN CMCC ln 网络安全管控平台(4a)调优
// @description let the '4A' website running in firefox without problems, auto prevent being offline by timed refreshing
// @description:zh 使网站能在Firefox中正常使用,后台定时刷新自动防掉线
// @description:zh-CN 使网站能在Firefox中正常使用,后台定时刷新自动防掉线
// @author X.Da
// @create 2018-07-13
// @version 0.0.1
@thianda91
thianda91 / Date.prototype.pattern.js
Created June 15, 2018 14:42
对Date的扩展,将 Date 转化为指定格式的String
/**
* 对Date的扩展,将 Date 转化为指定格式的String
* 月(M)、日(d)、12小时(h)、24小时(H)、分(m)、秒(s)、周(E)、季度(q) 可以用 1-2 个占位符 * 年(y)可以用 1-4 个占位符,毫秒(S)只能用 1 个占位符(是 1-3 位的数字)
* eg:
* (new Date()).pattern("yyyy-MM-dd hh:mm:ss.S")==> 2006-07-02 08:09:04.423
* (new Date()).pattern("yyyy-MM-dd E HH:mm:ss") ==> 2009-03-10 二 20:09:04
* (new Date()).pattern("yyyy-MM-dd EE hh:mm:ss") ==> 2009-03-10 周二 08:09:04
* (new Date()).pattern("yyyy-MM-dd EEE hh:mm:ss") ==> 2009-03-10 星期二 08:09:04
* (new Date()).pattern("yyyy-M-d h:m:s.S") ==> 2006-7-2 8:9:4.18
*/