From 6a7205210879082e7b4d6be3f4a342286777140b Mon Sep 17 00:00:00 2001 From: Vu Cong Tuan Date: Wed, 31 May 2017 11:16:17 +0700 Subject: [PATCH] Trivial fix typos Change-Id: Ib86aa9938fd852610ec0a6d8d868181f87bd2f24 --- diskimage_builder/block_device/level1/mbr.py | 4 ++-- diskimage_builder/block_device/plugin.py | 2 +- diskimage_builder/block_device/tests/test_config.py | 2 +- diskimage_builder/element_dependencies.py | 8 ++++---- .../dhcp-all-interfaces/install.d/50-dhcp-all-interfaces | 2 +- diskimage_builder/elements/dib-run-parts/README.rst | 4 ++-- .../elements/fedora-minimal/environment.d/11-yum-dnf.bash | 2 +- .../elements/fedora/environment.d/11-yum-dnf.bash | 2 +- diskimage_builder/elements/fedora/package-installs.yaml | 4 ++-- .../ironic-agent/environment.d/01-ironic-agent.sh | 2 +- diskimage_builder/elements/iso/cleanup.d/100-build-iso | 2 +- .../pip-and-virtualenv-source-install/04-install-pip | 2 +- diskimage_builder/elements/pkg-map/bin/pkg-map | 2 +- .../elements/source-repositories/package-installs.yaml | 2 +- 14 files changed, 20 insertions(+), 20 deletions(-) diff --git a/diskimage_builder/block_device/level1/mbr.py b/diskimage_builder/block_device/level1/mbr.py index 9137a171..8fab1e83 100644 --- a/diskimage_builder/block_device/level1/mbr.py +++ b/diskimage_builder/block_device/level1/mbr.py @@ -102,7 +102,7 @@ class MBR(object): ======== ============================================== Direct (native) writing of MBR, EBR (partition table) is - implemented - no other parititoning library or tools is used - + implemented - no other partitioning library or tools is used - to be sure to get the correct CHS and alignment for a wide range of host systems. """ @@ -240,7 +240,7 @@ class MBR(object): def write_partition_entry(self, bootflag, blockno, entry, ptype, lba_start, lba_length): - """Writes a parititon entry + """Writes a partition entry The entries are always the same and contain 16 bytes. The MBR and also the EBR use the same format. diff --git a/diskimage_builder/block_device/plugin.py b/diskimage_builder/block_device/plugin.py index 7a0ffa52..899a8f0c 100644 --- a/diskimage_builder/block_device/plugin.py +++ b/diskimage_builder/block_device/plugin.py @@ -32,7 +32,7 @@ class NodeBase(object): Every node has a unique string ``name``. This is its key in the graph and used for edge relationships. Implementations must - ensure they initalize it; e.g. + ensure they initialize it; e.g. .. code-block:: python diff --git a/diskimage_builder/block_device/tests/test_config.py b/diskimage_builder/block_device/tests/test_config.py index c2bd0ba9..564b3005 100644 --- a/diskimage_builder/block_device/tests/test_config.py +++ b/diskimage_builder/block_device/tests/test_config.py @@ -146,7 +146,7 @@ class TestCreateGraph(TestGraphGeneration): self.assertListEqual(call_order_list, call_order_names) - # Test multiple parition digraph generation + # Test multiple partition digraph generation def test_multiple_partitions_graph_generator(self): config = self.load_config_file('multiple_partitions_graph.yaml') diff --git a/diskimage_builder/element_dependencies.py b/diskimage_builder/element_dependencies.py index e90141f8..6ee85163 100644 --- a/diskimage_builder/element_dependencies.py +++ b/diskimage_builder/element_dependencies.py @@ -274,15 +274,15 @@ def expand_dependencies(user_elements, element_dirs): .. warning:: - DO NOT USE THIS FUNCTION. For compatability reasons, this + DO NOT USE THIS FUNCTION. For compatibility reasons, this function does not provide paths to the returned elements. This means the caller must process override rules if two elements with the same name appear in element_dirs :param user_elements: iterable enumerating the elements a user requested - :param elements_dir: The ELEMENTS_PATH to process + :param element_dirs: The ELEMENTS_PATH to process - :return: a set contatining user_elements and all dependent + :return: a set containing user_elements and all dependent elements including any transitive dependencies. """ logger.warning("expand_dependencies() deprecated, use get_elements") @@ -339,7 +339,7 @@ def main(): if args.env: _output_env_vars(elements) else: - # deprecated compatability output; doesn't include paths. + # deprecated compatibility output; doesn't include paths. print(' '.join([element.name for element in elements])) return 0 diff --git a/diskimage_builder/elements/dhcp-all-interfaces/install.d/50-dhcp-all-interfaces b/diskimage_builder/elements/dhcp-all-interfaces/install.d/50-dhcp-all-interfaces index fa7e2fd7..121f8d28 100755 --- a/diskimage_builder/elements/dhcp-all-interfaces/install.d/50-dhcp-all-interfaces +++ b/diskimage_builder/elements/dhcp-all-interfaces/install.d/50-dhcp-all-interfaces @@ -15,7 +15,7 @@ fi if [ "$DIB_INIT_SYSTEM" == "upstart" ]; then if [ -e "/etc/redhat-release" ] ; then - # the init system is upstart but networking is using sysv compatabiliy (i.e. Centos/RHEL 6) + # the init system is upstart but networking is using sysv compatibility (i.e. Centos/RHEL 6) install -D -g root -o root -m 0755 ${SCRIPTDIR}/dhcp-all-interfaces.init /etc/init.d/dhcp-all-interfaces chkconfig dhcp-all-interfaces on else diff --git a/diskimage_builder/elements/dib-run-parts/README.rst b/diskimage_builder/elements/dib-run-parts/README.rst index bf3852e6..f61962a0 100644 --- a/diskimage_builder/elements/dib-run-parts/README.rst +++ b/diskimage_builder/elements/dib-run-parts/README.rst @@ -4,7 +4,7 @@ dib-run-parts .. warning:: - This element is deprecated and is left only for compatability. + This element is deprecated and is left only for compatibility. Please read the notes. This element install the ``dib-utils`` package to provide @@ -17,6 +17,6 @@ stayed in the final image. The image build process now uses a private copy of ``dib-run-parts`` during the build, so this element has become deprecated. -For compatability this element simply installs the ``dib-utils`` +For compatibility this element simply installs the ``dib-utils`` package, which will provide ``dib-run-parts``. However, this is probably better expressed as a dependency in individual elements. diff --git a/diskimage_builder/elements/fedora-minimal/environment.d/11-yum-dnf.bash b/diskimage_builder/elements/fedora-minimal/environment.d/11-yum-dnf.bash index 568419d9..fdb91dec 100644 --- a/diskimage_builder/elements/fedora-minimal/environment.d/11-yum-dnf.bash +++ b/diskimage_builder/elements/fedora-minimal/environment.d/11-yum-dnf.bash @@ -1,5 +1,5 @@ # since f22, dnf is the yum replacement. Mostly it drops in -# unmodified, so while we transision KISS and use this to choose +# unmodified, so while we transition KISS and use this to choose if [ $DIB_RELEASE -ge 22 ]; then export YUM=dnf diff --git a/diskimage_builder/elements/fedora/environment.d/11-yum-dnf.bash b/diskimage_builder/elements/fedora/environment.d/11-yum-dnf.bash index 568419d9..fdb91dec 100644 --- a/diskimage_builder/elements/fedora/environment.d/11-yum-dnf.bash +++ b/diskimage_builder/elements/fedora/environment.d/11-yum-dnf.bash @@ -1,5 +1,5 @@ # since f22, dnf is the yum replacement. Mostly it drops in -# unmodified, so while we transision KISS and use this to choose +# unmodified, so while we transition KISS and use this to choose if [ $DIB_RELEASE -ge 22 ]; then export YUM=dnf diff --git a/diskimage_builder/elements/fedora/package-installs.yaml b/diskimage_builder/elements/fedora/package-installs.yaml index 1b298c89..7ca4e6d3 100644 --- a/diskimage_builder/elements/fedora/package-installs.yaml +++ b/diskimage_builder/elements/fedora/package-installs.yaml @@ -11,12 +11,12 @@ openssl: # FIXME: To avoid conflict between the pyOpenSSL installed via python-pip # and pyOpenSSL installed via yum, we are going to sort it out installing -# it earlier at the beginning of the image building process. Pyhton-pip +# it earlier at the beginning of the image building process. Python-pip # is installing pyOpenSSL as part of satisfying the requirements.txt # in python-glanceclient and afterwards yum tries to install it as a # dependency of the python-paste package needed for the heat element, # this seems to be conflicting and causing the image building process to -# fail. The problem is hapenning on a Fedora 18 system. +# fail. The problem is happening on a Fedora 18 system. pyOpenSSL: # Workaround for: diff --git a/diskimage_builder/elements/ironic-agent/environment.d/01-ironic-agent.sh b/diskimage_builder/elements/ironic-agent/environment.d/01-ironic-agent.sh index 4b759277..9e69ad08 100644 --- a/diskimage_builder/elements/ironic-agent/environment.d/01-ironic-agent.sh +++ b/diskimage_builder/elements/ironic-agent/environment.d/01-ironic-agent.sh @@ -1,4 +1,4 @@ -# backwards compatability with the previous environment +# backwards compatibility with the previous environment # variable for the ironic-agent source repository if [ -n "${DIB_REPOREF_agent:-}" ]; then echo "WARNING: DIB_REPOREF_agent is deprecated. Please update to use DIB_REPOREF_ironic_agent instead." diff --git a/diskimage_builder/elements/iso/cleanup.d/100-build-iso b/diskimage_builder/elements/iso/cleanup.d/100-build-iso index 4832c944..09622c15 100755 --- a/diskimage_builder/elements/iso/cleanup.d/100-build-iso +++ b/diskimage_builder/elements/iso/cleanup.d/100-build-iso @@ -75,7 +75,7 @@ function build_iso() { EXTRA_KERNEL_PARAMS="" fi - # Create a temporary build directory for holiding the contents of iso + # Create a temporary build directory for holding the contents of iso TMP_IMAGE_DIR="$TMP_BUILD_DIR/image" echo "Creating temporary directory $TMP_IMAGE_DIR" mkdir -p "$TMP_IMAGE_DIR" diff --git a/diskimage_builder/elements/pip-and-virtualenv/install.d/pip-and-virtualenv-source-install/04-install-pip b/diskimage_builder/elements/pip-and-virtualenv/install.d/pip-and-virtualenv-source-install/04-install-pip index 1f368b2d..705c3e1c 100755 --- a/diskimage_builder/elements/pip-and-virtualenv/install.d/pip-and-virtualenv-source-install/04-install-pip +++ b/diskimage_builder/elements/pip-and-virtualenv/install.d/pip-and-virtualenv-source-install/04-install-pip @@ -101,7 +101,7 @@ EOF echo "exclude=$packages" >> ${conf} fi else - # pre-install packages so depedencies are there. We will + # pre-install packages so dependencies are there. We will # overwrite with latest below. packages="python-pip python3-pip python-virtualenv" # unfortunately older ubuntu (trusty) doesn't have a diff --git a/diskimage_builder/elements/pkg-map/bin/pkg-map b/diskimage_builder/elements/pkg-map/bin/pkg-map index a15eb481..d33f52b1 100755 --- a/diskimage_builder/elements/pkg-map/bin/pkg-map +++ b/diskimage_builder/elements/pkg-map/bin/pkg-map @@ -69,7 +69,7 @@ def main(): args, extra = parser.parse_known_args() # Logs have traditionally gone to stderr with this tool. Maintain - # compatability + # compatibility level = logging.DEBUG if args.debug else logging.INFO logging.basicConfig(stream=sys.stderr, level=level) diff --git a/diskimage_builder/elements/source-repositories/package-installs.yaml b/diskimage_builder/elements/source-repositories/package-installs.yaml index 9598f0c5..0f115f0f 100644 --- a/diskimage_builder/elements/source-repositories/package-installs.yaml +++ b/diskimage_builder/elements/source-repositories/package-installs.yaml @@ -1,5 +1,5 @@ # Git isn't a dependency of this element, but is a dependency of pbr -# if you are doing pip install on a git cloned directoy, because this +# if you are doing pip install on a git cloned directory, because this # looks to be a fairly common pattern it makes sense to have git on the # target image git: