소스 검색

rename variable TRASHDIR to TEMPDIR

master
belliash 7 년 전
부모
커밋
3b1e85cbe4
3개의 변경된 파일20개의 추가작업 그리고 20개의 파일을 삭제
  1. 1
    1
      config/layout.conf
  2. 10
    10
      libraries/filesystem
  3. 9
    9
      modules/update-notification.ezmod

+ 1
- 1
config/layout.conf 파일 보기

@@ -23,7 +23,7 @@ PACKAGESDIR="${STOREDIR}/packages"
PORTAGESDIR="${STOREDIR}/portages"

# This specifies the directory where EzBuild will put its temporary files and caches.
TRASHDIR="${STOREDIR}/temp"
TEMPDIR="${STOREDIR}/temp"

# Directive sets the filename for logging of all information about the progress and of all
# executed commands output. This has to contain absolute path to the created file.

+ 10
- 10
libraries/filesystem 파일 보기

@@ -88,7 +88,7 @@ function generateDigests() {
#-------------------------------------------------------------------------------
function makeCoreDirectories() {
local DIRS="${BINDIR} ${BUILDDIR} ${LOGFILE%/*} ${OVERLAYSDIR} \
${PACKAGESDIR} ${PORTAGESDIR} ${STOREDIR} ${TRASHDIR}"
${PACKAGESDIR} ${PORTAGESDIR} ${STOREDIR} ${TEMPDIR}"
for DIR in ${DIRS}; do
makeDirectory ${DIR} || return 1
done
@@ -166,26 +166,26 @@ function mergeOverlay() {
local ORW="${5}"
local SRC="${1}"
local TOPDIR="$(pwd)"
makeCleanDirectory ${TRASHDIR}/ebuilds || return 1
makeCleanDirectory ${TEMPDIR}/ebuilds || return 1
cd ${SRC}
saveIFS ","
if [ "$(toUpper ${FTC})" == "ALL" ]; then
run "cp -apf *-* ${TRASHDIR}/ebuilds/"
run "cp -apf eclass ${TRASHDIR}/ebuilds/"
run "cp -apf licenses ${TRASHDIR}/ebuilds/"
run "cp -apf virtual ${TRASHDIR}/ebuilds/"
run "cp -apf *-* ${TEMPDIR}/ebuilds/"
run "cp -apf eclass ${TEMPDIR}/ebuilds/"
run "cp -apf licenses ${TEMPDIR}/ebuilds/"
run "cp -apf virtual ${TEMPDIR}/ebuilds/"
else
for ITEM in ${FTC}; do
run "cp -apf --parents ${ITEM} ${TRASHDIR}/ebuilds/" || return 1
run "cp -apf --parents ${ITEM} ${TEMPDIR}/ebuilds/" || return 1
done
fi
if [ "$(toUpper ${FTS})" != "NONE" ] && [ "$(toUpper ${FTS})" != "N/A" ]; then
for ITEM in ${FTS}; do
rm -rf ${TRASHDIR}/ebuilds/${ITEM}
rm -rf ${TEMPDIR}/ebuilds/${ITEM}
done
fi
restoreIFS
cd ${TRASHDIR}/ebuilds
cd ${TEMPDIR}/ebuilds
find -type d -name ".svn" -o -name "CVS" | xargs rm -rf {}
while read CAT; do
cd ${CAT}
@@ -205,7 +205,7 @@ function mergeOverlay() {
cd ..
done < <(find * -maxdepth 0 -type d)
cd ${TOPDIR}
rm -rf ${TRASHDIR}/ebuilds
rm -rf ${TEMPDIR}/ebuilds
return 0
}


+ 9
- 9
modules/update-notification.ezmod 파일 보기

@@ -10,15 +10,15 @@ ezsync_postcommit() {
local SENDMESG=0
if [ "${UPDATENOTIFY}" != "" ]; then
for PACKAGE in ${CHECKPACKAGES[*]}; do
makeCleanDirectory ${TRASHDIR}/ebuilds
makeDirectory ${TRASHDIR}/ebuilds/build
makeDirectory ${TRASHDIR}/ebuilds/mainline
run "cp -apf ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/${PACKAGE}/*.ebuild ${TRASHDIR}/ebuilds/build/" || return 1
run "cp -apf ${PORTAGESDIR}/${PORTAGE_MAINLINE[0]}/${PACKAGE}/*.ebuild ${TRASHDIR}/ebuilds/mainline/" || return 1
find ${TRASHDIR}/ebuilds -type f -name \*-9999\*.ebuild -exec rm -rf {} \;
BUILDVER=$(find ${TRASHDIR}/ebuilds/build -type f | sed -u -e "s/.ebuild//g" -e "s/-r/_z/g" -e "s/_p/_z/g" -e "s/_zre/_pre/" -e "s/$/_z0/" | sed "/^$/d" | sort -Vr | head -1)
makeCleanDirectory ${TEMPDIR}/ebuilds
makeDirectory ${TEMPDIR}/ebuilds/build
makeDirectory ${TEMPDIR}/ebuilds/mainline
run "cp -apf ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/${PACKAGE}/*.ebuild ${TEMPDIR}/ebuilds/build/" || return 1
run "cp -apf ${PORTAGESDIR}/${PORTAGE_MAINLINE[0]}/${PACKAGE}/*.ebuild ${TEMPDIR}/ebuilds/mainline/" || return 1
find ${TEMPDIR}/ebuilds -type f -name \*-9999\*.ebuild -exec rm -rf {} \;
BUILDVER=$(find ${TEMPDIR}/ebuilds/build -type f | sed -u -e "s/.ebuild//g" -e "s/-r/_z/g" -e "s/_p/_z/g" -e "s/_zre/_pre/" -e "s/$/_z0/" | sed "/^$/d" | sort -Vr | head -1)
BUILDVER=${BUILDVER##*/}
MAINLINEVER=$(find ${TRASHDIR}/ebuilds/mainline -type f | sed -u -e "s/.ebuild//g" -e "s/-r/_z/g" -e "s/_p/_z/g" -e "s/_zre/_pre/" -e "s/$/_z0/" | sed "/^$/d" | sort -Vr | head -1)
MAINLINEVER=$(find ${TEMPDIR}/ebuilds/mainline -type f | sed -u -e "s/.ebuild//g" -e "s/-r/_z/g" -e "s/_p/_z/g" -e "s/_zre/_pre/" -e "s/$/_z0/" | sed "/^$/d" | sort -Vr | head -1)
MAINLINEVER=${MAINLINEVER##*/}
NEWER=$(echo -e "${BUILDVER}\n${MAINLINEVER}" | sed "/^$/d" | sort -Vr | head -1)
if [[ "${NEWER}" != "${BUILDVER}" ]]; then
@@ -26,7 +26,7 @@ ezsync_postcommit() {
NEEDSUPDATE=${NEEDSUPDATE+"$NEEDSUPDATE, "}"${PACKAGE}"
fi
done
rm -rf ${TRASHDIR}/ebuilds
rm -rf ${TEMPDIR}/ebuilds
if isEnabled ${SENDMSG}; then
echo "The following packages needs your attention, because they probably has been updated in mainline Portage tree: ${NEEDSUPDATE}" | mailx -s "Packages need an update!" ${UPDATENOTIFY}
fi

Loading…
취소
저장