From f7c1e52dd1f3f90729f885811cea103e5a28a16a Mon Sep 17 00:00:00 2001 From: Adrien Ferrand Date: Sun, 20 Oct 2019 22:42:21 +0200 Subject: [PATCH] Change some variables names --- letsencrypt-auto-source/letsencrypt-auto | 26 +++++++++---------- .../letsencrypt-auto.template | 14 +++++----- .../bootstrappers/rpm_python3_legacy.sh | 2 +- 3 files changed, 21 insertions(+), 21 deletions(-) diff --git a/letsencrypt-auto-source/letsencrypt-auto b/letsencrypt-auto-source/letsencrypt-auto index b46592199..34d93789f 100755 --- a/letsencrypt-auto-source/letsencrypt-auto +++ b/letsencrypt-auto-source/letsencrypt-auto @@ -480,7 +480,7 @@ BootstrapRpmCommon() { BOOTSTRAP_RPM_PYTHON3_LEGACY_VERSION=1 # Checks if rh-python36 can be installed. -CheckPython36SclIsAvailable() { +Python36SclIsAvailable() { InitializeRPMCommonBase >/dev/null 2>&1; if "${TOOL}" list rh-python36 >/dev/null 2>&1; then @@ -827,10 +827,10 @@ elif [ -f /etc/redhat-release ]; then # Handle legacy RPM distributions if [ "$PYVER" -eq 26 ]; then - # Check if the automated rebootstrap can be achieved on this system. - if ! CheckPython36SclIsAvailable; then - INTERACTIVE_REBOOTSTRAP=1 - INTERACTIVE_REBOOTSTRAP_MESSAGE="Enable the SCL repository and try running Certbot again." + # Check if an automated bootstrap can be achieved on this system. + if ! Python36SclIsAvailable; then + INTERACTIVE_BOOTSTRAP=1 + INTERACTIVE_BOOTSTRAP_MESSAGE="Enable the SCL repository and try running Certbot again." fi Bootstrap() { @@ -1154,10 +1154,10 @@ if [ "$1" = "--le-auto-phase2" ]; then # If the selected Bootstrap function isn't a noop and it differs from the # previously used version if [ -n "$BOOTSTRAP_VERSION" -a "$BOOTSTRAP_VERSION" != "$PREV_BOOTSTRAP_VERSION" ]; then - # Check if we can rebootstrap without manual user intervention: this requires that + # Check if we can rebootstrap without manual user intervention: this require that # certbot-auto is in non-interactive mode AND selected bootstrap does not claim to # require a manual user intervention. - if [ "$NONINTERACTIVE" = 1 -a "$INTERACTIVE_REBOOTSTRAP" != 1 ]; then + if [ "$NONINTERACTIVE" = 1 -a "$INTERACTIVE_BOOTSTRAP" != 1 ]; then CAN_REBOOTSTRAP=1 fi # Check if rebootstrap can be done non-interactively and current shell is non-interactive @@ -1175,15 +1175,15 @@ if [ "$1" = "--le-auto-phase2" ]; then RerunWithArgs "$@" # Otherwise bootstrap needs to be done manually by the user. else - # If it is because bootstrapping is interactive, --non-interactive will be of no use. + # If it is because of the bootstrap, --non-interactive will be of no use. # Display the OS-specific interactive bootstrap message. - if [ "$INTERACTIVE_REBOOTSTRAP" = 1 ]; then - error "Skipping upgrade because new OS dependencies need to be installed." - error "This requires manual user intervention." - error "$INTERACTIVE_REBOOTSTRAP_MESSAGE" + if [ "$INTERACTIVE_BOOTSTRAP" = 1 ]; then + error "Skipping upgrade because new OS dependencies may need to be installed." + error "This requires a manual user intervention." + error "$INTERACTIVE_BOOTSTRAP_MESSAGE" error # If this is because of the environment (eg. non interactive shell without - # --non-interactive flag set, help the user in that direction. + # --non-interactive flag set), help the user in that direction. else error "Skipping upgrade because new OS dependencies may need to be installed." error diff --git a/letsencrypt-auto-source/letsencrypt-auto.template b/letsencrypt-auto-source/letsencrypt-auto.template index d29859753..e710f490a 100755 --- a/letsencrypt-auto-source/letsencrypt-auto.template +++ b/letsencrypt-auto-source/letsencrypt-auto.template @@ -356,9 +356,9 @@ elif [ -f /etc/redhat-release ]; then # Handle legacy RPM distributions if [ "$PYVER" -eq 26 ]; then # Check if an automated bootstrap can be achieved on this system. - if ! CheckPython36SclIsAvailable; then - INTERACTIVE_REBOOTSTRAP=1 - INTERACTIVE_REBOOTSTRAP_MESSAGE="Enable the SCL repository and try running Certbot again." + if ! Python36SclIsAvailable; then + INTERACTIVE_BOOTSTRAP=1 + INTERACTIVE_BOOTSTRAP_MESSAGE="Enable the SCL repository and try running Certbot again." fi Bootstrap() { @@ -577,7 +577,7 @@ if [ "$1" = "--le-auto-phase2" ]; then # Check if we can rebootstrap without manual user intervention: this require that # certbot-auto is in non-interactive mode AND selected bootstrap does not claim to # require a manual user intervention. - if [ "$NONINTERACTIVE" = 1 -a "$INTERACTIVE_REBOOTSTRAP" != 1 ]; then + if [ "$NONINTERACTIVE" = 1 -a "$INTERACTIVE_BOOTSTRAP" != 1 ]; then CAN_REBOOTSTRAP=1 fi # Check if rebootstrap can be done non-interactively and current shell is non-interactive @@ -597,10 +597,10 @@ if [ "$1" = "--le-auto-phase2" ]; then else # If it is because of the bootstrap, --non-interactive will be of no use. # Display the OS-specific interactive bootstrap message. - if [ "$INTERACTIVE_REBOOTSTRAP" = 1 ]; then - error "Skipping upgrade because new OS dependencies need to be installed." + if [ "$INTERACTIVE_BOOTSTRAP" = 1 ]; then + error "Skipping upgrade because new OS dependencies may need to be installed." error "This requires a manual user intervention." - error "$INTERACTIVE_REBOOTSTRAP_MESSAGE" + error "$INTERACTIVE_BOOTSTRAP_MESSAGE" error # If this is because of the environment (eg. non interactive shell without # --non-interactive flag set), help the user in that direction. diff --git a/letsencrypt-auto-source/pieces/bootstrappers/rpm_python3_legacy.sh b/letsencrypt-auto-source/pieces/bootstrappers/rpm_python3_legacy.sh index d0c1c6379..0935c1b94 100644 --- a/letsencrypt-auto-source/pieces/bootstrappers/rpm_python3_legacy.sh +++ b/letsencrypt-auto-source/pieces/bootstrappers/rpm_python3_legacy.sh @@ -3,7 +3,7 @@ BOOTSTRAP_RPM_PYTHON3_LEGACY_VERSION=1 # Checks if rh-python36 can be installed. -CheckPython36SclIsAvailable() { +Python36SclIsAvailable() { InitializeRPMCommonBase >/dev/null 2>&1; if "${TOOL}" list rh-python36 >/dev/null 2>&1; then