Skip to content

Commit

Permalink
added: setupfiles and destructured code
Browse files Browse the repository at this point in the history
  • Loading branch information
shahedex committed Dec 26, 2019
1 parent 5e2f725 commit acc880d
Show file tree
Hide file tree
Showing 12 changed files with 75 additions and 4 deletions.
19 changes: 19 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Copyright (c) 2018 The Python Packaging Authority

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@ Provides a python module to implement payment gateway in python based web apps.

## Projected use
```python
from sslcommerz_python import SSLCPayment
from sslcommerz_python.payment import SSLCSession
from decimal import Decimal

mypayment = SSLCPayment(sslc_is_sandbox=True, sslc_store_id='your_sslc_store_id', sslc_store_pass='your_sslc_store_passcode')
mypayment = SSLCSession(sslc_is_sandbox=True, sslc_store_id='your_sslc_store_id', sslc_store_pass='your_sslc_store_passcode')

mypayment.set_urls(success_url='example.com/success', fail_url='example.com/failed', cancel_url='example.com/cancel', ipn_url='example.com/payment_notification')

Expand Down
Empty file added __init__.py
Empty file.
Binary file removed __pycache__/_constants.cpython-37.pyc
Binary file not shown.
13 changes: 13 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
astroid==2.3.3
certifi==2019.11.28
chardet==3.0.4
idna==2.8
isort==4.3.21
lazy-object-proxy==1.4.3
mccabe==0.6.1
pylint==2.4.4
requests==2.22.0
six==1.13.0
typed-ast==1.4.0
urllib3==1.25.7
wrapt==1.11.2
38 changes: 38 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import setuptools

with open("README.md", "r") as fh:
long_description = fh.read()

requires = [
'astroid==2.3.3',
'certifi==2019.11.28',
'chardet==3.0.4',
'idna==2.8',
'isort==4.3.21',
'lazy-object-proxy==1.4.3',
'mccabe==0.6.1',
'requests==2.22.0',
'six==1.13.0',
'typed-ast==1.4.0',
'urllib3==1.25.7',
'wrapt==1.11.2'
]

setuptools.setup(
name="sslcommerz-python",
version="0.0.5",
author="Shahed Mehbub",
author_email="[email protected]",
description="Implements SSLCOMMERZ payment gateway in python based web apps.",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/shahedex/sslcommerz-payment-gateway-python",
packages=setuptools.find_packages(),
install_requires=requires,
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
],
python_requires='>=3.6',
)
Empty file added sslcommerz_python/__init__.py
Empty file.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File renamed without changes.
4 changes: 2 additions & 2 deletions sslcommerz_python.py → sslcommerz_python/payment.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
import requests
import json

import _constants as const
import sslcommerz_python._constants as const


class SSLCPayment:
class SSLCSession:
sslc_is_sandbox : bool
sslc_store_id : str
sslc_store_pass : str
Expand Down

0 comments on commit acc880d

Please sign in to comment.