Note: You need to have to Heroku PGBackup addon first heroku addons:add pgbackups..
Creates the backup on heroku first:
heroku pgbackups:capture| /* add new tab called "mytab | |
| /*Original author is Ultimate Member*/ | |
| add_filter('um_account_page_default_tabs_hook', 'my_custom_tab_in_um', 100 ); | |
| function my_custom_tab_in_um( $tabs ) { | |
| $tabs[800]['mytab']['icon'] = 'um-faicon-pencil'; | |
| $tabs[800]['mytab']['title'] = 'My Custom Tab'; | |
| $tabs[800]['mytab']['custom'] = true; | |
| return $tabs; | |
| } |
| add_filter('um_admin_custom_search_filters','add_my_custom_search_fields', 10, 1); | |
| function add_my_custom_search_fields($fields) { | |
| $fields['field_meta_key'] = array('title' => 'Enter field title'); // replace 'field_meta_key' with your field meta key | |
| return $fields; | |
| } |
| ############################################################ | |
| ## Content of the Traders in Financial Futures (TFF) Report | |
| ## http://www.cftc.gov/ucm/groups/public/@commitmentsoftraders/documents/file/tfmexplanatorynotes.pdf | |
| ############################################################ | |
| # Dealer/Intermediary | |
| # These participants are what are typically described as the "sell side” of the market. Though they | |
| # may not predominately sell futures, they do design and sell various financial assets to clients. | |
| # They tend to have matched books or offset their risk across markets and clients. Futures | |
| # contracts are part of the pricing and balancing of risk associated with the products they sell and | |
| # their activities. These include large banks (U.S. and non-U.S.) and dealers in securities, swaps |
| from bs4 import BeautifulSoup | |
| import requests | |
| import datetime | |
| import logging | |
| import csv | |
| def setLogger(): | |
| logging.basicConfig(level=logging.INFO, | |
| format='%(asctime)s - %(levelname)s - %(message)s', | |
| filename='logs_file', |
symfony set dev to prod : http://symfony.com/doc/current/cookbook/deployment/tools.html#d-clear-your-symfony-cache symfony switch back to dev :
composer install --dev --optimize-autoloader
./app/console cache:clear
./app/console router:debug
| /** | |
| * return the angle between two points. | |
| * | |
| * @param {number} x1 x position of first point | |
| * @param {number} y1 y position of first point | |
| * @param {number} x2 x position of second point | |
| * @param {number} y2 y position of second point | |
| * @return {number} angle between two points (in radian) | |
| */ | |
| Math.getAngle = function( x1, y1, x2, y2 ) { |
| import time | |
| import pprint | |
| phrase = """ Britney Jean Spears (born December 2, 1981) is an American singer, dancer and actress. Born in | |
| McComb, Mississippi, and raised in Kentwood, Louisiana, she performed acting roles in stage | |
| productions and television shows as a child before signing with Jive Records in 1997. Spears's first | |
| and second studio albums, ...Baby One More Time (1999) and Oops!... I Did It Again (2000), became | |
| international successes, with the former becoming the best-selling album by a teenage solo | |
| artist.[1] Title tracks "...Baby One More Time" and "Oops!... I Did It Again" broke international | |
| sales records. In 2001, Spears released her self-titled third studio album, Britney, and played the |
| import math | |
| #import sys | |
| #import sunau | |
| #import array | |
| """ | |
| ecc=0.5 | |
| P=1 | |
| p=1 | |
| if len(sys.argv)>1: | |
| ecc=float(sys.argv[1]) |
| import matplotlib | |
| matplotlib.use('Agg') | |
| import matplotlib.pyplot as plt | |
| from cogs.utils.dataIO import dataIO | |
| from __main__ import send_cmd_help | |
| from discord.ext import commands | |
| import asyncio |