Rename capabilities to traits

This commit is contained in:
Jay Pipes 2016-09-19 11:00:02 -04:00
parent 7d2a583f32
commit d5ab376e0a
7 changed files with 29 additions and 29 deletions

View File

@ -1,39 +1,39 @@
===============
os-capabilities
os-traits
===============
A library containing standardized capability strings.
A library containing standardized trait strings.
Capabilities are strings that represent a feature of some resource provider.
This library contains the catalog of constants that have been standardized in
the OpenStack community to refer to a particular hardware, virtualization,
storage, network, or device capability.
Traits are strings that represent a feature of some resource provider. This
library contains the catalog of constants that have been standardized in the
OpenStack community to refer to a particular hardware, virtualization, storage,
network, or device trait.
* Free software: Apache license
* Documentation: http://docs.openstack.org/developer/os-capabilities
* Source: http://git.openstack.org/cgit/openstack/os-capabilities
* Bugs: http://bugs.launchpad.net/os-capabilities
* Documentation: http://docs.openstack.org/developer/os-traits
* Source: http://git.openstack.org/cgit/openstack/os-traits
* Bugs: http://bugs.launchpad.net/os-traits
Usage
------
`os-capabilities` is primarily composed of a set of constants that may be
referenced by simply importing the os_capabilities module and referencing one
of the module's capabilities constants::
`os-traits` is primarily composed of a set of constants that may be referenced
by simply importing the os_traits module and referencing one of the module's
traits constants::
$ python
Python 2.7.11+ (default, Apr 17 2016, 14:00:29)
[GCC 5.3.1 20160413] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import os_capabilities as os_caps
>>> print os_caps.HW_CPU_X86_SSE42
>>> import os_traits as ot
>>> print ot.HW_CPU_X86_SSE42
hw:cpu:x86:sse42
Don't know what the symbol names are for the `os_capabilities` module? There's
a helper method for that::
Don't know what the symbol names are for the `os_traits` module? There's a
helper method for that::
>>> import pprint
>>> pprint.pprint(os_caps.get_symbol_names())
>>> pprint.pprint(ot.get_symbol_names())
[...
<snip>
'HW_CPU_X86_AVX2',
@ -58,9 +58,9 @@ a helper method for that::
'HW_CPU_X86_ABM',
'HW_CPU_X86_3DNOW']
Want to see the capability strings for a subset of capabilities? There's a method for that too::
Want to see the trait strings for a subset of traits? There's a method for that too::
>>> pprint.pprint(os_caps.get_capabilities(os_caps.NAMESPACES['x86']))
>>> pprint.pprint(ot.get_traits(ot.NAMESPACES['x86']))
['hw:cpu:x86:aes-ni',
'hw:cpu:x86:avx512er',
'hw:cpu:x86:avx512cd',

View File

@ -1,6 +1,6 @@
[metadata]
name = os-capabilities
summary = A library containing standardized capability strings
name = os-traits
summary = A library containing standardized trait strings
description-file =
README.rst
author = OpenStack
@ -21,7 +21,7 @@ classifier =
[files]
packages =
os_capabilities
os_traits
[build_sphinx]
source-dir = doc/source
@ -32,20 +32,20 @@ all_files = 1
upload-dir = doc/build/html
[compile_catalog]
directory = os_capabilities/locale
domain = os_capabilities
directory = os_traits/locale
domain = os_traits
[update_catalog]
domain = os_capabilities
output_dir = os_capabilities/locale
input_file = os_capabilities/locale/os_capabilities.pot
domain = os_traits
output_dir = os_traits/locale
input_file = os_traits/locale/os_traits.pot
[extract_messages]
keywords = _ gettext ngettext l_ lazy_gettext
mapping_file = babel.cfg
output_file = os_capabilities/locale/os_capabilities.pot
output_file = os_traits/locale/os_traits.pot
[build_releasenotes]
all_files = 1
build-dir = releasenotes/build
source-dir = releasenotes/source
source-dir = releasenotes/source