kiss: Add back KISS_DEBUG. Closes #109

This commit is contained in:
Dylan Araps 2020-02-08 10:55:58 +02:00
parent 89a927d3bb
commit cb7e57e8ed
No known key found for this signature in database
GPG Key ID: 46D62DD9F1DE636E
2 changed files with 8 additions and 1 deletions

3
kiss
View File

@ -616,7 +616,7 @@ pkg_build() {
# Delete the log file if the build succeeded to prevent
# the directory from filling very quickly with useless logs.
[ "$KISS_DEBUG" = 1 ] || rm -f "$log_dir/$pkg-$time-$pid"
[ "$KISS_KEEPLOG" = 1 ] || rm -f "$log_dir/$pkg-$time-$pid"
# Copy the repository files to the package directory.
# This acts as the database entry.
@ -1164,6 +1164,7 @@ pkg_updates() {
pkg_clean() {
# Clean up on exit or error. This removes everything related
# to the build.
[ "$KISS_DEBUG" != 1 ] || return
# Block 'Ctrl+C' while cache is being cleaned.
trap '' INT

6
kiss.1
View File

@ -103,6 +103,12 @@ export KISS_ROOT=/
# ones. Helpful when debugging.
#
# Set it to '1' to enable.
export KISS_KEEPLOG=0
# Keep build, package and extraction cache directories for debugging
# purposes.
#
# Set it to '1' to enable.
export KISS_DEBUG=0
# Force the usage of a different 'sudo' tool.