diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index cba956b..e157142 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -14,4 +14,4 @@ Pull requests submitted through GitHub will be ignored. Bugs should be filed on Launchpad, not GitHub: - https://bugs.launchpad.net/python-almanachclient + https://bugs.launchpad.net/almanach diff --git a/almanachclient/shell.py b/almanachclient/shell.py index a289e48..09fd697 100644 --- a/almanachclient/shell.py +++ b/almanachclient/shell.py @@ -56,7 +56,7 @@ class AlmanachApp(app.App): help='Keystone V3 URL (Env: OS_AUTH_URL).') parser.add_argument('--os-region-name', - default=os.environ.get('OS_REGION_NAME'), + default=os.environ.get('`'), help='OpenStack region name (Env: OS_REGION_NAME).') parser.add_argument('--os-password', diff --git a/doc/source/conf.py b/doc/source/conf.py index a65c35b..358b107 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -22,8 +22,6 @@ sys.path.insert(0, os.path.abspath('../..')) # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. extensions = [ 'sphinx.ext.autodoc', - #'sphinx.ext.intersphinx', - 'oslosphinx' ] # autodoc generation is a bit aggressive and a nuisance when doing heavy @@ -38,7 +36,7 @@ master_doc = 'index' # General information about the project. project = u'python-almanachclient' -copyright = u'2016, OpenStack Foundation' +copyright = u'%d, OpenStack Foundation' # If true, '()' will be appended to :func: etc. cross-reference text. add_function_parentheses = True @@ -50,26 +48,7 @@ add_module_names = True # The name of the Pygments (syntax highlighting) style to use. pygments_style = 'sphinx' -# -- Options for HTML output -------------------------------------------------- - -# The theme to use for HTML and HTML Help pages. Major themes that come with -# Sphinx are currently 'default' and 'sphinxdoc'. -# html_theme_path = ["."] -# html_theme = '_theme' -# html_static_path = ['static'] - # Output file base name for HTML help builder. htmlhelp_basename = '%sdoc' % project -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto/manual]). -latex_documents = [ - ('index', - '%s.tex' % project, - u'%s Documentation' % project, - u'OpenStack Foundation', 'manual'), -] - -# Example configuration for intersphinx: refer to the Python standard library. -#intersphinx_mapping = {'http://docs.python.org/': None} +html_theme = 'default' diff --git a/doc/source/index.rst b/doc/source/index.rst index b43f25e..c223951 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,10 +1,5 @@ -.. python-almanachclient documentation master file, created by - sphinx-quickstart on Tue Jul 9 22:26:36 2013. - You can adapt this file completely to your liking, but it should at least - contain the root `toctree` directive. - -Welcome to python-almanachclient's documentation! -======================================================== +Almanach Client +=============== Contents: @@ -15,11 +10,3 @@ Contents: installation usage contributing - -Indices and tables -================== - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` - diff --git a/doc/source/installation.rst b/doc/source/installation.rst index 90e350c..9942594 100644 --- a/doc/source/installation.rst +++ b/doc/source/installation.rst @@ -6,7 +6,3 @@ At the command line:: $ pip install python-almanachclient -Or, if you have virtualenvwrapper installed:: - - $ mkvirtualenv python-almanachclient - $ pip install python-almanachclient diff --git a/doc/source/usage.rst b/doc/source/usage.rst index 7666d1d..eaa4162 100644 --- a/doc/source/usage.rst +++ b/doc/source/usage.rst @@ -1,7 +1,45 @@ -======== -Usage -======== +Command Line Usage +================== -To use python-almanachclient in a project:: +Environment variables +--------------------- - import almanachclient +* `OS_AUTH_URL`: Keystone URL (v3 endpoint) +* `OS_AUTH_URL`: OpenStack region name +* `OS_USERNAME`: OpenStack username +* `OS_PASSWORD`: OpenStack password +* `ALMANACH_SERVICE`: Almanach catalog service name +* `ALMANACH_TOKEN`: Almanach private key + +Get server version +------------------ + +.. code:: bash + + almanach-client version + + 4.0.9 + +Get Endpoint URL +---------------- + +.. code:: bash + + almanach-client endpoint + + http://almanach.example.org + +Get tenant entities +------------------- + +.. code:: bash + + almanach-client tenant entities bca89ae64dba46b8b74653d8d9ae8364 2016-01-01 2017-05-30 + + +--------------------------------------+----------+--------+---------------------------+------+---------------------------------------------------------------------------------------+ + | Entity ID | Type | Name | Start | End | Properties | + +--------------------------------------+----------+--------+---------------------------+------+---------------------------------------------------------------------------------------+ + | 8c3bc3aa-28d6-4863-b5ae-72e1b415f79d | instance | vm01 | 2017-05-09 14:19:14+00:00 | None | {'image': {'distro': 'centos', 'version': '7', 'os_type': 'linux'}, 'flavor': 'A1.1'} | + | f0690323-c394-4848-a272-964aad6431aa | instance | vm02 | 2017-05-15 18:31:42+00:00 | None | {'image': {'distro': 'centos', 'version': '7', 'os_type': 'linux'}, 'flavor': 'A1.1'} | + | 3e3b22e6-a10c-4c00-b8e5-05fcc8422b11 | volume | vol01 | 2017-05-15 19:11:14+00:00 | None | {'attached_to': [], 'volume_type': 'solidfire0'} | + +--------------------------------------+----------+--------+---------------------------+------+---------------------------------------------------------------------------------------+ diff --git a/setup.cfg b/setup.cfg index b50023a..c1b1fb4 100644 --- a/setup.cfg +++ b/setup.cfg @@ -33,20 +33,6 @@ all_files = 1 [upload_sphinx] upload-dir = doc/build/html -[compile_catalog] -directory = almanachclient/locale -domain = almanachclient - -[update_catalog] -domain = almanachclient -output_dir = almanachclient/locale -input_file = almanachclient/locale/almanachclient.pot - -[extract_messages] -keywords = _ gettext ngettext l_ lazy_gettext -mapping_file = babel.cfg -output_file = almanachclient/locale/almanachclient.pot - [build_releasenotes] all_files = 1 build-dir = releasenotes/build