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
function myFunction() { | |
var symbols = ['STRATBTC','OMGBTC','BTCUSDT']; | |
var something_else = 'hello world'; | |
var query_string = symbols.toString()+'&'+something_else; | |
var url = 'http://****public ip goes here****:5000/symbols/'+query_string; | |
var request = UrlFetchApp.fetch(url); | |
var data = JSON.parse(request.getContentText()); | |
Logger.log(data); | |
} |
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
[Unit] | |
Description=/etc/rc.local Compatibility | |
ConditionPathExists=/etc/rc.local | |
[Service] | |
Type=forking | |
ExecStart=/etc/rc.local start | |
TimeoutSec=0 | |
StandardOutput=tty | |
RemainAfterExit=yes |
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 | |
/usr/local/bin/forever start -s --minUptime 1000 --spinSleepTime 1000 -c python3 ~/appscript/app.py |
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 -e | |
# | |
# rc.local | |
# | |
# This script is executed at the end of each multiuser runlevel. | |
# Make sure that the script will "exit 0" on success or any other | |
# value on error. | |
# | |
# In order to enable or disable this script just change the execution | |
# bits. |
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 | |
symbols = ['ETHBTC','XRPBTC','BTCUSDT'] | |
something_else = 'hello world' | |
query_string = str(symbols)+'&'+something_else | |
url = f'http://127.0.0.1:5000/symbols/{query_string}' | |
r = requests.get(url) | |
data = r.json() | |
print(data) |
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
from flask import Flask | |
from flask_restful import Api,Resource | |
from binance.client import Client | |
app = Flask(__name__) | |
api = Api(app) | |
class Prices(Resource): | |
def get(self,symbols,something_else): | |
client = Client(None,None) |
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
from __future__ import print_function | |
import pickle | |
import os.path | |
from googleapiclient import errors | |
from googleapiclient.discovery import build | |
from google_auth_oauthlib.flow import InstalledAppFlow | |
from google.auth.transport.requests import Request | |
SCOPES = [''] | |
credentials_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
function update_time() { | |
var sheet = SpreadsheetApp.getActiveSpreadsheet(); | |
var ss = sheet.getSheetByName('Sheet1'); | |
var formattedDate = Utilities.formatDate(new Date(), "UTC", "MM-dd-yyyy HH:mm:ss"); | |
var merge_range = ss.getRange(3,3,3,3).merge().setHorizontalAlignment("center").setVerticalAlignment("center").setFontWeight("bold").setBorder(true,true,true,true,null,null,"black",SpreadsheetApp.BorderStyle.SOLID_MEDIUM).setFontSize(25); | |
var input_range = ss.getRange(3,3).setValue(formattedDate); | |
} |
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 | |
import sys | |
import shutil | |
import multiprocessing as mp | |
from itertools import repeat as re | |
import dateparser | |
import pytz | |
import json | |
import csv | |
import datetime |
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 time | |
import dateparser | |
import pytz | |
import json | |
import csv | |
import datetime | |
from dateutil.rrule import rrule, MONTHLY | |
from binance.client import Client | |
import os | |
import sys |