Skip to content

Commit 68fd69a

Browse files
committed
Use twine
1 parent 4f9c22f commit 68fd69a

File tree

6 files changed

+94
-73
lines changed

6 files changed

+94
-73
lines changed

.gitignore

Lines changed: 48 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
# Byte-compiled / optimized / DLL files
22
__pycache__/
33
*.py[cod]
4+
*$py.class
45

56
# C extensions
67
*.so
78

89
# Distribution / packaging
910
.Python
1011
env/
11-
bin/
1212
build/
1313
develop-eggs/
1414
dist/
15+
downloads/
1516
eggs/
17+
.eggs/
1618
lib/
1719
lib64/
1820
parts/
@@ -22,6 +24,12 @@ var/
2224
.installed.cfg
2325
*.egg
2426

27+
# PyInstaller
28+
# Usually these files are written by a python script from a template
29+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
30+
*.manifest
31+
*.spec
32+
2533
# Installer logs
2634
pip-log.txt
2735
pip-delete-this-directory.txt
@@ -30,25 +38,55 @@ pip-delete-this-directory.txt
3038
htmlcov/
3139
.tox/
3240
.coverage
41+
.coverage.*
3342
.cache
3443
nosetests.xml
3544
coverage.xml
45+
*,cover
46+
.hypothesis/
3647

3748
# Translations
3849
*.mo
39-
40-
# Mr Developer
41-
.mr.developer.cfg
42-
.project
43-
.pydevproject
44-
45-
# Rope
46-
.ropeproject
50+
*.pot
4751

4852
# Django stuff:
4953
*.log
50-
*.pot
54+
local_settings.py
55+
56+
# Flask stuff:
57+
instance/
58+
.webassets-cache
59+
60+
# Scrapy stuff:
61+
.scrapy
5162

5263
# Sphinx documentation
5364
docs/_build/
5465

66+
# PyBuilder
67+
target/
68+
69+
# IPython Notebook
70+
.ipynb_checkpoints
71+
72+
# pyenv
73+
.python-version
74+
75+
# celery beat schedule file
76+
celerybeat-schedule
77+
78+
# dotenv
79+
.env
80+
81+
# virtualenv
82+
venv/
83+
ENV/
84+
85+
# Spyder project settings
86+
.spyderproject
87+
88+
# Rope project settings
89+
.ropeproject
90+
91+
# PyCharm
92+
.idea/

MANIFEST.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
include tox.ini
1+
include LICENSE README.md tox.ini

Makefile

Lines changed: 41 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,59 @@
1-
.PHONY: clean-pyc clean-build docs clean build install install-all version
1+
.PHONY: clean build install version release dist
22

33
help:
44
@echo "clean-build - remove build artifacts"
5-
@echo "clean-pyc - remove Python file artifacts"
5+
@echo "clean-test - remove Python file artifacts"
6+
@echo "clean-eggs - remove cached eggs"
7+
@echo "build - build package"
8+
@echo "version - get version number"
9+
@echo "install - install packages"
10+
@echo "test - run tests quickly with the default Python"
11+
@echo "test-all - run tests on every Python version with tox"
612
@echo "release - package and upload a release"
713
@echo "dist - package"
814

9-
clean: clean-build clean-pyc
15+
clean: clean-build clean-test clean-eggs
16+
rm -rf htmlcov/
1017

1118
clean-build:
1219
rm -rf build/
1320
rm -rf dist/
1421
rm -rf *.egg-info
1522

16-
clean-pyc:
17-
find . -name '*.pyc' -exec rm -f {} +
18-
find . -name '*.pyo' -exec rm -f {} +
19-
find . -name '*~' -exec rm -f {} +
23+
.PHONY: clean-test
24+
clean-test:
25+
find . | grep -E "(__pycache__|\.pyc|\.pyo$$)" | xargs rm -rf
26+
rm -rf .pytest_cache/
27+
28+
.PHONY: clean-eggs
29+
clean-eggs:
30+
rm -rf .eggs/
31+
32+
.PHONY: build
33+
build: clean-build clean-eggs
34+
python3 setup.py build_ext --inplace
35+
36+
install: clean-build
37+
python3 setup.py install
2038

2139
version:
22-
python setup.py --version
40+
python3 setup.py --version
41+
42+
.PHONY: test
43+
test:
44+
python3 setup.py test
45+
46+
.PHONY: test-all
47+
test-all:
48+
tox
2349

50+
.PHONY: release
2451
release: clean build
25-
python setup.py sdist upload
26-
python setup.py bdist_wheel upload
52+
python3 setup.py sdist bdist_wheel
53+
twine check dist/*
54+
twine upload --verbose dist/*
2755

56+
.PHONY: dist
2857
dist: clean build
29-
python setup.py sdist
30-
python setup.py bdist_wheel
31-
ls -l dist
58+
python3 setup.py sdist bdist_wheel
59+
twine check dist/*

README.rst

Lines changed: 0 additions & 45 deletions
This file was deleted.

setup.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description-file = README.md
55
max-line-length = 120
66
exclude = .tox
77

8-
[pytest]
8+
[tool:pytest]
99
pep8maxlinelength = 120
1010
addopts = --tb=short
1111

setup.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ def run_tests(self):
2525
setup(
2626
name='flask-sqlacodegen',
2727
description='Automatic model code generator for SQLAlchemy with Flask support',
28-
long_description=open('README.rst').read(),
28+
long_description=open("README.md").read(),
29+
long_description_content_type="text/markdown",
2930
version=sqlacodegen.version,
3031
author='Kamil Sindi',
3132
classifiers=[
@@ -36,15 +37,14 @@ def run_tests(self):
3637
'Topic :: Database',
3738
'Topic :: Software Development :: Code Generators',
3839
'Programming Language :: Python',
39-
'Programming Language :: Python :: 2.6',
4040
'Programming Language :: Python :: 2.7',
4141
'Programming Language :: Python :: 3',
4242
'Programming Language :: Python :: 3.2',
4343
'Programming Language :: Python :: 3.3',
4444
'Programming Language :: Python :: 3.4',
4545
'Programming Language :: Python :: 3.5',
4646
'Programming Language :: Python :: 3.6',
47-
'Programming Language :: Python :: 3.7'
47+
'Programming Language :: Python :: 3.7',
4848
],
4949
keywords=['sqlalchemy', 'sqlacodegen', 'flask'],
5050
license='MIT',

0 commit comments

Comments
 (0)