This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*** | |
1. Create an app on your https://www.dropbox.com/developers/apps/create, choose "Dropbox API", | |
set permissions to "Apps folder", generate a token Refresh until image loads | |
2. Deploy this code to Cloudflare Workers. | |
3. Set your token as env variable DROPBOX_TOKEN in Cloudflare worker | |
4. Move all your files to your ~/Dropbox/Apps/'dropbox-app-name-earlier' folder | |
5. Look at your file at https://example.com/path/to/file.html if you have a | |
file ~/Dropbox/Apps/'dropbox-app-name-earlier'/path/to/file.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//****** | |
//* | |
//* 1. Change the text below by pasting each line from the email you receive | |
//* 2. Then open the console, and copy and paste the whole file and press enter | |
//* | |
//****** | |
text = ` | |
Order matched – Bought 30000 units of MTAG (0213) at RM 0.580000 on (2020-07-30 12:12:38). Login to UTRADE for more information. | |
Order matched – Bought 13000 units of HEXZA (3298) at RM 1.330000 on (2020-07-30 12:14:27). Login to UTRADE for more information. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SimpleHTTPServer | |
import SocketServer | |
import random | |
from urlparse import urlparse, parse_qs | |
class Redirect(SimpleHTTPServer.SimpleHTTPRequestHandler): | |
def do_GET(self): | |
term = parse_qs(urlparse(self.path).query)['q'][0] | |
self.send_response(302) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Inspired by https://gist.github.com/lifehome/db101c66fe547a8ffbffe10d1bc0b426 | |
* | |
* Please keep the source code updated with this gist at | |
* https://gist.github.com/owyongsk/cf36ae0dc9fdb743ae70cb39fe164f8d | |
* | |
* There's no way to have a gist owned by an organization | |
*/ | |
var webhook_url = "https://your.own/webhook/path"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# I use this to install Elixir on our codeship instances for testing. YMMV. | |
# | |
# cd ~ | |
# curl -O https://gist.githubusercontent.com/jamesotron/44f8962cddef781ab830/raw/e75599e95587cbca26e707505fd40dd0f26eb0f5/install_ex.sh | |
# . ~/install_ex.sh | |
# cd ~/clone | |
# You can override your Elixir and Erlang versions from your shell when you call ./install_ex.sh. |