summaryrefslogtreecommitdiffstats
path: root/postsync.d/50-eix-update
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2008-12-18 15:22:05 +0100
committerAlexander Sulfrian <alexander@sulfrian.net>2008-12-18 15:22:05 +0100
commit410ee70f54f462f72ac4993c608b34cd9fac1bd6 (patch)
tree45a621acd2eeac74bf27d337e64513f6b403aefb /postsync.d/50-eix-update
downloadportage-ext-410ee70f54f462f72ac4993c608b34cd9fac1bd6.tar.gz
portage-ext-410ee70f54f462f72ac4993c608b34cd9fac1bd6.tar.xz
portage-ext-410ee70f54f462f72ac4993c608b34cd9fac1bd6.zip
initial commit
currently supports: auto-patch add overlay to eix index show diff to old eix index on emerge --sync Add this to your make.conf: # portage autopatch PATCH_OVERLAY="/var/lib/portage/patches" # portage overlays source /etc/portage/overlays/make.conf and create configs for the overlays in /etc/portage/overlays. Currently the only supported options are LOCATION and CACHE_FORMAT (for eix) in bash syntax like: LOCATION="/var/portage/repositories/proaudio" CACHE_FORMAT="parse*" or something like this. If CACHE_FORMAT is missing the default of eix is used. For autopatch you have to put the patches in the subdir: ${PATCH_OVERLAY}/CATEGORY/PACKAGE/ All files in that directory with .patch extension are applied during ebuild execution.
Diffstat (limited to 'postsync.d/50-eix-update')
-rwxr-xr-xpostsync.d/50-eix-update33
1 files changed, 33 insertions, 0 deletions
diff --git a/postsync.d/50-eix-update b/postsync.d/50-eix-update
new file mode 100755
index 0000000..e9eb5ac
--- /dev/null
+++ b/postsync.d/50-eix-update
@@ -0,0 +1,33 @@
+EIXCACHE=$(update-eix --print EIX_CACHEFILE)
+OVERLAY_CONFIG_DIR="$(update-eix --print EIXCFGDIR)/overlays"
+
+TMPFILE=""
+if [ -r "${EIXCACHE}" ]; then
+ TMPFILE=$(mktemp -t eix.cache.XXXXXXXX)
+ cp "${EIXCACHE}" "${TMPFILE}"
+fi
+
+OVERLAY_PARAM=""
+for overlay_config in $(ls ${OVERLAY_CONFIG_DIR}); do
+ unset LOCATION
+ unset SYNC
+ unset CACHE_FORMAT
+
+ source ${OVERLAY_CONFIG_DIR}/${overlay_config}
+ if [[ -n ${LOCATION} ]]; then
+ OVERLAY_PARAM="${OVERLAY_PARAM} --add-overlay ${LOCATION}"
+
+ if [[ -n ${CACHE_FORMAT} ]]; then
+ OVERLAY_PARAM="${OVERLAY_PARAM} -m ${LOCATION} ${CACHE_FORMAT}"
+ fi
+ fi
+done
+
+[ -x /usr/bin/update-eix ] && /usr/bin/update-eix ${OVERLAY_PARAM}
+
+if [ -r "${EIXCACHE}" -a -r "${TMPFILE}" ]; then
+ echo
+ diff-eix "${TMPFILE}"
+ echo
+ rm -f "${TMPFILE}"
+fi