Skip to content

Instantly share code, notes, and snippets.

View heape's full-sized avatar
🤒
Out sick

heape

🤒
Out sick
View GitHub Profile
@heape
heape / fewfwe
Created April 10, 2019 08:32
fewfwfe
wfwfwfw
@heape
heape / util.js
Created October 19, 2019 23:34
a Mini Http Client Wrapper for Node.js
// it's a mess :( and i'm not good at js! please edit the source as you like :D
/* usage: */
/*
const util = require('./util.js');
let url = 'https://www.google.com';
let cookie = '';
let ck = util.createCookieStore();
@heape
heape / Twitterいいね!回しスクリプト.js
Last active October 23, 2019 14:03
Twitterいいね!回しスクリプト
/*
ブラウザのコンソール入力。 API制限有るので、ほどほどに!
*/
window['resetScript'] = () => {
window['scriptBusy'] = false;
};
window['invokeScript'] = async() => {
const sleep = ms => new Promise((r, j) => setTimeout(r, ms)); // async用 delay関数
@heape
heape / util.js
Created October 27, 2019 07:47
util.js for React + Electron
const http = require('http'),
https = require('https'),
iconv = require('iconv-lite'),
zlib = require('zlib');
const sleep = ms => new Promise((r, j) => setTimeout(r, ms));
const randRange = (min, max) => Math.floor(Math.random() * (max - min + 1) + min);
const str2doc = str => {
let parser = new DOMParser();
return parser.parseFromString(str, "text/html");
@heape
heape / request.cs
Last active November 1, 2019 10:53
C# Http Request Wrapper (NOOB)
private async Task<HttpResponseMessage> Request(string url, HttpMethod method, Dictionary<string, string> headers, string body)
{
HttpClientHandler clientHandler = new HttpClientHandler();
clientHandler.AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate;
clientHandler.Proxy = null;
clientHandler.UseProxy = false;
clientHandler.UseCookies = false;
clientHandler.AllowAutoRedirect = false;
@heape
heape / hentai_pooky.js
Created December 8, 2019 19:23
Hentai Pooky for Supreme TEST #001
const util = require('./util.js'); // Download: https://gist.github.com/heape/f1327199405ad2f847ace1c3b07113ce
const url = require('url');
const path = require('path');
const puppeteer = require('puppeteer-extra');
const stealth = require('puppeteer-extra-plugin-stealth');
const sleep = ms => new Promise((r, j) => setTimeout(r, ms));
(async() => {
const userAgent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.97 Safari/537.36';
@heape
heape / -3923-24390-fmpaefa.js
Created April 21, 2020 02:52
-3923-24390-fmpaefa
var all = document.getElementsByTagName("*");
var dummy = document.body.appendChild(document.createElement('div')); // block
var style = window.getComputedStyle(dummy);
for(let i = 0; i < style.length; i++)
pageObj.DOM.default.style[style[i]] = style.getPropertyValue(style[i]);
for (let i = 0; i < all.length; i++) {
if(all[i].tagName === 'HEAD' || all[i].parentElement == document.head) {
// console.log('skipped');
@heape
heape / HELLO rich man
Created May 13, 2020 20:08
HELLO rich man
https://mega.nz/file/qtwixaBC#cJ3mJ-oOtkOMrLeI01E3NQ1E9FzXDS0Jz71VYG2tCSs