Skip to content

Instantly share code, notes, and snippets.

View kasuganosora's full-sized avatar
🙎‍♀️
Working at home

KasuganoSora kasuganosora

🙎‍♀️
Working at home
View GitHub Profile
@kasuganosora
kasuganosora / gist:656b7758a60d6fe87e3d9f76f8842c75
Created October 29, 2016 08:39
Golang GRPC 生成protobuf类产生循环引用的解决方法
正确的姿势是
protoc --go_out=plugins=grpc:. *.proto
@kasuganosora
kasuganosora / rpgmaker_map.md
Last active March 12, 2017 11:18
RPGMaker地图格式

RPGMaker地图格式 解析

#示例地图数据 { "autoplayBgm":false,"autoplayBgs":false,"battleback1Name":"","battleback2Name":"","bgm":{"name":"","pan":0,"pitch":100,"volume":90},"bgs":{"name":"","pan":0,"pitch":100,"volume":90},"disableDashing":false,"displayName":"","encounterList":[],"encounterStep":30,"height":13,"note":"","parallaxLoopX":false,"parallaxLoopY":false,"parallaxName":"","parallaxShow":true,"parallaxSx":0,"parallaxSy":0,"scrollType":0,"specifyBattleback":false,"tilesetId":1,"width":17, "data":[2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816,2816

@kasuganosora
kasuganosora / RouterOS SET L2TP over IPSEC client.md
Last active December 9, 2016 01:32
ROUTEROS 设置L2TP over IPSEC客户端方法

设置IPSEC

Peoposal 设置

Name: IPSECL2tpClient
Auth. Algorithms: sha1
Encr.Algorithms: 3des ase-256 cbc
PFS Group: modp1024

Peer

Address: 你的服务器IP

This file has been truncated, but you can view the full file.
../eyyxo.torrent:
Name: Hacked Team
Size: 415768052618 (387G)
Announce: udp://coppersurfer.tk:6969/announce
Files:
Amministrazione/01 - CLIENTI/1 - Commesse/1 - Commesse 2011/Commessa001.2011 Royal.xls 59392 (58K)
Amministrazione/01 - CLIENTI/1 - Commesse/1 - Commesse 2011/Commessa002.2011 Royal.xls 59392 (58K)
@kasuganosora
kasuganosora / set bilibili's message readed
Created May 10, 2015 04:43
设置bilibilid的消息全部已读
$.getJSON("http://member.bilibili.com/message.do?act=notify_list&page=1")
.done(function(data){
var maxPage = data.numPages;
for(var page = 1; page <= maxPage; page++){
$.getJSON("http://member.bilibili.com/message.do?act=notify_list&page=" + page)
.done(function(d){
for(var j in d){
if(!$.isNumeric(j)){
continue;
}
@kasuganosora
kasuganosora / shit bilibili
Last active August 29, 2015 14:20
殴打B站的小学生
// ==UserScript==
// @name shit bilibili
// @namespace http://blog.hcg.im/
// @version 0.2
// @description enter something useful
// @match http://www.bilibili.com/video/*
// @copyright 2015+, ReitsukiSion
// ==/UserScript==
(function(){
@kasuganosora
kasuganosora / week.sh
Created April 10, 2015 15:30
判断今天是不是一周的第一个星期6 不是的话则不继续执行
# 一周的第一个星期 6
if [ $(date +%d) -gt 7 ] || [ $(date +%w) -neq 6 ]
then
echo 'shit!'
exit
fi
@kasuganosora
kasuganosora / createiptable
Created April 8, 2015 03:36
更具域名剩下IP规则
<?php
$domainsStr = <<<DOMAIN
twitter.com
facebook.com
instagram.com
youtube.com
google.com
ytimg.com
DOMAIN;
@kasuganosora
kasuganosora / ex_thumb
Last active January 17, 2016 03:41
ex thumb
// ==UserScript==
// @name g.Hentai.com Thumb
// @namespace http://9.co/
// @version 0.2
// @description g.Hentai.com Thumb
// @match http://g.e-hentai.org/*
// @match http://exhentai.org/*
// @exclude http://g.e-hentai.org/g/*
// @exclude http://exhentai.org/g/*
// @copyright 2012+, sion
#### 以下是HTTP PROXY的实现
net = require 'net'
localPort = 8011
findBodyStartPos = (buffer)->
length = buffer.length
for index in [0..buffer.length]
# http header end \r\n\r\n pos
return index+4 if buffer[index] == 0x0d and buffer[index+1] == 0x0a and buffer[index+2] == 0x0d and buffer[index+3] == 0x0a
return -1 # not found