From 6c0a60888bba8086701ffe87d42ff69a5fd83bc4 Mon Sep 17 00:00:00 2001 From: davidovski Date: Sun, 15 May 2022 16:59:45 +0100 Subject: added add_from_main --- xi_profile.sh | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'xi_profile.sh') diff --git a/xi_profile.sh b/xi_profile.sh index 78bd6f4..5fb89a5 100644 --- a/xi_profile.sh +++ b/xi_profile.sh @@ -23,19 +23,35 @@ apply_patches () { done } +add_from_main () { + for pattern in $@; do + printf "moving $pattern..." + for file in $(find ./xipkg/ -path "./xipkg/*/$pattern" ); do + printf "$file " + filename=${file#./xipkg/$PKG_NAME} + mkdir -p $PKG_DEST/${pattern%/*} + mv $file $PKG_DEST/${filename} + done + printf "\n" + done +} + PKG_NAME=$1 cd $2 export BUILD_ROOT=$(realpath $2) +echo "Build file for $1, to build at root $2" + builds="$(ls *.xibuild | grep -v "$PKG_NAME.xibuild")" for xibuild in $PKG_NAME.xibuild $(ls *.xibuild | grep -v "$PKG_NAME.xibuild"); do + cd $2 SUBPKG_NAME=$(basename $xibuild .xibuild) mkdir -p ./xipkg/$SUBPKG_NAME export PKG_DEST=$(realpath ./xipkg/$SUBPKG_NAME) echo "to install to $PKG_DEST" - echo "============$PKG_NAME=============" + echo "============$SUBPKG_NAME=============" # read only the static variables fromt the primary . ./$PKG_NAME.xibuild -- cgit v1.2.1