incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhais...@apache.org
Subject git commit: cli: fix python sdist, add readline as installation requirement
Date Tue, 06 Nov 2012 11:37:33 GMT
Updated Branches:
  refs/heads/master b71386530 -> 77e957c91


cli: fix python sdist, add readline as installation requirement

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/77e957c9
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/77e957c9
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/77e957c9

Branch: refs/heads/master
Commit: 77e957c91b804856b66d31636a487af4a1e35f4b
Parents: b713865
Author: Rohit Yadav <bhaisaab@apache.org>
Authored: Tue Nov 6 17:06:11 2012 +0530
Committer: Rohit Yadav <bhaisaab@apache.org>
Committed: Tue Nov 6 17:06:11 2012 +0530

----------------------------------------------------------------------
 tools/cli/cloudmonkey/__init__.py    |    2 +-
 tools/cli/cloudmonkey/cloudmonkey.py |   11 ++++++++++-
 tools/cli/setup.py                   |   22 ++++++++++++----------
 3 files changed, 23 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/77e957c9/tools/cli/cloudmonkey/__init__.py
----------------------------------------------------------------------
diff --git a/tools/cli/cloudmonkey/__init__.py b/tools/cli/cloudmonkey/__init__.py
index 70e5d50..5f59cd0 100644
--- a/tools/cli/cloudmonkey/__init__.py
+++ b/tools/cli/cloudmonkey/__init__.py
@@ -16,6 +16,6 @@
 # under the License.
 
 try:
-    from cloudmonkey import *
+    from cloudmonkey import __version__
 except ImportError, e:
     print e

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/77e957c9/tools/cli/cloudmonkey/cloudmonkey.py
----------------------------------------------------------------------
diff --git a/tools/cli/cloudmonkey/cloudmonkey.py b/tools/cli/cloudmonkey/cloudmonkey.py
index 4d2cc6d..ea904b0 100644
--- a/tools/cli/cloudmonkey/cloudmonkey.py
+++ b/tools/cli/cloudmonkey/cloudmonkey.py
@@ -43,13 +43,19 @@ except ImportError, e:
     import sys
     sys.exit()
 
+# Use following rules for versioning:
+# <cli major version>.<cloudstack minor version>.<cloudstack major version>
+# Example: For CloudStack 4.1.x, CLI version should be 0.1.4
+__version__ = "0.0.4"
+
 log_fmt = '%(asctime)s - %(filename)s:%(lineno)s - [%(levelname)s] %(message)s'
 logger = logging.getLogger(__name__)
 completions = cloudstackAPI.__all__
 
 
 class CloudStackShell(cmd.Cmd):
-    intro = "☁ Apache CloudStack CLI. Type help or ? to list commands.\n"
+    intro = ("☁ Apache CloudStack cloudmonkey " + __version__ +
+             ". Type help or ? to list commands.\n")
     ruler = "-"
     config_file = os.path.expanduser('~/.cloudmonkey_config')
     grammar = []
@@ -386,6 +392,9 @@ class CloudStackShell(cmd.Cmd):
         return self.do_EOF(args)
 
     def do_EOF(self, args):
+        """
+        Quit on Ctrl+d or EOF
+        """
         return True
 
 

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/77e957c9/tools/cli/setup.py
----------------------------------------------------------------------
diff --git a/tools/cli/setup.py b/tools/cli/setup.py
index 9cf6b17..ebfb9d0 100644
--- a/tools/cli/setup.py
+++ b/tools/cli/setup.py
@@ -22,11 +22,10 @@ except ImportError:
     use_setuptools()
     from setuptools import setup, find_packages
 
-# Use following rules for versioning:
-# <cli major version>.<cloudstack minor version>.<cloudstack major version>
-# Example: For CloudStack 4.1.x, CLI version should be 0.1.4
-version = "0.0.4"
-name = "cloudmonkey"
+from cloudmonkey import __version__
+
+name = 'cloudmonkey'
+version = __version__
 
 setup(
     name = name,
@@ -37,12 +36,15 @@ setup(
     maintainer_email = "bhaisaab@apache.org",
     url = "http://incubator.apache.org/cloudstack",
     description = "Command Line Interface for Apache CloudStack",
-    long_description="cloudmonkey is a command line interface for Apache "
+    long_description = "cloudmonkey is a command line interface for Apache "
                      "CloudStack powered by CloudStack Marvin testclient",
-    platforms=("Any",),
+    platforms = ("Any",),
     license = 'ASL 2.0',
-    packages=find_packages(),
-    install_requires=['clint>=0.3.0'],
+    packages = find_packages(),
+    install_requires = [
+        'clint>=0.3.0',
+        'readline',
+    ],
     include_package_data = True,
     zip_safe = False,
     classifiers = [
@@ -58,6 +60,6 @@ setup(
     ],
     entry_points="""
     [console_scripts]
-    cloudmonkey = cloudmonkey:main
+    cloudmonkey = cloudmonkey.cloudmonkey:main
     """,
 )


Mime
View raw message