Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@yingziwu
yingziwu / 二十九、前兆.txt
Created January 5, 2022 16:52
《慢慢仙途》( https://www.jjwxc.net/onebook.php?novelid=1066345 )“ 二十九、前兆” 修文前后对比
泰古大陆中部凤阳城内一派繁华,如今不过辰时街道上已是熙熙攘攘,要说到为何这凤阳城如此热闹就不得不提当朝掌权者——朱氏。
自朱氏掌权这泰古大陆已经逾过万年,而凤阳正是天子所在城郡既国都所在。经过万年发展又得天子佛照,怎能不繁荣昌平。
由此可见这朱氏极不简单,若是按照历史洪流的自然定则,这早该改朝换姓不知多少次,但朱家依旧稳坐泰古这处江山。究其原因就不得不提到一个隐晦:据传说在朱氏后面有仙家势力撑腰。
传说天地间有规则,各上仙均不得明中参与进凡人世俗间的皇权争斗,不可做皇帝,有违者皆受天罚灰飞烟灭,永世不得超生。
仙者法术高强,求的是长生大道,这点凡间小小的皇权自然是不会放在眼中,哪怕是最初级的仙者,皇上看到了也不得不恭敬低头。这便是为何那么多人对修仙狂热追求的原因之一,按理说仙家根本就不会参与到此事中。
@yingziwu
yingziwu / cors-deno.ts
Last active June 19, 2022 10:38
A CORS proxy write by deno
import { serve } from "https://deno.land/std/http/server.ts";
function error(code: number): Promise<Response> {
const response = new Response(null, {
status: code,
});
return Promise.resolve(response);
}
function options(): Promise<Response> {
(async () => {
const lotteryStatusUrl = 'https://bgme.me/@bgme/105206731005287886'; // 抽奖嘟文URL
const lotteryType = 'reblog'; // 抽奖类型:转发(reblog),收藏(favourite)
const candidateNumber = 5; // 候选中奖者人数
main();
async function main() {
const domain = document.location.hostname;
const token = JSON.parse(document.querySelector('#initial-state').text).meta.access_token;
@yingziwu
yingziwu / encode.py
Created October 28, 2020 15:42 — forked from gasman/encode.py
Encoding a file as a Youtube video - https://www.youtube.com/watch?v=hyqLv2_zBdA
# Encode inputfile.tar.gz as a series of video frames
# Frames are written to frames/frameNNNN.png
from PIL import Image
with open('inputfile.tar.gz', 'rb') as f:
data = f.read()
WIDTH = 120
HEIGHT = 90
CHUNK_SIZE = int((WIDTH * HEIGHT) / 8)
@yingziwu
yingziwu / china-domain.txt
Last active June 13, 2020 04:28
china tlds
AIGO
ANQUAN
ASIA
BAIDU
BOX
CITIC
CN
FAN
FANS
HK
@yingziwu
yingziwu / custome_emoji_download.py
Created July 8, 2019 08:16
custome_emoji_download.py
#!/usr/bin/env python
# coding: utf-8
import requests
import json
import tarfile
import os
import click
@yingziwu
yingziwu / WeiboUtil.js
Last active July 3, 2019 08:59 — forked from fengmk2/WeiboUtil.js
新浪微博mid与url互转实用工具
/**
* 新浪微博mid与url互转实用工具
* 作者: XiNGRZ (http://weibo.com/xingrz)
*/
var WeiboUtil = {
// 62进制字典
str62keys: [
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9",
"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z",
@yingziwu
yingziwu / download_mastodon_timeline_tag_picture.py
Last active March 21, 2019 06:57
输入实例地址,tag名称,下载相应tag下的所有图片。
#!/usr/bin/env python
# coding: utf-8
import requests
import os
def request_status_list(instance_uri, tag_name, max_id=None):
api_endpoint = '/api/v1/timelines/tag/'
uri = instance_uri + api_endpoint + tag_name
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import requests
from six.moves.urllib.parse import urljoin
def capture(
target_url,
user_agent="savepagenow (https://github.com/pastpages/savepagenow)",
accept_cache=False,
@yingziwu
yingziwu / v2ex_cookies.json
Created October 17, 2017 15:42
v2ex node restricted detect
{
"PB3_SESSION": "\"xxxxx\"",
"A2": "\"xxxxxx\"",
"V2EX_TAB": "\"xxxx\""
}