aboutsummaryrefslogtreecommitdiff
path: root/kiss
diff options
context:
space:
mode:
authormerakor <cem@ckyln.com>2020-04-22 21:06:54 +0000
committermerakor <cem@ckyln.com>2020-04-22 21:06:54 +0000
commitbe41b711489f4bec70834478237ea73656634f9b (patch)
treeb02656972b8d7c8d572435d0359ef724e605ab9d /kiss
parentef39477c9ef4ef365d7f38e8bc261c7b9efb028e (diff)
downloadcpt-be41b711489f4bec70834478237ea73656634f9b.tar.gz
kiss: pull some upstream changes
FossilOrigin-Name: 613a576e33c286d8edbb9dc0b40c76a6eb31e6165000e57997b051b3999334c2
Diffstat (limited to 'kiss')
-rwxr-xr-xkiss18
1 files changed, 9 insertions, 9 deletions
diff --git a/kiss b/kiss
index ed631ab..2a6bf2f 100755
--- a/kiss
+++ b/kiss
@@ -479,7 +479,7 @@ pkg_manifest() (
# This function runs as a sub-shell to avoid having to 'cd' back to the
# prior directory before being able to continue.
- cd "$pkg_dir/$1"
+ cd "${2:-$pkg_dir}/$1"
# find: Print all files and directories and append '/' to directories.
# sort: Sort the output in *reverse*. Directories appear *after* their
@@ -487,7 +487,7 @@ pkg_manifest() (
# sed: Remove the first character in each line (./dir -> /dir) and
# remove all lines which only contain '.'.
find . -type d -exec printf '%s/\n' {} + -o -print |
- sort -r | sed '/^\.\/$/d;ss.ss' > "$pkg_dir/$1/$pkg_db/$1/manifest"
+ sort -r | sed '/^\.\/$/d;ss.ss' > "${2:-$pkg_dir}/$1/$pkg_db/$1/manifest"
)
pkg_etcsums() (
@@ -778,7 +778,7 @@ pkg_conflicts() {
#
# Pretty nifty huh?
while IFS=: read -r _ con; do
- log "$p_name" "Found conflict ($con), adding choice"
+ printf '%s\n' "Found conflict $con"
# Create the "choices" directory inside of the tarball.
# This directory will store the conflicting file.
@@ -799,13 +799,12 @@ pkg_conflicts() {
log "this must be fixed in $p_name. Contact the maintainer"
die "by checking 'git log' or by running 'kiss-maintainer'"
}
-
- # Rewrite the package's manifest to update its location
- # to its new spot (and name) in the choices directory.
- sed -i "$(esc "$con" "/$cho_dir/$p_name$con_name")" \
- "$tar_dir/$p_name/$pkg_db/$p_name/manifest"
done
+ # Rewrite the package's manifest to update its location
+ # to its new spot (and name) in the choices directory.
+ pkg_manifest "$p_name" "$tar_dir" 2>/dev/null
+
elif "$grep" -Fxf "$cac_dir/$pid-m" -- "$@"; then
log "Package '$p_name' conflicts with another package" "" "!>"
log "Run 'KISS_CHOICE=1 kiss i $p_name' to add conflicts" "" "!>"
@@ -934,7 +933,7 @@ pkg_etc() {
;;
esac
- cp -af "$file" "$KISS_ROOT/${file}${new}"
+ cp -fPp "$file" "$KISS_ROOT/${file}${new}"
chown root:root "$KISS_ROOT/${file}${new}" 2>/dev/null
done) ||:
}
@@ -1092,6 +1091,7 @@ pkg_install() {
fi
done ||:
+ log "$pkg_name" "Verifying installation"
pkg_install_files -e "$tar_dir/$pkg_name" "Checking file"
# Reset 'trap' to its original value. Installation is done so