Browse Source

added basic packaging structure

master
Holger Frey 6 years ago
parent
commit
fec34aabbf
  1. 14
      LICENSE
  2. 8
      MANIFEST.in
  3. 8
      Makefile
  4. 5
      README.md
  5. 2
      mtor/__init__.py
  6. 18
      mtor/cli.py
  7. 11
      requirements_dev.txt
  8. 19
      setup.cfg
  9. 63
      setup.py

14
LICENSE

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
/*
* ----------------------------------------------------------------------------
* "THE BEER-WARE LICENSE" (Revision 42):
* <frey@imtek.de> wrote this file. As long as you retain this notice you
* can do whatever you want with this stuff. If we meet some day, and you think
* this stuff is worth it, you can buy me a beer in return. Holger Frey
* ----------------------------------------------------------------------------
*/
The example content for the test cases involving database connections was
assembled from https://en.wikipedia.org/wiki/List_of_cheeses and other pages in
the domain of en.wikipedia.org. This content was provided by the Wikimedia
Foundation under the Creative Commons Attribution-ShareAlike License.

8
MANIFEST.in

@ -0,0 +1,8 @@ @@ -0,0 +1,8 @@
include LICENSE
include README.md
recursive-include tests *
recursive-exclude * __pycache__
recursive-exclude * *.py[co]
recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif

8
Makefile

@ -61,3 +61,11 @@ coverage: ## check code coverage with the default Python @@ -61,3 +61,11 @@ coverage: ## check code coverage with the default Python
coverage report -m
coverage html
$(BROWSER) htmlcov/index.html
dist: clean ## builds source and wheel package
python setup.py sdist
python setup.py bdist_wheel
ls -l dist
install: clean ## install the package to the active Python's site-packages
python setup.py install

5
README.md

@ -0,0 +1,5 @@ @@ -0,0 +1,5 @@
Mtor Image Analysis
===================
Image analysis for the mTor project

2
mtor/__init__.py

@ -11,6 +11,8 @@ from .workflows import ( @@ -11,6 +11,8 @@ from .workflows import (
warnings.filterwarnings("ignore")
__version__ = "0.1.0"
def run():
# pw = prescan_workflow("mtor-bilder", 50, 910, 300, 660)
pw = prescan_workflow("mtor-bilder", 50, 725 + 150, 300, 725)

18
mtor/cli.py

@ -0,0 +1,18 @@ @@ -0,0 +1,18 @@
# -*- coding: utf-8 -*-
"""Console script for mtor."""
import sys
import click
@click.command()
def main(args=None):
"""Console script for mtor."""
click.echo("Replace this message by putting your code into "
"mtor.cli.main")
click.echo("See click documentation at http://click.pocoo.org/")
return 0
if __name__ == "__main__":
sys.exit(main()) # pragma: no cover

11
requirements_dev.txt

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
pip==18.1
bumpversion==0.5.3
wheel==0.32.1
watchdog==0.9.0
flake8==3.5.0
tox==3.5.2
coverage==4.5.1
Sphinx==1.8.1
twine==1.12.1
black==18.9b0

19
setup.cfg

@ -0,0 +1,19 @@ @@ -0,0 +1,19 @@
[bumpversion]
current_version = 0.1.0
commit = True
tag = True
[bumpversion:file:setup.py]
search = version='{current_version}'
replace = version='{new_version}'
[bumpversion:file:mtor/__init__.py]
search = __version__ = '{current_version}'
replace = __version__ = '{new_version}'
[bdist_wheel]
universal = 1
[aliases]
# Define setup.py command aliases here

63
setup.py

@ -0,0 +1,63 @@ @@ -0,0 +1,63 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""The setup script."""
from setuptools import setup, find_packages
with open("README.md") as readme_file:
readme = readme_file.read()
with open("HISTORY.rst") as history_file:
history = history_file.read()
requirements = [
"Click>=6.0",
"pandas>=0.24",
"seaborn>=0.9",
"xlrd>=1.2",
"scikit-image>=0.15",
"scikit-learn>=0.20",
"peakutils>=1.3",
"tqdm>=4.31",
"openpyxl>=2.6",
"scipy>=1.2",
"xlwt>=1.3",
"xlsxwriter>=1.1",
"reportlab>=3.5",
]
setup_requirements = [ ]
test_requirements = [ ]
setup(
author="Holger Frey",
author_email="mail@holgerfrey.de",
classifiers=[
"Development Status :: 2 - Pre-Alpha",
"Intended Audience :: Developers",
"License :: Other",
"Natural Language :: English",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
],
description="Image analysis for the mTor project",
entry_points={
"console_scripts": [
"mtor=mtor.cli:main",
],
},
install_requires=requirements,
license="Beerware license",
long_description=readme,
include_package_data=True,
keywords="mtor",
name="mtor",
packages=find_packages(include=["mtor"]),
setup_requires=setup_requirements,
url="ttps://git.cpi.imtek.uni-freiburg.de/holgi/mtor",
version="0.1.0",
zip_safe=False,
)
Loading…
Cancel
Save