From 9ea442d486e73348ce0346e97374c633ac6e11b8 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Wed, 2 Nov 2011 11:54:37 +0100 Subject: [PATCH] use correct spelling --- kernel_build.py | 4 ++-- kernel_persistance.py => kernel_persistence.py | 16 ++++++++-------- 2 files changed, 10 insertions(+), 10 deletions(-) rename kernel_persistance.py => kernel_persistence.py (84%) diff --git a/kernel_build.py b/kernel_build.py index 7ae3903..b9b6eec 100644 --- a/kernel_build.py +++ b/kernel_build.py @@ -11,7 +11,7 @@ import logging import smtplib from glob import glob from logging import Formatter -import kernel_persistance +import kernel_persistence CWD = os.environ.get('WORKSPACE') BUILD_NUMBER = os.environ.get('BUILD_NUMBER') @@ -139,7 +139,7 @@ if __name__ == '__main__': atexit.register(remove_git_target_workspace) kernel_revision_obj = kernel_persistence.get_last_kernel_revision_obj() new_version = kernel_revision_obj.last_version + 1 - if not kernel_persistance.update_kernel_revision_obj(kernel_revision_obj, new_version): + if not kernel_persistence.update_kernel_revision_obj(kernel_revision_obj, new_version): logger.info( 'Could not update persistence version to %s for %s' %(new_version, GIT_BRANCH_NAME) diff --git a/kernel_persistance.py b/kernel_persistence.py similarity index 84% rename from kernel_persistance.py rename to kernel_persistence.py index e0d9c9a..b5542ae 100644 --- a/kernel_persistance.py +++ b/kernel_persistence.py @@ -39,27 +39,27 @@ def get_last_kernel_revision_obj(): session = Session() logger.debug('Getting kernel revision from persistence') if GIT_BRANCH_NAME == 'master' or GIT_BRANCH_NAME.startswith('hotfix'): - persistance_identifier = 'master' + persistence_identifier = 'master' elif GIT_BRANCH_NAME.startswith('release'): - persistance_identifier = 'release' + persistence_identifier = 'release' else: # FIXME: feature branch handling - persistance_identifier = 'develop' + persistence_identifier = 'develop' try: answ = session.query(KernelVersion).filter( - KernelVersion.identifier == persistance_identifier).one() + KernelVersion.identifier == persistence_identifier).one() except NoResultFound: - session.add(KernelVersion(persistance_identifier, 0)) + session.add(KernelVersion(persistence_identifier, 0)) session.commit() answ = session.query(KernelVersion).filter( - KernelVersion.identifier == persistance_identifier).one() + KernelVersion.identifier == persistence_identifier).one() finally: session.close() logger.info( - 'Got this Kernel revision for persistance_identifier %s: %s' - %(persistance_identifier, answ) + 'Got this Kernel revision for persistence_identifier %s: %s' + %(persistence_identifier, answ) ) return answ -- 2.39.5