diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 207aab9..3ee7594 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -5,8 +5,8 @@ Appendix C. Changelog :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. :License: BSD (see /LICENSE or :doc:`Appendix B `.) -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. index:: CHANGELOG @@ -19,6 +19,9 @@ More information can be found on GitHub in the `releases section Version History =============== +0.1.5 + * Warn if store is empty or does not exist (Issue #5) + 0.1.4 * Add j/k support for moving in the list (Issue #4) @@ -38,6 +41,9 @@ Version History 0.1.0 Initial release. +0.1.5 + * Warn if store is empty or does not exist (Issue #5) + 0.1.4 * Add j/k support for moving in the list (Issue #4) diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index c20fcaf..aad5510 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -5,8 +5,8 @@ Appendix A. Contribution rules :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. :License: BSD (see /LICENSE or :doc:`Appendix B `.) -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. index:: contributing diff --git a/PKGBUILD b/PKGBUILD index bafba39..880146e 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Chris Warrick pkgname=upass _pyname=upass -pkgver=0.1.4 +pkgver=0.1.5 pkgrel=1 pkgdesc='Console UI for pass' arch=('any') @@ -9,7 +9,7 @@ url='https://github.com/Kwpolska/upass' license=('BSD') options=(!emptydirs) source=("https://pypi.python.org/packages/source/${_pyname:0:1}/${_pyname}/${_pyname}-${pkgver}.tar.gz") -md5sums=('4bcb9683da51dc7dbf5bbd96c001fabc') +md5sums=('25932df5ae1a02401c06dcb6249889c7') depends=('pass' 'python' 'python-setuptools' 'python-urwid' 'python-pyperclip') prepare() { diff --git a/PKGBUILD-git b/PKGBUILD-git index 14b0e04..8b35d6e 100644 --- a/PKGBUILD-git +++ b/PKGBUILD-git @@ -2,7 +2,7 @@ pkgname=upass-git _pyname=upass _gitname=upass -pkgver=0.1.4 +pkgver=0.1.5 pkgrel=1 pkgdesc='Console UI for pass (git version)' arch=('any') diff --git a/README b/README index 94fb0b2..f11e021 100644 --- a/README +++ b/README @@ -4,8 +4,8 @@ upass. Console UI for pass. :Info: This is the README file for upass. :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. image:: https://chriswarrick.com/galleries/upass/directory-listing.png diff --git a/README.rst b/README.rst index 94fb0b2..f11e021 100644 --- a/README.rst +++ b/README.rst @@ -4,8 +4,8 @@ upass. Console UI for pass. :Info: This is the README file for upass. :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. image:: https://chriswarrick.com/galleries/upass/directory-listing.png diff --git a/docs/CHANGELOG.rst b/docs/CHANGELOG.rst index 207aab9..3ee7594 100644 --- a/docs/CHANGELOG.rst +++ b/docs/CHANGELOG.rst @@ -5,8 +5,8 @@ Appendix C. Changelog :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. :License: BSD (see /LICENSE or :doc:`Appendix B `.) -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. index:: CHANGELOG @@ -19,6 +19,9 @@ More information can be found on GitHub in the `releases section Version History =============== +0.1.5 + * Warn if store is empty or does not exist (Issue #5) + 0.1.4 * Add j/k support for moving in the list (Issue #4) @@ -38,6 +41,9 @@ Version History 0.1.0 Initial release. +0.1.5 + * Warn if store is empty or does not exist (Issue #5) + 0.1.4 * Add j/k support for moving in the list (Issue #4) diff --git a/docs/CONTRIBUTING.rst b/docs/CONTRIBUTING.rst index c20fcaf..aad5510 100644 --- a/docs/CONTRIBUTING.rst +++ b/docs/CONTRIBUTING.rst @@ -5,8 +5,8 @@ Appendix A. Contribution rules :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. :License: BSD (see /LICENSE or :doc:`Appendix B `.) -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. index:: contributing diff --git a/docs/LICENSE.rst b/docs/LICENSE.rst index 15a8759..f0c206e 100644 --- a/docs/LICENSE.rst +++ b/docs/LICENSE.rst @@ -5,8 +5,8 @@ Appendix B. License for upass :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. :License: BSD (see /LICENSE or :doc:`Appendix B `.) -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. index:: LICENSE diff --git a/docs/README.rst b/docs/README.rst index 94fb0b2..f11e021 100644 --- a/docs/README.rst +++ b/docs/README.rst @@ -4,8 +4,8 @@ upass. Console UI for pass. :Info: This is the README file for upass. :Author: Chris Warrick :Copyright: © 2015-2016, Chris Warrick. -:Date: 2016-01-01 -:Version: 0.1.4 +:Date: 2016-02-07 +:Version: 0.1.5 .. image:: https://chriswarrick.com/galleries/upass/directory-listing.png diff --git a/docs/conf.py b/docs/conf.py index f603fe4..6b48aa7 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -48,9 +48,9 @@ # built documents. # # The short X.Y version. -version = '0.1.4' +version = '0.1.5' # The full version, including alpha/beta/rc tags. -release = '0.1.4' +release = '0.1.5' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff --git a/setup.py b/setup.py index 922b7c1..4a4c829 100755 --- a/setup.py +++ b/setup.py @@ -21,7 +21,7 @@ def run_tests(self): sys.exit(errno) setup(name='upass', - version='0.1.4', + version='0.1.5', description='Console UI for pass.', keywords='upass', author='Chris Warrick', diff --git a/upass/__init__.py b/upass/__init__.py index 402872e..bbce8ca 100755 --- a/upass/__init__.py +++ b/upass/__init__.py @@ -1,5 +1,5 @@ # -*- encoding: utf-8 -*- -# upass v0.1.4 +# upass v0.1.5 # Console UI for pass. # Copyright © 2015-2016, Chris Warrick. # All rights reserved. @@ -40,7 +40,7 @@ """ __title__ = 'upass' -__version__ = '0.1.4' +__version__ = '0.1.5' __author__ = 'Chris Warrick' __license__ = '3-clause BSD' __docformat__ = 'restructuredtext en' diff --git a/upass/__main__.py b/upass/__main__.py index d44da7a..9b61987 100755 --- a/upass/__main__.py +++ b/upass/__main__.py @@ -1,5 +1,5 @@ # -*- encoding: utf-8 -*- -# upass v0.1.4 +# upass v0.1.5 # Console UI for pass. # Copyright © 2015-2016, Chris Warrick. # See /LICENSE for licensing information. @@ -156,9 +156,15 @@ def __init__(self): self.box = FancyListBox(urwid.SimpleFocusListWalker(listbox_content)) self.home = os.path.expanduser('~/.password-store') - self.refresh() - self.current = '.' - self.dir_load(None, self.current) + if os.path.exists(self.home) and os.listdir(self.home): + self.refresh() + self.current = '.' + self.dir_load(None, self.current) + else: + self._clear_box() + self.box.body.extend([urwid.Text(("error", 'Your Password Store is empty.')), + urwid.Text('Please use the `pass` command to create passwords. upass is a read-only browser.'), + urwid.Text('Press q to exit.')]) column_data = [ urwid.Button('DiSplay', self.display_selected), @@ -411,7 +417,7 @@ def run(self): def main(): """The main function of upass.""" - App().run() + return App().run() if __name__ == '__main__': try: