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 ethers from 'ethers' | |
import _ from 'underscore' | |
import dotenv from 'dotenv' | |
dotenv.config() | |
const delay = (time) => { | |
return new Promise((resolve) => setTimeout(resolve, time)) | |
} |
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
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.13; | |
import "@openzeppelin/contracts/access/AccessControlEnumerable.sol"; | |
/** | |
* @dev ASM Genome Mining - PermissionControl contract | |
*/ |
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 requests | |
PEARL_PEV_CONTRACT_ADDRESS = 'TYCmYzi5c2X5FKhUBgD1FtgRCho8aiKd3j' | |
TAI_PEV_CONTRACT_ADDRESS = 'TNEgrJkG5S1t8p1xqFfqat3LsZaBbKJyVD' | |
SAN_PEV_CONTRACT_ADDRESS = 'TL5WhUrxfdi8G5WTuDDEB6Ai4GthiZ1jLK' | |
USDT_PEV_CONTRACT_ADDRESS = 'TSitoyPGTMb6pR3WrWM2jEtCis6b6QJcF1' | |
USDT_CONTRACT_ADDRESS = 'TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t' | |
PEV_CONTRACT_ADDRESS = 'TQQhxCErnhCQ4XG2fAqP2jG6ZwH5MBFv7X' | |
PEARL_CONTRACT_ADDRESS = 'TGbu32VEGpS4kDmjrmn5ZZJgUyHQiaweoq' |
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 requests | |
COLA_TRX_CONTRACT_ADDRESS = 'TKH4HPMPjxR2Q93XBVfQrpGiBpyjBwBG6P' | |
USDT_TRX_CONTRACT_ADDRESS = 'TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbLSE' | |
COLA_CONTRACT_ADDRESS = 'TSNWgunSeGUQqBKK4bM31iLw3bn9SBWWTG' | |
USDT_CONTRACT_ADDRESS = 'TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t' | |
def fetch_token_balances(token_addresses, pair_address): |
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 requests | |
PEV_CONTRACT_ADDRESS = 'TUJrRXdbkHbKEVT8sRs9xdfsaEWe1XHEMC' | |
PEARL_CONTRACT_ADDRESS = 'TJydMBnDJUYccpBPbLqn6oBxaiaCAhxcFd' | |
TAI_CONTRACT_ADDRESS = 'TSdDVvLdt3Vu9TqyEH5m273pJxbpJoqAwR' | |
SAN_CONTRACT_ADDRESS = 'TUU9vEMbEndY4VBm6C6T35EHByvkaMQypc' | |
TOKEN_SYMBOLS = ['USDT', 'PEARL', 'TAI', 'SAN'] | |
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
{"sig":"67c14a986845f909cc3d62f720522ec28599acb04019c1474e9041616568bc1245b6d8ee5ec2e197c7a902c9b774d83dc0f758307e4cc737c59e248e93bb85a21","msghash":"0348391951533f74f4bcd46cad09a5b30e91e241e6e40eb7a0930039df4a1af4"} |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import os | |
import shutil | |
from optparse import OptionParser | |
config_path = '/etc/switch-host/' | |
default_backup_file = 'default-hosts' |
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
var openApp = function() { | |
var a = xparamsString.sharefrom; | |
if (a) { | |
var b = "", | |
c = videoIdEn, | |
d = ""; | |
if ("pkios" == a || "pkandroid" == a) null != window.navigator.userAgent.match(/android/i) && (b = "paike://vid/" + c), null != window.navigator.userAgent.match(/iphone|ipad/i) && (b = "paike://type=vid&value=" + c), d = "banner=pk"; | |
if ("android" == a || "ipad" == a || "iphone" == a) { | |
var e = getCookie("__ysuid") || ""; | |
null != window.navigator.userAgent.match(/iphone/i) && (b = "youku://play?vid=" + c + "&source=mplaypage&cookieid=" + e); |
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 os | |
while True: | |
join_by = ' ' * 3 | |
content = raw_input('say something: ') | |
content_list = [content[i:i+3] for i in range(0, len(content), 3)] | |
output = join_by.join(content_list) | |
os.system("echo '%s' | pbcopy" % output) | |
print 'copied "%s" to clipboard, now you can paste!' % output |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
# This script helps removing Git branches. | |
# Run it from a git repo dir. It will open the Git branches list | |
# in your favorite editor. Delete some branches from the list. | |
# Save and close the file. The script applies the changes to the repo. | |
from subprocess import call, Popen, PIPE | |
from os import getenv |
NewerOlder