Skip to content

Commit 4a5cf37

Browse files
author
Munis İsazadə
committed
Initial commit
1 parent a66bbf0 commit 4a5cf37

File tree

5 files changed

+190
-0
lines changed

5 files changed

+190
-0
lines changed

.gitignore

+110
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
9+
# Distribution / packaging
10+
.Python
11+
build/
12+
develop-eggs/
13+
dist/
14+
downloads/
15+
eggs/
16+
.eggs/
17+
lib/
18+
lib64/
19+
parts/
20+
sdist/
21+
var/
22+
wheels/
23+
*.egg-info/
24+
.installed.cfg
25+
*.egg
26+
MANIFEST
27+
28+
# PyInstaller
29+
# Usually these files are written by a python script from a template
30+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
31+
*.manifest
32+
*.spec
33+
34+
# Installer logs
35+
pip-log.txt
36+
pip-delete-this-directory.txt
37+
38+
# Unit test / coverage reports
39+
htmlcov/
40+
.tox/
41+
.coverage
42+
.coverage.*
43+
.cache
44+
nosetests.xml
45+
coverage.xml
46+
*.cover
47+
.hypothesis/
48+
.pytest_cache/
49+
50+
# Translations
51+
*.mo
52+
*.pot
53+
54+
# Django stuff:
55+
*.log
56+
local_settings.py
57+
db.sqlite3
58+
59+
# Flask stuff:
60+
instance/
61+
.webassets-cache
62+
63+
# Scrapy stuff:
64+
.scrapy
65+
66+
# Sphinx documentation
67+
docs/_build/
68+
69+
# PyBuilder
70+
target/
71+
72+
# Jupyter Notebook
73+
.ipynb_checkpoints
74+
75+
# pyenv
76+
.python-version
77+
78+
# celery beat schedule file
79+
celerybeat-schedule
80+
81+
# SageMath parsed files
82+
*.sage.py
83+
84+
# Environments
85+
.env
86+
!pydjango/conf/.env
87+
.venv
88+
env/
89+
venv/
90+
ENV/
91+
env.bak/
92+
venv.bak/
93+
94+
# Spyder project settings
95+
.spyderproject
96+
.spyproject
97+
98+
# Rope project settings
99+
.ropeproject
100+
101+
# mkdocs documentation
102+
/site
103+
104+
# mypy
105+
.mypy_cache/
106+
107+
# Editors
108+
.code/
109+
.idea/
110+
.vscode/

LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2019 Munis Isazade
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

MANIFEST.in

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include LICENSE

pubsub/__init__.py

Whitespace-only changes.

setup.py

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
import setuptools
2+
import sys
3+
import os
4+
import shutil
5+
import subprocess
6+
import platform
7+
8+
with open("README.md", "r") as fh:
9+
long_description = fh.read()
10+
#
11+
# config_files = []
12+
# for dirpath, subdirs, files in os.walk("pydjango/conf/"):
13+
# print(dirpath, subdirs, files)
14+
# for dir in subdirs:
15+
# config_files.append(os.path.join(dirpath, dir))
16+
# for file in files:
17+
# config_files.append(os.path.join(dirpath, file))
18+
19+
if "install" in sys.argv:
20+
if platform.system() == "Windows":
21+
pass
22+
else:
23+
proc = subprocess.Popen("echo ~",shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
24+
path = proc.stdout.read().decode("utf-8").replace("\n", "")
25+
config_name = "{}/.pydjango".format(path)
26+
if not os.path.isdir(config_name):
27+
os.makedirs(config_name)
28+
if os.path.isdir("{}/conf".format(config_name)):
29+
subprocess.call("rm -rf {}/conf".format(config_name),shell=True)
30+
shutil.copytree("pydjango/conf", "{}/conf".format(config_name))
31+
file = open("pydjango/config.py", "w")
32+
file.write("conf_path='{}/conf'\n".format(config_name))
33+
file.close()
34+
print("la"*50)
35+
# os.path.join(path)
36+
37+
setuptools.setup(
38+
name="pydjango",
39+
version=__import__("pydjango").VERSION,
40+
author="Munis Isazade",
41+
author_email="munisisazade@gmail.com",
42+
description="PyDjango, create django application with command line interface.",
43+
long_description=long_description,
44+
license='MIT',
45+
url="https://github.com/munisisazade/pydjango",
46+
scripts=['pydjango/script/create_django.py'],
47+
install_requires=["jinja2"],
48+
entry_points={'console_scripts': [
49+
'create_django = pydjango.core.management:execute_from_command_line',
50+
]},
51+
platforms=['any'],
52+
packages=setuptools.find_packages(),
53+
classifiers=[
54+
"Programming Language :: Python :: 3",
55+
"License :: OSI Approved :: MIT License",
56+
"Operating System :: OS Independent",
57+
],
58+
)

0 commit comments

Comments
 (0)