From f1e84e565fc534fd4795fadf6bafa0f30b0520ba Mon Sep 17 00:00:00 2001 From: merakor Date: Thu, 24 Dec 2020 15:04:54 +0000 Subject: Makefile: fix installing files other than cpt-* FossilOrigin-Name: 76e5ec56a8f045f2b4a31feb4cacfdf02cc6cd86cf7d7884ff48addc4862e5aa --- Makefile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 4e0880d..1f03f57 100644 --- a/Makefile +++ b/Makefile @@ -33,23 +33,23 @@ install-bin: ${BIN} install -Dm755 $${bin} ${DESTDIR}${BINDIR}/$${bin##*/}; done install-src: - for bin in src/*; do \ + for bin in src/cpt-*; do \ install -Dm755 $${bin} ${DESTDIR}${BINDIR}/$${bin##*/}; done install-contrib: - for bin in contrib/*; do \ + for bin in contrib/cpt-*; do \ install -Dm755 $${bin} ${DESTDIR}${BINDIR}/$${bin##*/}; done install-contrib-static: mkdir -p ${DESTDIR}${BINDIR} - for bin in contrib/*; do \ + for bin in contrib/cpt-*; do \ sed '/\. cpt-lib/r src/cpt-lib' $${bin} | \ sed '/\. cpt-lib/d' > ${DESTDIR}${BINDIR}/$${bin##*/}; \ chmod 755 ${DESTDIR}${BINDIR}/$${bin##*/}; done install-src-static: mkdir -p ${DESTDIR}${BINDIR} - for bin in src/*; do \ + for bin in src/cpt-*; do \ sed '/\. cpt-lib/r src/cpt-lib' $${bin} | \ sed '/\. cpt-lib/d' > ${DESTDIR}${BINDIR}/$${bin##*/}; \ chmod 755 ${DESTDIR}${BINDIR}/$${bin##*/}; done @@ -61,7 +61,7 @@ install: install-bin install-src install-contrib install-do install-static: install-bin install-src-static install-contrib-static install-doc uninstall: - for bin in ${BIN} src/* contrib/*; do \ + for bin in ${BIN} src/cpt-* contrib/cpt-*; do \ rm -f ${DESTDIR}${BINDIR}/$${bin##*/}; done for man in man/*; do rm -f ${DESTDIR}${MAN1}/$${man##*/}; done -- cgit v1.2.3 From bf988706fa4bdd863bdf1c6bf95e03bb68ab08c0 Mon Sep 17 00:00:00 2001 From: merakor Date: Mon, 4 Jan 2021 11:41:57 +0000 Subject: pkg_swap(): fix swap regular expression This bug caused swapping prefix files to malfunction on manifest files. Example: swapping redo caused redo-* files to be swapped on the manifest with the name 'redo' without actually moving the files to the alternatives directory either. FossilOrigin-Name: 5966d079397154246173b94f53de83212c20edeb53f75089092cec352e6316f4 --- src/cpt-lib | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cpt-lib b/src/cpt-lib index c75fbcf..6afd030 100644 --- a/src/cpt-lib +++ b/src/cpt-lib @@ -1281,7 +1281,7 @@ pkg_swap() { # its manifest file to reflect this. We then resort this file # so no issues arise when removing packages. cp -Pf "$CPT_ROOT/$2" "$pkg_owns>${alt#*>}" - sed "s#^$(regesc "$2")#${PWD#$CPT_ROOT}/$pkg_owns>${alt#*>}#" \ + sed "s#^$(regesc "$2")\$#${PWD#$CPT_ROOT}/$pkg_owns>${alt#*>}#" \ "../installed/$pkg_owns/manifest" | sort -r -o "../installed/$pkg_owns/manifest" fi @@ -1289,7 +1289,7 @@ pkg_swap() { # Convert the desired alternative to a real file and rewrite # the manifest file to reflect this. The reverse of above. mv -f "$alt" "$CPT_ROOT/$2" - sed "s#^${PWD#$CPT_ROOT}/$(regesc "$alt")#$2#" "../installed/$1/manifest" | + sed "s#^${PWD#$CPT_ROOT}/$(regesc "$alt")\$#$2#" "../installed/$1/manifest" | sort -r -o "../installed/$1/manifest" } -- cgit v1.2.3 From 6c4ca6e23d3ac6e511c6982e2557844b538a6a68 Mon Sep 17 00:00:00 2001 From: merakor Date: Mon, 4 Jan 2021 11:46:44 +0000 Subject: docs: update FossilOrigin-Name: ded347af5f33221e20649e7531847ab28a2a905c72b0c7a2f1bca9270cb20960 --- CHANGELOG.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4b2bf5f..6330006 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,15 @@ this project _somewhat_ adheres to [Semantic Versioning]. [Semantic Versioning]: https://semver.org/spec/v2.0.0.html +5.1.2 - 2020-12-24 +-------------------------------------------------------------------------------- + +### Fixed +- Fixed the `Makefile` installing files other than `cpt-*` files. +- Fixed `pkg_swap()` bug where swapping a prefix file would change the following + file locations on the manifest as well. + + 5.1.1 - 2020-12-20 -------------------------------------------------------------------------------- -- cgit v1.2.3