diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 0000000..1cf24c9 --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1,4 @@ +include README.md +include CHANGES.md +recursive-include yawlib/data *.json +recursive-include yawlib/glosswordnet/script *.sql diff --git a/README.md b/README.md index b62b2e6..f13a8f6 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,53 @@ WordNet glosstag : https://drive.google.com/open?id=0Bwko6IfQbRUJVUlkNEs # Installation -Extract the glosstag folder and sqlite-30.db to ~/wordnet. The directory should look like this: +Yawlib is available on PyPI +```bash +pip install yawlib +# or +python3 -m pip install yawlib + +# Download wordnet data and extract them to ~/wordnet + +# Show yawlib information +python3 -m yawlib info +``` + +Search synsets by the lemma `research`, use `python3 -m yawlib lemma research` + +``` +wn lemma research +Looking for synsets by term (Provided: research | pos = None) + +〔Synset〕00636921-n 〔Lemmas〕research 〔Keys〕research%1:04:00:: +------------------------------------------------------------ +(def) “systematic investigation to establish facts;” + + +〔Synset〕05797597-n 〔Lemmas〕inquiry; enquiry; research 〔Keys〕inquiry%1:09:01:: enquiry%1:09:00:: research%1:09:00:: +------------------------------------------------------------ +(def) “a search for knowledge;” +(ex) their pottery deserves more research than it has received; + + +〔Synset〕00648224-v 〔Lemmas〕research; search; explore 〔Keys〕research%2:31:00:: search%2:31:00:: explore%2:31:00:: +------------------------------------------------------------ +(def) “inquire into;” +(ex) the students had to research the history of the Second World War for their history project; +(ex) He searched for information on his relatives on the web; +(ex) Scientists are exploring the nature of consciousness; + + +〔Synset〕00877327-v 〔Lemmas〕research 〔Keys〕research%2:32:00:: +------------------------------------------------------------ +(def) “attempt to find out in a systematically and scientific manner;” +(ex) The student researched the history of that word; + +Found 4 synset(s) +``` + +Note: Extract the glosstag folder and sqlite-30.db to ~/wordnet. The directory should look like this: + ``` /home/user/wordnet ├── glosstag @@ -47,6 +93,9 @@ Extract the glosstag folder and sqlite-30.db to ~/wordnet. The directory should ├── sqlite-30.db ``` + +# Development + Go to yawlib folder, execute the config script and then run wntk.sh to generate the glosstab DB file. ``` cd ~/workspace diff --git a/release.sh b/release.sh new file mode 100755 index 0000000..f52303c --- /dev/null +++ b/release.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +pandoc --from=markdown --to=rst README.md -o README.rst +python3 setup.py sdist diff --git a/requirements-optional.txt b/requirements-optional.txt new file mode 100644 index 0000000..7e10602 --- /dev/null +++ b/requirements-optional.txt @@ -0,0 +1 @@ +flask diff --git a/requirements.txt b/requirements.txt index 7eed1eb..8c49faf 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,5 @@ -chirptext >= 0.1a5 +lxml fuzzywuzzy python-levenshtein -lxml -flask - +chirptext>=0.1a16 +puchikarui>=0.1a1 diff --git a/run b/run index cd310e8..8eb2630 100755 --- a/run +++ b/run @@ -1,4 +1,6 @@ #!/bin/bash -export FLASK_APP=yawol-flask.py -flask run +# export FLASK_APP=yawol-flask.py +# flask run +export FLASK_DEBUG=1 +python3 -m yawlib.yawol.app diff --git a/setup.py b/setup.py index 3a4f3f9..3a70b7e 100755 --- a/setup.py +++ b/setup.py @@ -3,19 +3,11 @@ ''' Setup script for YAWLib. -Latest version can be found at https://github.com/letuananh/yawlib - -Adapted from: https://github.com/letuananh/lelesk -References: - Python documentation: - https://docs.python.org/ - argparse module: - https://docs.python.org/3/howto/argparse.html - PEP 257 - Python Docstring Conventions: - https://www.python.org/dev/peps/pep-0257/ +Latest version can be found at https://github.com/letuananh/yawlib -@author: Le Tuan Anh +:copyright: (c) 2015 Le Tuan Anh +:license: MIT, see LICENSE for more details. ''' # Copyright (c) 2015, Le Tuan Anh @@ -38,33 +30,15 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -__author__ = "Le Tuan Anh " -__copyright__ = "Copyright 2015, yawlib" -__credits__ = [] -__license__ = "MIT" -__version__ = "0.1" -__maintainer__ = "Le Tuan Anh" -__email__ = "" -__status__ = "Prototype" - ######################################################################## -from setuptools import setup, find_packages -from setuptools.command.test import test as TestCommand import io -import codecs import os -import sys - -from uberapp import uberapp - -######################################################################## - - -here = os.path.abspath(os.path.dirname(__file__)) +from setuptools import setup def read(*filenames, **kwargs): + ''' Read contents of multiple files and join them together ''' encoding = kwargs.get('encoding', 'utf-8') sep = kwargs.get('sep', '\n') buf = [] @@ -74,35 +48,48 @@ def read(*filenames, **kwargs): return sep.join(buf) -long_description = read('README.md', 'CHANGES.md') +readme_file = 'README.rst' if os.path.isfile('README.rst') else 'README.md' +long_description = read(readme_file) +pkg_info = {} +exec(read('yawlib/__version__.py'), pkg_info) setup( - name='uberapp', - version=uberapp.__version__, - url='https://github.com/letuananh/pydemo', - license='MIT License', - author='Le Tuan Anh', - tests_require=[], - install_requires=[], - author_email='tuananh.ke@gmail.com', - description='An uber software which does not do anything useful', + name='yawlib', # package file name (-version.tar.gz) + version=pkg_info['__version__'], + url=pkg_info['__url__'], + project_urls={ + "Bug Tracker": "https://github.com/letuananh/yawlib/issues", + "Source Code": "https://github.com/letuananh/yawlib/" + }, + keywords="princeton wordnet glosstag omw", + license=pkg_info['__license__'], + author=pkg_info['__author__'], + tests_require=['lxml', 'fuzzywuzzy', 'python-levenshtein', 'chirptext>=0.1a16', 'puchikarui'], + install_requires=['lxml', 'fuzzywuzzy', 'python-levenshtein', 'chirptext>=0.1a16', 'puchikarui'], + author_email=pkg_info['__email__'], + description=pkg_info['__description__'], long_description=long_description, - packages=['uberapp'], + packages=['yawlib', + 'yawlib.glosswordnet', + 'yawlib.yawol', + 'yawlib.yawol.django', + 'yawlib.yawol.django.migrations'], + package_data={'yawlib': ['data/*.json', + 'glosswordnet/script/*.sql']}, include_package_data=True, platforms='any', test_suite='test', - classifiers = [ - 'Programming Language :: Python', - 'Development Status :: 0.1 - Alpha', - 'Natural Language :: English', - 'Environment :: Console Application', - 'Intended Audience :: Developers', - 'License :: OSI Approved :: MIT License', - 'Operating System :: OS Independent', - 'Topic :: Software Development :: Libraries :: Python Modules', - ]#, - #extras_require={ - # 'testing': ['pytest'], - #} + # Reference: https://pypi.python.org/pypi?%3Aaction=list_classifiers + classifiers=['Programming Language :: Python', + 'Development Status :: 2 - Pre-Alpha', + 'Natural Language :: English', + 'Environment :: Plugins', + 'Intended Audience :: Developers', + 'Intended Audience :: Science/Research', + 'License :: OSI Approved :: {}'.format(pkg_info['__license__']), + 'Operating System :: OS Independent', + 'Topic :: Text Processing', + 'Topic :: Text Processing :: Linguistic', + 'Topic :: Software Development :: Libraries :: Python Modules'] ) diff --git a/wntk b/wntk index 44ac9c6..9ff3b0d 100755 --- a/wntk +++ b/wntk @@ -5,4 +5,4 @@ if [ -z "$YAWLIB_HOME" ]; then fi cd ${YAWLIB_HOME} # setup alias -python3 -m yawlib.wntk "$@" +python3 -m yawlib "$@" diff --git a/yawlib-api.org b/yawlib-api.org index 2272598..84d7966 100644 --- a/yawlib-api.org +++ b/yawlib-api.org @@ -25,6 +25,28 @@ These functions should return a list of synset objects - hyponyms(synsetid, deep_select=True) - hypehypo(synsetid, deep_select=True) +* REST APIs +** Flask +To run Yawol Flask, use +```bash +# to debug, use +# export FLASK_DEBUG=1 +python3 -m yawlib.yawol.app +``` +*** Testing API +To ensure that Yawol is running, visit this URL: http://localhost:5000/yawol/version +(Change the port 5000 to your actual port) + +** Django +To run Yawol Django, use +```bash +python3 manage.py runserver +``` + +*** Testing API +To ensure that Yawol is running, visit this URL: http://localhost:8000/yawol/version +(Change the port 8000 to your actual port) + * Support datasets ** WordnetSQL ** GlossedWordnet diff --git a/yawlib/__init__.py b/yawlib/__init__.py index 3d5cd32..1e0e8e4 100644 --- a/yawlib/__init__.py +++ b/yawlib/__init__.py @@ -3,41 +3,16 @@ ''' YAWLib - Yet another WordNet library for Python -Latest version can be found at https://github.com/letuananh/yawlib -Adapted from: https://github.com/letuananh/lelesk +Latest version can be found at https://github.com/letuananh/yawlib -@author: Le Tuan Anh +:copyright: (c) 2012 Le Tuan Anh +:license: MIT, see LICENSE for more details. ''' -# Copyright (c) 2016, Le Tuan Anh -# -# 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. - -__author__ = "Le Tuan Anh " -__copyright__ = "Copyright 2014, yawlib" -__credits__ = [] -__license__ = "MIT" -__version__ = "0.1" -__maintainer__ = "Le Tuan Anh" -__email__ = "" -__status__ = "Prototype" +from .__version__ import __author__, __email__, __copyright__, __maintainer__ +from .__version__ import __credits__, __license__, __description__, __url__ +from .__version__ import __version_major__, __version_long__, __version__, __status__ from .config import YLConfig from .models import SynsetID, POS, Synset, SynsetCollection @@ -51,4 +26,5 @@ 'POS', 'SynsetID', 'Synset', 'SynsetCollection', 'get_synset_by_id', 'get_synset_by_sk', 'get_synsets_by_term', 'dump_synsets', 'dump_synset', - 'WordnetException', 'SynsetNotFoundException'] + 'WordnetException', 'SynsetNotFoundException', + "__version__", "__author__", "__description__", "__copyright__"] diff --git a/yawlib/__main__.py b/yawlib/__main__.py new file mode 100644 index 0000000..5ae6070 --- /dev/null +++ b/yawlib/__main__.py @@ -0,0 +1,2 @@ +from . import wntk +wntk.main() diff --git a/yawlib/__version__.py b/yawlib/__version__.py new file mode 100644 index 0000000..baa4ef3 --- /dev/null +++ b/yawlib/__version__.py @@ -0,0 +1,15 @@ +# -*- coding: utf-8 -*- + +# yawlib's package version information +__author__ = "Le Tuan Anh" +__email__ = "tuananh.ke@gmail.com" +__copyright__ = "Copyright (c) 2014, Le Tuan Anh" +__credits__ = [] +__license__ = "MIT License" +__description__ = "YAWLib - Yet another WordNet library for Python" +__url__ = "https://github.com/letuananh/yawlib" +__maintainer__ = "Le Tuan Anh" +__version_major__ = "0.1" +__version__ = "{}a1".format(__version_major__) +__version_long__ = "{} - Alpha".format(__version_major__) +__status__ = "Prototype" diff --git a/yawlib/config.py b/yawlib/config.py index b325b7f..6171971 100644 --- a/yawlib/config.py +++ b/yawlib/config.py @@ -40,41 +40,67 @@ __status__ = "Prototype" import os +import logging + +from chirptext import AppConfig +from chirptext.io import read_file, write_file + + +MY_DIR = os.path.dirname(__file__) +CONFIG_TEMPLATE = os.path.join(MY_DIR, 'data', 'config_template.json') +__yawlib_home = os.environ.get('YAWLIB_HOME', MY_DIR) +__app_config = AppConfig('yawlib', mode=AppConfig.JSON, working_dir=__yawlib_home) def full_path(a_path): return os.path.abspath(os.path.expanduser(a_path)) +def getLogger(): + return logging.getLogger(__name__) + + +def _get_config_manager(): + ''' Internal function for retrieving application config manager object + Don't use this directly, use read_config() method instead + ''' + return __app_config + + +def read_config(): + if not __app_config.config and not __app_config.locate_config(): + # need to create a config + config_dir = os.path.expanduser('~/.yawlib/') + if not os.path.exists(config_dir): + os.makedirs(config_dir) + cfg_loc = os.path.join(config_dir, 'config.json') + default_config = read_file(CONFIG_TEMPLATE) + getLogger().warning("Yawlib configuration file could not be found. A new configuration file will be generated at {}".format(cfg_loc)) + getLogger().debug("Default config: {}".format(default_config)) + write_file(cfg_loc, default_config) + # read config + config = __app_config.config + return config + + +def home_dir(): + _config = read_config() + yhome = _config.get('YAWLIB_HOME', '.') + return yhome if yhome else __yawlib_home + + +def get_file(file_key): + _config = read_config() + return _config.get(file_key).format(YAWLIB_HOME=home_dir()) + + class YLConfig: # WordNet SQLite can be downloaded from: # http://sourceforge.net/projects/wnsql/files/wnsql3/sqlite/3.0/ - WNSQL30_PATH = full_path('~/wordnet/sqlite-30.db') + WNSQL30_PATH = get_file('WNSQL30_PATH') # Gloss WordNet can be downloaded from: # http://wordnet.princeton.edu/glosstag.shtml - GWN30_PATH = full_path('~/wordnet/glosstag') - GWN30_DB = full_path('~/wordnet/glosstag.db') - OMW_DB = full_path('~/wordnet/wn-ntumc.db') - - NTUMC_PRONOUNS = ['77000100-n', '77000057-n', '77000054-a', '77000054-n', '77000026-n', '77000065-n' - , '77000025-n', '77000028-n', '77000004-n', '77010118-n', '77000104-n', '77000113-r', '77000003-n' - , '77000107-a', '77000098-n', '77000059-n', '77000059-a', '77000008-n', '77000107-n', '77000048-n' - , '01554230-n', '77010005-a', '77000088-r', '77000053-n', '77000113-a', '77000120-a', '77000123-n' - , '77000050-n', '77000050-a', '77000093-n', '77000114-r', '77000117-n', '77000040-n', '77000090-n' - , '77000114-a', '77000046-n', '01551633-n', '77000018-n', '77000009-n', '77000031-n', '77000032-n' - , '77000078-n', '77000092-n', '77000041-n', '77000043-a', '02267686-n', '77000039-a', '77000095-n' - , '77000081-n', '77000071-n', '02269039-n', '77000103-n', '77000072-n', '77000022-n', '77000108-n' - , '77000021-n', '77000035-n', '77010002-a', '77000076-n', '77000085-n', '77000013-n', '77010001-a' - , '77000074-n', '77000076-a', '02269286-n', '77000082-a', '77000017-n', '77010120-n', '77000082-n' - , '77000061-a', '77000110-n', '77010006-a', '77000061-n', '77000024-a', '77000011-n', '77000016-n' - , '77000024-n', '77000023-n', '77000052-n', '77000029-n', '77000064-n', '77000002-n', '77010119-n' - , '77010003-a', '77010008-n', '77000058-a', '77000056-n', '77000099-n', '77000106-n', '77000058-n' - , '77000006-n', '77000006-a', '77000139-n', '77000080-a', '02269635-n', '77000121-n', '77000091-a' - , '77000089-r', '77010000-a', '77000091-n', '77000116-n', '77010004-a', '77000044-n', '77000089-a' - , '77000122-n', '77000115-n', '77000019-n', '00524607-n', '77000033-n', '77000034-n', '77000045-n' - , '77000084-n', '02267308-n', '77000109-n', '77000075-a', '77000075-n', '77000097-n', '77000001-n' - , '77000073-n', '77000094-n', '77010122-n', '77000079-a', '77000111-n', '77000037-n', '77000012-n' - , '77000079-n', '77000020-n', '77000027-n', '77000070-n', '02070188-n', '77000038-n', '77010121-n' - , '77000015-n', '77000066-n', '77000137-n', '77000080-n', '77000060-n', '77010007-n', '77000060-a' - , '77000112-n' - ] + GWN30_PATH = get_file('GWN30_PATH') + GWN30_DB = get_file('GWN30_DB') + OMW_DB = get_file('OMW_DB') + NTUMC_PRONOUNS = read_config().get('NTUMC_PRONOUNS') diff --git a/yawlib/data/config_template.json b/yawlib/data/config_template.json new file mode 100644 index 0000000..63b70db --- /dev/null +++ b/yawlib/data/config_template.json @@ -0,0 +1,31 @@ +{ + "YAWLIB_HOME": "~/wordnet", + "WNSQL30_PATH": "{YAWLIB_HOME}/sqlite-30.db", + "GWN30_PATH": "{YAWLIB_HOME}/glosstag", + "GWN30_DB": "{YAWLIB_HOME}/glosstag.db", + "OMW_DB": "{YAWLIB_HOME}/wn-ntumc.db", + "NTUMC_PRONOUNS": ["77000100-n", "77000057-n", "77000054-a", "77000054-n", "77000026-n", "77000065-n", + "77000025-n", "77000028-n", "77000004-n", "77010118-n", "77000104-n", "77000113-r", + "77000003-n", "77000107-a", "77000098-n", "77000059-n", "77000059-a", "77000008-n", + "77000107-n", "77000048-n", "01554230-n", "77010005-a", "77000088-r", "77000053-n", + "77000113-a", "77000120-a", "77000123-n", "77000050-n", "77000050-a", "77000093-n", + "77000114-r", "77000117-n", "77000040-n", "77000090-n", "77000114-a", "77000046-n", + "01551633-n", "77000018-n", "77000009-n", "77000031-n", "77000032-n", "77000078-n", + "77000092-n", "77000041-n", "77000043-a", "02267686-n", "77000039-a", "77000095-n", + "77000081-n", "77000071-n", "02269039-n", "77000103-n", "77000072-n", "77000022-n", + "77000108-n", "77000021-n", "77000035-n", "77010002-a", "77000076-n", "77000085-n", + "77000013-n", "77010001-a", "77000074-n", "77000076-a", "02269286-n", "77000082-a", + "77000017-n", "77010120-n", "77000082-n", "77000061-a", "77000110-n", "77010006-a", + "77000061-n", "77000024-a", "77000011-n", "77000016-n", "77000024-n", "77000023-n", + "77000052-n", "77000029-n", "77000064-n", "77000002-n", "77010119-n", "77010003-a", + "77010008-n", "77000058-a", "77000056-n", "77000099-n", "77000106-n", "77000058-n", + "77000006-n", "77000006-a", "77000139-n", "77000080-a", "02269635-n", "77000121-n", + "77000091-a", "77000089-r", "77010000-a", "77000091-n", "77000116-n", "77010004-a", + "77000044-n", "77000089-a", "77000122-n", "77000115-n", "77000019-n", "00524607-n", + "77000033-n", "77000034-n", "77000045-n", "77000084-n", "02267308-n", "77000109-n", + "77000075-a", "77000075-n", "77000097-n", "77000001-n", "77000073-n", "77000094-n", + "77010122-n", "77000079-a", "77000111-n", "77000037-n", "77000012-n", "77000079-n", + "77000020-n", "77000027-n", "77000070-n", "02070188-n", "77000038-n", "77010121-n", + "77000015-n", "77000066-n", "77000137-n", "77000080-n", "77000060-n", "77010007-n", + "77000060-a", "77000112-n"] +} diff --git a/yawoldjango/__init__.py b/yawlib/yawol/__init__.py similarity index 100% rename from yawoldjango/__init__.py rename to yawlib/yawol/__init__.py diff --git a/yawol-flask.py b/yawlib/yawol/app.py similarity index 75% rename from yawol-flask.py rename to yawlib/yawol/app.py index 2634b2e..b4f9263 100755 --- a/yawol-flask.py +++ b/yawlib/yawol/app.py @@ -47,23 +47,38 @@ import json import logging + import flask from flask import Flask, Response, abort from functools import wraps from flask import request +from chirptext.cli import CLIApp, setup_logging + +from yawlib.config import read_config from yawlib import YLConfig from yawlib import SynsetID, SynsetCollection from yawlib import WordnetSQL as WSQL # --------------------------------------------------------------------- -# CONFIGURATION +# Configuration # --------------------------------------------------------------------- -logger = logging.getLogger(__name__) + +def getLogger(): + return logging.getLogger(__name__) + + +cfg = read_config() +logging_config_file = cfg.get('logging_config_file', 'logging.json') +log_dir = cfg.get('log_dir', 'logs') +setup_logging(logging_config_file, log_dir) app = Flask(__name__, static_url_path="") wsql = WSQL(YLConfig.WNSQL30_PATH) +# --------------------------------------------------------------------- +# Helper functions +# --------------------------------------------------------------------- # Adopted from: http://flask.pocoo.org/snippets/79/ def jsonp(func): """Wraps JSONified output for JSONP requests.""" @@ -79,6 +94,9 @@ def decorated_function(*args, **kwargs): return decorated_function +# --------------------------------------------------------------------- +# Views +# --------------------------------------------------------------------- @app.route('/yawol/synset/', methods=['GET']) @jsonp def get_synset(synsetid): @@ -100,7 +118,7 @@ def search(query): return SynsetCollection().add(ss).to_json_str() except Exception as e: # not synsetid - logger.exception(e, "Invalid synset ID") + getLogger().exception(e, "Invalid synset ID") pass # try search by lemma synsets = wsql.get_synsets_by_lemma(query) @@ -128,5 +146,19 @@ def version(): 'server': 'yawol-flask/Flask-{}'.format(flask.__version__)}) +# --------------------------------------------------------------------- +# Main +# --------------------------------------------------------------------- + +def run_app(cli, args): + print("Running Yawol-flask at http://{}:{} | DEBUG={}".format(args.host, args.port, args.debug)) + app.run(host=args.host, port=args.port, debug=args.debug) + + if __name__ == '__main__': - app.run(debug=True) + cli = CLIApp(desc='Yawol-Flask development server', logger=__name__) + cli.parser.add_argument('--port', default=5000, type=int) + cli.parser.add_argument('--host', default='0.0.0.0') + cli.parser.add_argument('--debug', default=False, action='store_true') + cli.parser.set_defaults(func=run_app) + cli.run() diff --git a/yawoldjango/migrations/__init__.py b/yawlib/yawol/django/__init__.py similarity index 100% rename from yawoldjango/migrations/__init__.py rename to yawlib/yawol/django/__init__.py diff --git a/yawoldjango/admin.py b/yawlib/yawol/django/admin.py similarity index 100% rename from yawoldjango/admin.py rename to yawlib/yawol/django/admin.py diff --git a/yawoldjango/apps.py b/yawlib/yawol/django/apps.py similarity index 100% rename from yawoldjango/apps.py rename to yawlib/yawol/django/apps.py diff --git a/yawlib/yawol/django/migrations/__init__.py b/yawlib/yawol/django/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/yawoldjango/models.py b/yawlib/yawol/django/models.py similarity index 100% rename from yawoldjango/models.py rename to yawlib/yawol/django/models.py diff --git a/yawoldjango/tests.py b/yawlib/yawol/django/tests.py similarity index 100% rename from yawoldjango/tests.py rename to yawlib/yawol/django/tests.py diff --git a/yawoldjango/urls.py b/yawlib/yawol/django/urls.py similarity index 100% rename from yawoldjango/urls.py rename to yawlib/yawol/django/urls.py diff --git a/yawoldjango/views.py b/yawlib/yawol/django/views.py similarity index 100% rename from yawoldjango/views.py rename to yawlib/yawol/django/views.py diff --git a/yawolsite/urls.py b/yawolsite/urls.py index 6cb0f9b..e632547 100644 --- a/yawolsite/urls.py +++ b/yawolsite/urls.py @@ -17,6 +17,6 @@ from django.contrib import admin urlpatterns = [ - url(r'^yawol/', include('yawoldjango.urls')), + url(r'^yawol/', include('yawlib.yawol.django.urls')), url(r'^admin/', admin.site.urls), ]