Browse Source

Add some modules for ezsync

master
belliash 8 years ago
parent
commit
a9e55c3866
6 changed files with 56 additions and 26 deletions
  1. +1
    -0
      config/modules/openrc-branding.conf
  2. +13
    -0
      modules/gentoo-compat.ezmod
  3. +13
    -0
      modules/mini-manifest.ezmod
  4. +14
    -0
      modules/openrc-branding.ezmod
  5. +0
    -26
      modules/sample.ezmod
  6. +15
    -0
      modules/thin-manifest.ezmod

+ 1
- 0
config/modules/openrc-branding.conf View File

@@ -0,0 +1 @@
CUSTOM_OPENRC_BRAND="reGen2"

+ 13
- 0
modules/gentoo-compat.ezmod View File

@@ -0,0 +1,13 @@
# Copyright 2010-2012, Asio Software Technologies
# Distributed under the terms of the GNU General Public License v3
EZMOD_DESCRIPTION="Enables various compatibility options in Portage tree"
EZMOD_COMPATIBILITY="ezsync"
EZMOD_AUTHOR="Rafal Kupiec"
EZMOD_VERSION="1.0"

ezsync_precommit() {
printInfo "Enabling compatibility options..."
echo "cache-formats = md5-dict pms" >> ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/metadata/layout.conf
echo "profile-formats = portage-1" >> ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/metadata/layout.conf
return 0
}

+ 13
- 0
modules/mini-manifest.ezmod View File

@@ -0,0 +1,13 @@
# Copyright 2010-2012, Asio Software Technologies
# Distributed under the terms of the GNU General Public License v3
EZMOD_DESCRIPTION="Minifies Portage tree with so-called mini-manifests"
EZMOD_COMPATIBILITY="ezsync"
EZMOD_AUTHOR="Rafal Kupiec"
EZMOD_VERSION="1.0"

ezsync_precommit() {
printInfo "Preparing mini-manifests..."
find ${PORTAGESDIR}/${PORTAGE_BUILD[0]} -type f -iname changelog -exec rm -f {} \;
find ${PORTAGESDIR}/${PORTAGE_BUILD[0]} -type f -iname manifest -exec sed -n -i -e "/DIST/p" {} \;
return 0
}

+ 14
- 0
modules/openrc-branding.ezmod View File

@@ -0,0 +1,14 @@
# Copyright 2010-2012, Asio Software Technologies
# Distributed under the terms of the GNU General Public License v3
EZMOD_DESCRIPTION="Allows to re-brand the OpenRC package"
EZMOD_COMPATIBILITY="ezsync"
EZMOD_AUTHOR="Rafal Kupiec"
EZMOD_VERSION="1.0"

ezsync_precommit() {
printInfo "Enabling custom OpenRC branding..."
find ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/sys-apps/openrc -type f -name \*.ebuild | while read EBUILD; do
sed -i "s/BRANDING=\"Gentoo \${brand}\"/BRANDING=\"${CUSTOM_OPENRC_BRAND} \${brand}\"/g" ${EBUILD} || return 1
done
return 0
}

+ 0
- 26
modules/sample.ezmod View File

@@ -1,26 +0,0 @@
# Copyright 2010-2012, Asio Software Technologies
# Distributed under the terms of the GNU General Public License v3
EZMOD_DESCRIPTION="Sample module for learning and testing purposes"
EZMOD_COMPATIBILITY="ezbuild ezsync"
EZMOD_AUTHOR="Rafal Kupiec"
EZMOD_VERSION="0.3"

ezsync_presync() {
printWarn "Sample module loaded"
return 0
}

ezsync_postsync() {
printWarn "Sample module loaded"
return 0
}

ezsync_precommit() {
printWarn "Sample module loaded"
return 0
}

ezsync_postcommit() {
printWarn "Sample module loaded"
return 0
}

+ 15
- 0
modules/thin-manifest.ezmod View File

@@ -0,0 +1,15 @@
# Copyright 2010-2012, Asio Software Technologies
# Distributed under the terms of the GNU General Public License v3
EZMOD_DESCRIPTION="Minifies Portage tree with so-called thin-manifests"
EZMOD_COMPATIBILITY="ezsync"
EZMOD_AUTHOR="Rafal Kupiec"
EZMOD_VERSION="1.0"

ezsync_precommit() {
printInfo "Preparing thin-manifests..."
find ${PORTAGESDIR}/${PORTAGE_BUILD[0]} -type f -iname changelog -exec rm -f {} \;
find ${PORTAGESDIR}/${PORTAGE_BUILD[0]} -type f -iname manifest -exec sed -n -i -e "/DIST/p" {} \;
echo "thin-manifests = true" >> ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/metadata/layout.conf
echo "sign-manifests = false" >> ${PORTAGESDIR}/${PORTAGE_BUILD[0]}/metadata/layout.conf
return 0
}

Loading…
Cancel
Save