Commit dbfa469a authored by Lucas Manika Koeb's avatar Lucas Manika Koeb

le-gera-iso: Create a new templates directory for le5/home

Signed-off-by: default avatarLucas Manika Koeb <lmk08@c3sl.ufpr.br>
parent 674c00a9
escola/
\ No newline at end of file
Package: *
Pin: origin "windu.c3sl.ufpr.br"
Pin-Priority: 1100
#!/bin/sh
PREREQ=""
DESCRIPTION="Adding live session user..."
prereqs()
{
echo "$PREREQ"
}
case $1 in
# get pre-requisites
prereqs)
prereqs
exit 0
;;
esac
. /scripts/casper-functions
load_confmodule
log_begin_msg "$DESCRIPTION"
debconf_backup () {
local question backup
for question; do
backup="$question-casper-backup"
db_register debian-installer/dummy "$backup"
db_get "$question"
db_set "$backup" "$RET"
db_fget "$question" seen
db_fset "$backup" seen "$RET"
done
}
debconf_restore () {
local question backup
for question; do
backup="$question-casper-backup"
db_get "$backup"
db_set "$question" "$RET"
db_fget "$backup" seen
db_fset "$question" seen "$RET"
db_unregister "$backup"
done
}
debconf_backup \
passwd/root-password-crypted \
passwd/root-password passwd/root-password-again \
passwd/user-password-crypted \
passwd/user-password passwd/user-password-again \
passwd/user-fullname passwd/username passwd/user-uid
# U6aMy0wojraho is just a blank password
db_set passwd/root-password-crypted '*'
db_set passwd/user-password-crypted U6aMy0wojraho
db_set passwd/user-fullname "$USERFULLNAME"
db_set passwd/username "$USERNAME"
db_set passwd/user-uid 998
chroot /root /usr/lib/user-setup/user-setup-apply > /dev/null
# Clear out debconf database again to avoid confusing ubiquity later.
debconf_restore \
passwd/root-password-crypted \
passwd/root-password passwd/root-password-again \
passwd/user-password-crypted \
passwd/user-password passwd/user-password-again \
passwd/user-fullname passwd/username passwd/user-uid
if [ -f /root/etc/sudoers ]; then
echo "${USERNAME} ALL=(ALL) NOPASSWD: ALL" >> /root/etc/sudoers
fi
# XXX - awful hack to stop xscreensaver locking the screen (#7150)
echo 'RUNNING_UNDER_GDM="yes"' >> /root/etc/environment
LTS="$(cut -d' ' -f3 /root/cdrom/.disk/info 2>/dev/null)" || LTS=
RELEASE="$(cut -d' ' -f1-2 /root/cdrom/.disk/info 2>/dev/null)" || RELEASE=
if [ "$LTS" = "LTS" ] && [ -n "$RELEASE" ]; then
RELEASE="$RELEASE LTS"
fi
for file in /usr/share/applications/ubiquity-gtkui.desktop /usr/share/applications/kde4/ubiquity-kdeui.desktop; do
if [ -f "/root/$file" ]; then
sed -i "s/RELEASE/$RELEASE/" "/root$file"
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME $file /home/$USERNAME/Desktop/$(basename "$file")
break
fi
done
if [ -L /root/home/$USERNAME/Examples ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/Examples /root/home/$USERNAME/Desktop/
fi
if [ -f /root/home/$USERNAME/examples.desktop ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/examples.desktop /root/home/$USERNAME/Desktop/
fi
#Kubuntu
if [ -f "/root/usr/bin/plasma" ]; then
if [ -f "/root/usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop" ]; then
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME /usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop /home/$USERNAME/Desktop/about-kubuntu.desktop
fi
fi
#Ubuntu MID wants to be installed with --automatic
if [ -f "/root/usr/share/ubuntu-mid-default-settings/mid-gui-start" ]; then
if [ -f "/root/usr/share/applications/ubiquity-gtkui.desktop" ]; then
sed -i 's/--desktop/--automatic --desktop/' "/root/usr/share/applications/ubiquity-gtkui.desktop"
fi
fi
#Ubuntu MID uses kourou, and the ubiquity icon should be easy to find
if [ -f "/root/usr/lib/hildon-desktop/kourou.py" ]; then
if [ -f "/root/etc/xdg/menus/home.menu" ]; then
sed -i '/<\/Include>/i\ <Filename>ubiquity-gtkui.desktop</Filename>' "/root/etc/xdg/menus/home.menu"
fi
fi
log_end_msg
#!/bin/sh
PREREQ=""
DESCRIPTION="Adding live session user..."
prereqs()
{
echo "$PREREQ"
}
case $1 in
# get pre-requisites
prereqs)
prereqs
exit 0
;;
esac
. /scripts/casper-functions
load_confmodule
log_begin_msg "$DESCRIPTION"
# U6aMy0wojraho is just a blank password
db_set passwd/root-password-crypted '*'
db_set passwd/user-password-crypted U6aMy0wojraho
db_set passwd/user-fullname "$USERFULLNAME"
db_set passwd/username "$USERNAME"
db_set passwd/user-uid 998
chroot /root /usr/lib/user-setup/user-setup-apply > /dev/null
# Clear out debconf database again to avoid confusing ubiquity later.
db_set passwd/root-password-crypted
db_set passwd/user-password-crypted
db_set passwd/user-fullname
db_set passwd/username
db_set passwd/user-uid
if [ -f /root/etc/sudoers ]; then
if grep -q '^%admin' /root/etc/sudoers; then
sed -i -e '/^%admin/s/(ALL) ALL$/(ALL) NOPASSWD: ALL/' /root/etc/sudoers
else
echo '%admin ALL=(ALL) NOPASSWD: ALL' >> /root/etc/sudoers
fi
fi
# XXX - awful hack to stop xscreensaver locking the screen (#7150)
echo 'RUNNING_UNDER_GDM="yes"' >> /root/etc/environment
LTS="$(cut -d' ' -f3 /root/cdrom/.disk/info 2>/dev/null)" || LTS=
RELEASE="$(cut -d' ' -f1-2 /root/cdrom/.disk/info 2>/dev/null)" || RELEASE=
if [ "$LTS" = "LTS" ] && [ -n "$RELEASE" ]; then
RELEASE="$RELEASE LTS"
fi
for file in /usr/share/applications/ubiquity-gtkui.desktop /usr/share/applications/kde4/ubiquity-kdeui.desktop; do
if [ -f "/root/$file" ]; then
sed -i "s/RELEASE/$RELEASE/" "/root$file"
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME $file /home/$USERNAME/Desktop/$(basename "$file")
break
fi
done
if [ -L /root/home/$USERNAME/Examples ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/Examples /root/home/$USERNAME/Desktop/
fi
if [ -f /root/home/$USERNAME/examples.desktop ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/examples.desktop /root/home/$USERNAME/Desktop/
fi
#Kubuntu
if [ -f "/root/usr/bin/plasma" ]; then
if [ -f "/root/usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop" ]; then
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME /usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop /home/$USERNAME/Desktop/about-kubuntu.desktop
fi
fi
#Ubuntu MID wants to be installed with --automatic
if [ -f "/root/usr/share/ubuntu-mid-default-settings/mid-gui-start" ]; then
if [ -f "/root/usr/share/applications/ubiquity-gtkui.desktop" ]; then
sed -i 's/--desktop/--automatic --desktop/' "/root/usr/share/applications/ubiquity-gtkui.desktop"
fi
fi
#Ubuntu MID uses kourou, and the ubiquity icon should be easy to find
if [ -f "/root/usr/lib/hildon-desktop/kourou.py" ]; then
if [ -f "/root/etc/xdg/menus/home.menu" ]; then
sed -i '/<\/Include>/i\ <Filename>ubiquity-gtkui.desktop</Filename>' "/root/etc/xdg/menus/home.menu"
fi
fi
log_end_msg
#!/bin/sh
PREREQ=""
DESCRIPTION="Adding live session user..."
prereqs()
{
echo "$PREREQ"
}
case $1 in
# get pre-requisites
prereqs)
prereqs
exit 0
;;
esac
. /scripts/casper-functions
load_confmodule
log_begin_msg "$DESCRIPTION"
debconf_backup () {
local question backup
for question; do
backup="$question-casper-backup"
db_register debian-installer/dummy "$backup"
db_get "$question"
db_set "$backup" "$RET"
db_fget "$question" seen
db_fset "$backup" seen "$RET"
done
}
debconf_restore () {
local question backup
for question; do
backup="$question-casper-backup"
db_get "$backup"
db_set "$question" "$RET"
db_fget "$backup" seen
db_fset "$question" seen "$RET"
db_unregister "$backup"
done
}
debconf_backup \
passwd/root-password-crypted \
passwd/root-password passwd/root-password-again \
passwd/user-password-crypted \
passwd/user-password passwd/user-password-again \
passwd/user-fullname passwd/username passwd/user-uid
# U6aMy0wojraho is just a blank password
db_set passwd/root-password-crypted '*'
db_set passwd/user-password-crypted U6aMy0wojraho
db_set passwd/user-fullname "$USERFULLNAME"
db_set passwd/username "$USERNAME"
db_set passwd/user-uid 998
chroot /root /usr/lib/user-setup/user-setup-apply > /dev/null
# Clear out debconf database again to avoid confusing ubiquity later.
debconf_restore \
passwd/root-password-crypted \
passwd/root-password passwd/root-password-again \
passwd/user-password-crypted \
passwd/user-password passwd/user-password-again \
passwd/user-fullname passwd/username passwd/user-uid
if [ -f /root/etc/sudoers ]; then
echo "${USERNAME} ALL=(ALL) NOPASSWD: ALL" >> /root/etc/sudoers
fi
# XXX - awful hack to stop xscreensaver locking the screen (#7150)
echo 'RUNNING_UNDER_GDM="yes"' >> /root/etc/environment
LTS="$(cut -d' ' -f3 /root/cdrom/.disk/info 2>/dev/null)" || LTS=
RELEASE="$(cut -d' ' -f1-2 /root/cdrom/.disk/info 2>/dev/null)" || RELEASE=
if [ "$LTS" = "LTS" ] && [ -n "$RELEASE" ]; then
RELEASE="$RELEASE LTS"
fi
for file in /usr/share/applications/ubiquity-gtkui.desktop /usr/share/applications/kde4/ubiquity-kdeui.desktop; do
if [ -f "/root/$file" ]; then
sed -i "s/RELEASE/$RELEASE/" "/root$file"
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME $file /home/$USERNAME/Desktop/$(basename "$file")
break
fi
done
if [ -L /root/home/$USERNAME/Examples ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/Examples /root/home/$USERNAME/Desktop/
fi
if [ -f /root/home/$USERNAME/examples.desktop ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/examples.desktop /root/home/$USERNAME/Desktop/
fi
#Kubuntu
if [ -f "/root/usr/bin/plasma" ]; then
if [ -f "/root/usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop" ]; then
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME /usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop /home/$USERNAME/Desktop/about-kubuntu.desktop
fi
fi
#Ubuntu MID wants to be installed with --automatic
if [ -f "/root/usr/share/ubuntu-mid-default-settings/mid-gui-start" ]; then
if [ -f "/root/usr/share/applications/ubiquity-gtkui.desktop" ]; then
sed -i 's/--desktop/--automatic --desktop/' "/root/usr/share/applications/ubiquity-gtkui.desktop"
fi
fi
#Ubuntu MID uses kourou, and the ubiquity icon should be easy to find
if [ -f "/root/usr/lib/hildon-desktop/kourou.py" ]; then
if [ -f "/root/etc/xdg/menus/home.menu" ]; then
sed -i '/<\/Include>/i\ <Filename>ubiquity-gtkui.desktop</Filename>' "/root/etc/xdg/menus/home.menu"
fi
fi
log_end_msg
#!/bin/sh
PREREQ=""
DESCRIPTION="Adding live session user..."
prereqs()
{
echo "$PREREQ"
}
case $1 in
# get pre-requisites
prereqs)
prereqs
exit 0
;;
esac
. /scripts/casper-functions
load_confmodule
log_begin_msg "$DESCRIPTION"
# U6aMy0wojraho is just a blank password
db_set passwd/root-password-crypted '*'
db_set passwd/user-password-crypted U6aMy0wojraho
db_set passwd/user-fullname "$USERFULLNAME"
db_set passwd/username "$USERNAME"
db_set passwd/user-uid 998
chroot /root /usr/lib/user-setup/user-setup-apply > /dev/null
# Clear out debconf database again to avoid confusing ubiquity later.
db_set passwd/root-password-crypted
db_set passwd/user-password-crypted
db_set passwd/user-fullname
db_set passwd/username
db_set passwd/user-uid
if [ -f /root/etc/sudoers ]; then
if grep -q '^%admin' /root/etc/sudoers; then
sed -i -e '/^%admin/s/(ALL) ALL$/(ALL) NOPASSWD: ALL/' /root/etc/sudoers
else
echo '%admin ALL=(ALL) NOPASSWD: ALL' >> /root/etc/sudoers
fi
fi
# XXX - awful hack to stop xscreensaver locking the screen (#7150)
echo 'RUNNING_UNDER_GDM="yes"' >> /root/etc/environment
LTS="$(cut -d' ' -f3 /root/cdrom/.disk/info 2>/dev/null)" || LTS=
RELEASE="$(cut -d' ' -f1-2 /root/cdrom/.disk/info 2>/dev/null)" || RELEASE=
if [ "$LTS" = "LTS" ] && [ -n "$RELEASE" ]; then
RELEASE="$RELEASE LTS"
fi
for file in /usr/share/applications/ubiquity-gtkui.desktop /usr/share/applications/kde4/ubiquity-kdeui.desktop; do
if [ -f "/root/$file" ]; then
sed -i "s/RELEASE/$RELEASE/" "/root$file"
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME $file /home/$USERNAME/Desktop/$(basename "$file")
break
fi
done
if [ -L /root/home/$USERNAME/Examples ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/Examples /root/home/$USERNAME/Desktop/
fi
if [ -f /root/home/$USERNAME/examples.desktop ]; then
chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
mv /root/home/$USERNAME/examples.desktop /root/home/$USERNAME/Desktop/
fi
#Kubuntu
if [ -f "/root/usr/bin/plasma" ]; then
if [ -f "/root/usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop" ]; then
chroot /root install -d -o $USERNAME -g $USERNAME /home/$USERNAME/Desktop
chroot /root install -D -o $USERNAME -g $USERNAME /usr/share/kde4/apps/khelpcenter/plugins/kubuntu/about-kubuntu.desktop /home/$USERNAME/Desktop/about-kubuntu.desktop
fi
fi
#Ubuntu MID wants to be installed with --automatic
if [ -f "/root/usr/share/ubuntu-mid-default-settings/mid-gui-start" ]; then
if [ -f "/root/usr/share/applications/ubiquity-gtkui.desktop" ]; then
sed -i 's/--desktop/--automatic --desktop/' "/root/usr/share/applications/ubiquity-gtkui.desktop"
fi
fi
#Ubuntu MID uses kourou, and the ubiquity icon should be easy to find
if [ -f "/root/usr/lib/hildon-desktop/kourou.py" ]; then
if [ -f "/root/etc/xdg/menus/home.menu" ]; then
sed -i '/<\/Include>/i\ <Filename>ubiquity-gtkui.desktop</Filename>' "/root/etc/xdg/menus/home.menu"
fi
fi
log_end_msg
#!/bin/sh
PREREQ=""
DESCRIPTION="Adding live session user..."
prereqs()
{
echo "$PREREQ"
}
case $1 in
# get pre-requisites
prereqs)
prereqs
exit 0
;;
esac