diff options
author | Juergen Bocklage-Ryannel <jbocklage-ryannel@luxoft.com> | 2017-07-13 13:53:10 +0200 |
---|---|---|
committer | Juergen Bocklage-Ryannel <jbocklage-ryannel@luxoft.com> | 2017-07-13 13:53:10 +0200 |
commit | cc6169ac2238cf32fe120790c9fb639bfa2d4c96 (patch) | |
tree | b7f8c9bfb1a0dd410c4a2120762212bcf9b3b080 /cli.py | |
parent | 62185cb8d52bba55a2e3eeb0da2a7597fffb0e1b (diff) | |
download | qtivi-qface-cc6169ac2238cf32fe120790c9fb639bfa2d4c96.tar.gz |
Fixed some smaller issues with named filters and how the
setup tools are working
Diffstat (limited to 'cli.py')
-rwxr-xr-x | cli.py | 19 |
1 files changed, 11 insertions, 8 deletions
@@ -14,13 +14,13 @@ import logging.config from livereload import Server, shell -here = os.path.dirname(__file__) +here = Path(__file__).abspath().dirname() -logging.config.dictConfig(yaml.load(open(os.path.join(here, 'log.yaml')))) +logging.config.dictConfig(yaml.load((here / 'log.yaml').open())) logger = logging.getLogger(__name__) -os.environ['PYTHONPATH'] = os.getcwd() +os.environ['PYTHONPATH'] = Path.getcwd() def sh(cmd, all=False, **kwargs): @@ -167,16 +167,19 @@ def uninstall(): @cli.command() def upload(): - Path('build').rmtree_p() - dist = Path('dist') - dist.rmtree_p() - dist.makedirs_p() - sh('python3 setup.py bdist_wheel') sh('twine upload dist/*') Path('build').rmtree_p() @cli.command() +def pack(): + Path('build').rmtree_p() + Path('dist').rmtree_p() + sh('python3 setup.py bdist_wheel') + sh('unzip -l dist/*.whl') + + +@cli.command() def docs_serve(): server = Server() server.watch('docs/*.rst', shell('make html', cwd='docs')) |