diff options
| author | Tang Chen <chen.tang@easystack.cn> | 2016-04-16 10:59:37 +0800 |
|---|---|---|
| committer | Tang Chen <chen.tang@easystack.cn> | 2016-04-18 10:31:01 +0800 |
| commit | 89445855acffc5ae4cf87dc501c09f3434d08bad (patch) | |
| tree | c55932e315ae6714775614fb3f9e4cdb2f726085 /openstackclient/network/v2/floating_ip.py | |
| parent | 8eade18624ad4a141424caa7e8cbb22294c2239f (diff) | |
| download | python-openstackclient-89445855acffc5ae4cf87dc501c09f3434d08bad.tar.gz | |
State i18() changes and help messages improved
Add _() to wrap help message in network commands.
And also some improvement for help message.
Change-Id: Ib3e498f5976ba98c44fd4eec2d1623263b3db53e
Partial-bug: 1570924
Diffstat (limited to 'openstackclient/network/v2/floating_ip.py')
| -rw-r--r-- | openstackclient/network/v2/floating_ip.py | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/openstackclient/network/v2/floating_ip.py b/openstackclient/network/v2/floating_ip.py index b21d6e96..21f86599 100644 --- a/openstackclient/network/v2/floating_ip.py +++ b/openstackclient/network/v2/floating_ip.py @@ -14,6 +14,7 @@ """IP Floating action implementations""" from openstackclient.common import utils +from openstackclient.i18n import _ from openstackclient.network import common @@ -63,7 +64,7 @@ class CreateFloatingIP(common.NetworkAndComputeShowOne): parser.add_argument( 'network', metavar='<network>', - help='Network to allocate floating IP from (name or ID)', + help=_("Network to allocate floating IP from (name or ID)") ) return parser @@ -71,26 +72,26 @@ class CreateFloatingIP(common.NetworkAndComputeShowOne): parser.add_argument( '--subnet', metavar='<subnet>', - help="Subnet on which you want to create the floating IP " - "(name or ID)" + help=_("Subnet on which you want to create the floating IP " + "(name or ID)") ) parser.add_argument( '--port', metavar='<port>', - help="Port to be associated with the floating IP " - "(name or ID)" + help=_("Port to be associated with the floating IP " + "(name or ID)") ) parser.add_argument( '--floating-ip-address', metavar='<floating-ip-address>', dest='floating_ip_address', - help="Floating IP address" + help=_("Floating IP address") ) parser.add_argument( '--fixed-ip-address', metavar='<fixed-ip-address>', dest='fixed_ip_address', - help="Fixed IP address mapped to the floating IP" + help=_("Fixed IP address mapped to the floating IP") ) return parser @@ -115,7 +116,7 @@ class DeleteFloatingIP(common.NetworkAndComputeCommand): parser.add_argument( 'floating_ip', metavar="<floating-ip>", - help=("Floating IP to delete (IP address or ID)") + help=_("Floating IP to delete (IP address or ID)") ) return parser @@ -189,7 +190,7 @@ class ShowFloatingIP(common.NetworkAndComputeShowOne): parser.add_argument( 'floating_ip', metavar="<floating-ip>", - help=("Floating IP to display (IP address or ID)") + help=_("Floating IP to display (IP address or ID)") ) return parser |
