From 246eeaa2169dd7e0cf485b52a36f7ce64e72a80e Mon Sep 17 00:00:00 2001 From: merakor Date: Sun, 20 Dec 2020 09:00:28 +0000 Subject: cpt-lib: fix a bug in pkg_clean when CPT_DEBUG was set Because of the CPT_DEBUG check returning 1, it would skip the termination, meaning that even the package has failed, it will create the tarball and exit with success. FossilOrigin-Name: ce2337ddaa89f4a9928018ad325e6c7eac71ffb639ad55ad8e8bc97547f9a59b --- CHANGELOG.md | 9 +++++++++ config.mk | 2 +- src/cpt-lib | 4 ++-- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f714c1a..4b2bf5f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,14 @@ this project _somewhat_ adheres to [Semantic Versioning]. [Semantic Versioning]: https://semver.org/spec/v2.0.0.html +5.1.1 - 2020-12-20 +-------------------------------------------------------------------------------- + +### Fixed +- Fixed an issue where the package build is continued even when it failed when + `$CPT_DEBUG` was set + + 5.1.0 - 2020-11-25 -------------------------------------------------------------------------------- @@ -29,6 +37,7 @@ this project _somewhat_ adheres to [Semantic Versioning]. - Moved option parsing to cpt-lib if `parser_definition` exists. This shouldn't affect existing scripts where `cpt-lib` is called before the `p + 5.0.0 - 2020-10-06 -------------------------------------------------------------------------------- diff --git a/config.mk b/config.mk index 7001625..ba76118 100644 --- a/config.mk +++ b/config.mk @@ -1,5 +1,5 @@ # See LICENSE for copyright information -VERSION = 5.1.0 +VERSION = 5.1.1 # Paths PREFIX = /usr/local diff --git a/src/cpt-lib b/src/cpt-lib index e071206..c75fbcf 100644 --- a/src/cpt-lib +++ b/src/cpt-lib @@ -8,7 +8,7 @@ # Currently maintained by Cem Keylan. version() { - log "Carbs Packaging Tools" 5.1.0 + log "Carbs Packaging Tools" 5.1.1 exit 0 } @@ -1746,7 +1746,7 @@ pkg_updates(){ pkg_clean() { # Clean up on exit or error. This removes everything related # to the build. - [ "$CPT_DEBUG" != 1 ] || return + [ "$CPT_DEBUG" != 1 ] || return 0 # Block 'Ctrl+C' while cache is being cleaned. trap_set block -- cgit v1.2.3