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
""" | |
This file is copied from https://github.com/dkensinger/python/blob/master/XIRR.py | |
which doesn't exist anymore! | |
""" | |
from datetime import date | |
def xirr(transactions): | |
""" | |
Calculates the Internal Rate of Return (IRR) for an irregular series of cash flows (XIRR) |
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
""" | |
Usage: | |
$ import mf | |
$ mf.get_price('INF200K01VK1') # pass ISIN of the mutual fund | |
> 1126.55 | |
""" | |
import os | |
import requests | |
import tempfile |
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
syntax on | |
" Sane defaults | |
set noerrorbells | |
set nowrap | |
set nu | |
set ignorecase | |
set smartcase | |
set incsearch | |
set tabstop=4 softtabstop=4 expandtab shiftwidth=4 smartindent |
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
stages: | |
- build | |
build: | |
image: electronuserland/builder:wine | |
stage: build | |
script: | |
- yarn | |
# Linux machine can be used to build only Windows and Linux binaries | |
- yarn dist -wl |
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 paypalrestsdk | |
from django.conf import settings | |
from django.http import JsonResponse | |
from django.utils.decorators import method_decorator | |
from django.views.decorators.csrf import csrf_exempt | |
from django.views.generic import View | |
paypalrestsdk.configure(dict( | |
mode=settings.PAYPAL_MODE, |