From: Chris Gianelloni Date: Thu, 7 Feb 2008 01:11:30 +0000 (+0000) Subject: Changed the code for copying the MOTD files so it's fewer lines and makes more sense. X-Git-Tag: CATALYST_2_0_6_916~213 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=54e5cff8baf201d2063f1b04112f861fdab7d9ba;p=catalyst.git Changed the code for copying the MOTD files so it's fewer lines and makes more sense. git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@1281 d1e1f19c-881f-0410-ab34-b69fee027534 --- diff --git a/ChangeLog b/ChangeLog index 1fab2dd1..fca0dac3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,11 @@ # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2 # $Id: $ + 07 Feb 2008; Chris Gianelloni + targets/livecd-stage2/livecd-stage2-controller.sh: + Changed the code for copying the MOTD files so it's fewer lines and makes + more sense. + 06 Feb 2008; Chris Gianelloni +arch/powerpc.py, -arch/ppc.py, -arch/ppc64.py, arch/sparc.py, -arch/sparc64.py: Merged ppc.py and ppc64.py into powerpc.py and merged sparc.py and diff --git a/targets/livecd-stage2/livecd-stage2-controller.sh b/targets/livecd-stage2/livecd-stage2-controller.sh index b1649f57..2b2920ad 100755 --- a/targets/livecd-stage2/livecd-stage2-controller.sh +++ b/targets/livecd-stage2/livecd-stage2-controller.sh @@ -31,33 +31,28 @@ case $1 in preclean) # Move over the motd (if applicable) - if [ -n "${clst_livecd_motd}" ] - then - case ${clst_livecd_type} in - gentoo-*) + case ${clst_livecd_type} in + gentoo-*) + if [ -n "${clst_livecd_motd}" ] + then echo "Using livecd/motd is not supported with livecd/type" echo "${clst_livecd_type}. You should switch to using" echo "generic-livecd instead." - cp -pPR ${clst_sharedir}/livecd/files/generic.motd.txt \ - ${clst_sharedir}/livecd/files/universal.motd.txt \ - ${clst_sharedir}/livecd/files/minimal.motd.txt \ - ${clst_sharedir}/livecd/files/livecd.motd.txt \ - ${clst_sharedir}/livecd/files/gamecd.motd.txt \ - ${clst_chroot_path}/etc - ;; - *) + fi + cp -pPR ${clst_sharedir}/livecd/files/generic.motd.txt \ + ${clst_sharedir}/livecd/files/universal.motd.txt \ + ${clst_sharedir}/livecd/files/minimal.motd.txt \ + ${clst_sharedir}/livecd/files/livecd.motd.txt \ + ${clst_sharedir}/livecd/files/gamecd.motd.txt \ + ${clst_chroot_path}/etc + ;; + *) + if [ -n "${clst_livecd_motd}" ] + then cp -pPR ${clst_livecd_motd} ${clst_chroot_path}/etc/motd - ;; - esac - elif [ "${clst_livecd_type}" != "generic-livecd" ] - then - cp -pPR ${clst_sharedir}/livecd/files/generic.motd.txt \ - ${clst_sharedir}/livecd/files/universal.motd.txt \ - ${clst_sharedir}/livecd/files/minimal.motd.txt \ - ${clst_sharedir}/livecd/files/livecd.motd.txt \ - ${clst_sharedir}/livecd/files/gamecd.motd.txt \ - ${clst_chroot_path}/etc - fi + fi + ;; + esac # move over the environment cp -f ${clst_sharedir}/livecd/files/livecd-bashrc \