Skip to content

Commit

Permalink
Update mv.sh
Browse files Browse the repository at this point in the history
Make sure wax-leap-500x build files can be repackaged properly.
  • Loading branch information
xebb82 authored Dec 18, 2023
1 parent 3718557 commit 15ffd53
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions include/plugins/mv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,17 @@ comment "Remove conflicts field in control file"
sed -i "/^Conflicts:/d" ${CONTROL_FILE}

# new packages puts binaries directly in /usr/bin
if [ -d ${TMP_DIR}/usr/bin ] && [ -d ${TMP_DIR}/usr/share/licenses/${PACKAGE} ]; then
# 'wax-leap' packages has their license under 'leap' ADJUSTED_PACKAGE="${PACKAGE}"
if [[ "${ADJUSTED_PACKAGE}" == "wax-leap" ]]; then
ADJUSTED_PACKAGE="leap"
fi
if [ -d ${TMP_DIR}/usr/bin ] && [ -d ${TMP_DIR}/usr/share/licenses/${ADJUSTED_PACKAGE} ]; then

local NEW_PATH=usr/opt/${PACKAGE}/${MV_VERSION}

rename ${TMP_DIR} usr/bin ${NEW_PATH}/bin
rename ${TMP_DIR} usr/share/licenses/${PACKAGE} ${NEW_PATH}/licenses
rename ${TMP_DIR} usr/share/bash-completion ${NEW_PATH}/share/bash-completion
rename ${TMP_DIR} usr/share/licenses/${ADJUSTED_PACKAGE} ${NEW_PATH}/share/licenses

comment "Remove usr/share"
rm -rf ${TMP_DIR}/usr/share 2> /dev/null
Expand Down

0 comments on commit 15ffd53

Please sign in to comment.