summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoramnesia <amnesia@boum.org>2010-08-10 10:28:30 (GMT)
committeramnesia <amnesia@boum.org>2010-08-10 11:09:52 (GMT)
commit14776de3d9a42e49f933cf064ce0db608ff1c3cb (patch)
tree8957f5d83a1573f890b58b74ea36aecea165e21b
parentf85fe5b17db81f8bc6677a80818a952a1309c5bb (diff)
Migrate to live-boot / live-config instead of live-initramfs.
Tons of involved changes. The $HOME files have been moved to /etc/skel in order to get rid of permissions problems: we now let adduser deal with this. New custom packages: - live-boot 2.0~a16-1+tails1.cb5e34 built from our Git repository. It integrates the changes our custom live-initramfs had. - live-config patched with xserver-xorg related fixes sent today on the Debian Live ML; hopefully this is only temporary...
-rwxr-xr-xauto/config2
-rwxr-xr-xconfig/binary_local-hooks/20-syslinux_i18n18
-rw-r--r--config/chroot_apt/preferences12
-rwxr-xr-xconfig/chroot_local-hooks/01-password2
-rwxr-xr-xconfig/chroot_local-hooks/15-fix_X117
-rwxr-xr-xconfig/chroot_local-hooks/99-permissions3
-rw-r--r--config/chroot_local-includes/etc/live/config.conf.d/hostname1
-rw-r--r--config/chroot_local-includes/etc/live/config.conf.d/username1
-rw-r--r--config/chroot_local-includes/etc/live/config.conf.d/x-session-manager1
-rw-r--r--config/chroot_local-includes/etc/skel/.bash_logout (renamed from config/chroot_local-includes/home/amnesia/.bash_logout)0
-rw-r--r--config/chroot_local-includes/etc/skel/.bashrc (renamed from config/chroot_local-includes/home/amnesia/.bashrc)0
-rw-r--r--config/chroot_local-includes/etc/skel/.claws-mail/accountrc.tmpl (renamed from config/chroot_local-includes/home/amnesia/.claws-mail/accountrc.tmpl)0
-rw-r--r--config/chroot_local-includes/etc/skel/.claws-mail/clawsrc (renamed from config/chroot_local-includes/home/amnesia/.claws-mail/clawsrc)0
-rw-r--r--config/chroot_local-includes/etc/skel/.claws-mail/dispheaderrc (renamed from config/chroot_local-includes/home/amnesia/.claws-mail/dispheaderrc)0
-rw-r--r--config/chroot_local-includes/etc/skel/.config/autostart/localize.desktop (renamed from config/chroot_local-includes/home/amnesia/.config/autostart/localize.desktop)0
-rw-r--r--config/chroot_local-includes/etc/skel/.config/autostart/onboard.desktop (renamed from config/chroot_local-includes/home/amnesia/.config/autostart/onboard.desktop)0
-rw-r--r--config/chroot_local-includes/etc/skel/.config/autostart/security-check.desktop (renamed from config/chroot_local-includes/home/amnesia/.config/autostart/security-check.desktop)0
-rw-r--r--config/chroot_local-includes/etc/skel/.config/autostart/vidalia.desktop (renamed from config/chroot_local-includes/home/amnesia/.config/autostart/vidalia.desktop)0
-rw-r--r--config/chroot_local-includes/etc/skel/.profile (renamed from config/chroot_local-includes/home/amnesia/.profile)0
-rw-r--r--config/chroot_local-includes/etc/skel/.purple/accounts.xml (renamed from config/chroot_local-includes/home/amnesia/.purple/accounts.xml)0
-rw-r--r--config/chroot_local-includes/etc/skel/.purple/blist.xml (renamed from config/chroot_local-includes/home/amnesia/.purple/blist.xml)0
-rw-r--r--config/chroot_local-includes/etc/skel/.purple/certificates/x509/tls_peers/irc.indymedia.org (renamed from config/chroot_local-includes/home/amnesia/.purple/certificates/x509/tls_peers/irc.indymedia.org)0
-rw-r--r--config/chroot_local-includes/etc/skel/.purple/certificates/x509/tls_peers/jabber.ccc.de (renamed from config/chroot_local-includes/home/amnesia/.purple/certificates/x509/tls_peers/jabber.ccc.de)0
-rw-r--r--config/chroot_local-includes/etc/skel/.purple/prefs.xml (renamed from config/chroot_local-includes/home/amnesia/.purple/prefs.xml)5
l---------config/chroot_local-includes/etc/skel/.tor/control_auth_cookie (renamed from config/chroot_local-includes/home/amnesia/.tor/control_auth_cookie)0
-rw-r--r--config/chroot_local-includes/etc/skel/.vidalia/vidalia.conf (renamed from config/chroot_local-includes/home/amnesia/.vidalia/vidalia.conf)0
-rw-r--r--config/chroot_local-includes/etc/skel/Desktop/Report_a_Bug.desktop (renamed from config/chroot_local-includes/home/amnesia/Desktop/Report_a_Bug.desktop)0
-rw-r--r--config/chroot_local-includes/etc/skel/Desktop/TAILS documentation.desktop (renamed from config/chroot_local-includes/home/amnesia/Desktop/TAILS documentation.desktop)0
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/000-boot-profile37
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/000-readahead41
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/000-resolv-conf14
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/200-import-gnupg-key12
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/201-pidgin28
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/202-localize48
-rwxr-xr-xconfig/chroot_local-includes/lib/live/config/998-permissions12
-rwxr-xr-xconfig/chroot_local-includes/usr/local/bin/home-refresh2
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00boot_profile44
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00readahead45
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00resolv_conf32
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/30import_gnupg_key36
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/31pidgin50
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/32localize72
-rwxr-xr-xconfig/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/98permissions36
-rw-r--r--config/chroot_local-preseed/live-boot1
-rw-r--r--config/chroot_local-preseed/live-initramfs1
45 files changed, 227 insertions, 336 deletions
diff --git a/auto/config b/auto/config
index 2feef35..97c3049 100755
--- a/auto/config
+++ b/auto/config
@@ -19,13 +19,11 @@ $RUN_LH_CONFIG \
--isohybrid-options "$AMNESIA_ISOHYBRID_OPTS" \
--bootappend-live "${AMNESIA_APPEND}" \
--archive-areas "main contrib non-free" \
- --hostname="amnesia" \
--iso-application="The Amnesic Incognito Live System" \
--iso-publisher="https://amnesia.boum.org/" \
--iso-volume="TAILS ${AMNESIA_FULL_VERSION}" \
--memtest none \
--packages-lists="standard" \
- --username="amnesia" \
--syslinux-menu vesamenu \
--syslinux-timeout 4 \
${@}
diff --git a/config/binary_local-hooks/20-syslinux_i18n b/config/binary_local-hooks/20-syslinux_i18n
index ebcd8bb..adec003 100755
--- a/config/binary_local-hooks/20-syslinux_i18n
+++ b/config/binary_local-hooks/20-syslinux_i18n
@@ -63,39 +63,39 @@ for LANG_CODE in ${AMNESIA_SUPPORTED_LANGUAGES}; do
case "${LANG_CODE}" in
ar)
LANG_NAME='^Arabic'
- LANG_APPEND='locale=ar_EG.UTF-8 timezone=Africa/Cairo'
+ LANG_APPEND='locales=ar_EG.UTF-8 timezone=Africa/Cairo'
;;
de)
LANG_NAME='^German'
- LANG_APPEND='locale=de_DE.UTF-8 klayout=de timezone=Europe/Berlin'
+ LANG_APPEND='locales=de_DE.UTF-8 keyboard-layouts=de timezone=Europe/Berlin'
;;
en)
LANG_NAME='^English'
- LANG_APPEND='locale=en_US.UTF-8 klayout=us timezone=America/Detroit'
+ LANG_APPEND='locales=en_US.UTF-8 keyboard-layouts=us timezone=America/Detroit'
;;
es)
LANG_NAME='^Spanish'
- LANG_APPEND='locale=es klayout=es timezone=Europe/Madrid'
+ LANG_APPEND='locales=es keyboard-layouts=es timezone=Europe/Madrid'
;;
fr)
LANG_NAME='^French'
- LANG_APPEND='locale=fr_FR.UTF-8 klayout=fr timezone=Europe/Paris'
+ LANG_APPEND='locales=fr_FR.UTF-8 keyboard-layouts=fr timezone=Europe/Paris'
;;
it)
LANG_NAME='^Italian'
- LANG_APPEND='locale=it timezone=Europe/Rome'
+ LANG_APPEND='locales=it timezone=Europe/Rome'
;;
pt)
LANG_NAME='^Portuguese'
- LANG_APPEND='locale=pt timezone=Europe/Lisbon'
+ LANG_APPEND='locales=pt timezone=Europe/Lisbon'
;;
ru)
LANG_NAME='^Russian'
- LANG_APPEND='locale=ru timezone=Europe/Moscow'
+ LANG_APPEND='locales=ru timezone=Europe/Moscow'
;;
zh)
LANG_NAME='^Chinese'
- LANG_APPEND='locale=zh_CN.UTF-8 klayout=zh timezone=Asia/Shangai'
+ LANG_APPEND='locales=zh_CN.UTF-8 keyboard-layouts=zh timezone=Asia/Shangai'
;;
*)
Echo_error "Language ${LANG_CODE} is not supported yet, ask amnesia developpers!"
diff --git a/config/chroot_apt/preferences b/config/chroot_apt/preferences
index 7bb5a66..df726fa 100644
--- a/config/chroot_apt/preferences
+++ b/config/chroot_apt/preferences
@@ -94,6 +94,18 @@ Package: live-build
Pin: release a=testing
Pin-Priority: 999
+Package: live-config
+Pin: release a=testing
+Pin-Priority: 999
+
+Package: live-config-sysvinit
+Pin: release a=testing
+Pin-Priority: 999
+
+Package: live-initramfs
+Pin: release a=testing
+Pin-Priority: 999
+
Package: monkeysphere
Pin: release a=lenny-backports
Pin-Priority: 999
diff --git a/config/chroot_local-hooks/01-password b/config/chroot_local-hooks/01-password
index eb5316d..2707dcb 100755
--- a/config/chroot_local-hooks/01-password
+++ b/config/chroot_local-hooks/01-password
@@ -7,5 +7,5 @@ echo "root:amnesia" | chpasswd
# Change the autogenerated user password to "amnesia"
plain_password="amnesia"
password=$(echo "${plain_password}" | mkpasswd -s)
-sed -i -e 's/\(user_crypted=\)\(.*\)\( #.*\)/\1\"'${password}'\"\3/' /usr/share/initramfs-tools/scripts/live-bottom/10adduser
+sed -i -e 's/\(_PASSWORD=\)\(.*\)/\1\"'${password}'\"/' /lib/live/config/002-user-setup
update-initramfs -tu -kall
diff --git a/config/chroot_local-hooks/15-fix_X11 b/config/chroot_local-hooks/15-fix_X11
new file mode 100755
index 0000000..52b9a3b
--- /dev/null
+++ b/config/chroot_local-hooks/15-fix_X11
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+if [ ! -d /etc/X11 ]; then
+ mkdir /etc/X11
+ chmod 755 /etc/X11
+fi
+ln -s --force /usr/bin/Xorg /etc/X11/X
diff --git a/config/chroot_local-hooks/99-permissions b/config/chroot_local-hooks/99-permissions
index 5b84694..842336f 100755
--- a/config/chroot_local-hooks/99-permissions
+++ b/config/chroot_local-hooks/99-permissions
@@ -1,5 +1,4 @@
#!/bin/sh
-chown -R 1000:1000 /home/amnesia
chmod go+rX /etc/apt/apt.conf /etc/apt/preferences /etc/apt/sources.list /etc/apt/sources.list.d/*
-
+chmod go+rX /lib /lib/live /lib/live/config
diff --git a/config/chroot_local-includes/etc/live/config.conf.d/hostname b/config/chroot_local-includes/etc/live/config.conf.d/hostname
new file mode 100644
index 0000000..266833c
--- /dev/null
+++ b/config/chroot_local-includes/etc/live/config.conf.d/hostname
@@ -0,0 +1 @@
+LIVE_HOSTNAME=amnesia
diff --git a/config/chroot_local-includes/etc/live/config.conf.d/username b/config/chroot_local-includes/etc/live/config.conf.d/username
new file mode 100644
index 0000000..8f6faf6
--- /dev/null
+++ b/config/chroot_local-includes/etc/live/config.conf.d/username
@@ -0,0 +1 @@
+LIVE_USERNAME=amnesia
diff --git a/config/chroot_local-includes/etc/live/config.conf.d/x-session-manager b/config/chroot_local-includes/etc/live/config.conf.d/x-session-manager
new file mode 100644
index 0000000..a8f8cb3
--- /dev/null
+++ b/config/chroot_local-includes/etc/live/config.conf.d/x-session-manager
@@ -0,0 +1 @@
+LIVE_X_SESSION_MANAGER=/usr/bin/gnome-session
diff --git a/config/chroot_local-includes/home/amnesia/.bash_logout b/config/chroot_local-includes/etc/skel/.bash_logout
index de4f5f7..de4f5f7 100644
--- a/config/chroot_local-includes/home/amnesia/.bash_logout
+++ b/config/chroot_local-includes/etc/skel/.bash_logout
diff --git a/config/chroot_local-includes/home/amnesia/.bashrc b/config/chroot_local-includes/etc/skel/.bashrc
index e0f7d2c..e0f7d2c 100644
--- a/config/chroot_local-includes/home/amnesia/.bashrc
+++ b/config/chroot_local-includes/etc/skel/.bashrc
diff --git a/config/chroot_local-includes/home/amnesia/.claws-mail/accountrc.tmpl b/config/chroot_local-includes/etc/skel/.claws-mail/accountrc.tmpl
index 5edb61e..5edb61e 100644
--- a/config/chroot_local-includes/home/amnesia/.claws-mail/accountrc.tmpl
+++ b/config/chroot_local-includes/etc/skel/.claws-mail/accountrc.tmpl
diff --git a/config/chroot_local-includes/home/amnesia/.claws-mail/clawsrc b/config/chroot_local-includes/etc/skel/.claws-mail/clawsrc
index 750221a..750221a 100644
--- a/config/chroot_local-includes/home/amnesia/.claws-mail/clawsrc
+++ b/config/chroot_local-includes/etc/skel/.claws-mail/clawsrc
diff --git a/config/chroot_local-includes/home/amnesia/.claws-mail/dispheaderrc b/config/chroot_local-includes/etc/skel/.claws-mail/dispheaderrc
index f1d0379..f1d0379 100644
--- a/config/chroot_local-includes/home/amnesia/.claws-mail/dispheaderrc
+++ b/config/chroot_local-includes/etc/skel/.claws-mail/dispheaderrc
diff --git a/config/chroot_local-includes/home/amnesia/.config/autostart/localize.desktop b/config/chroot_local-includes/etc/skel/.config/autostart/localize.desktop
index df8b9f4..df8b9f4 100644
--- a/config/chroot_local-includes/home/amnesia/.config/autostart/localize.desktop
+++ b/config/chroot_local-includes/etc/skel/.config/autostart/localize.desktop
diff --git a/config/chroot_local-includes/home/amnesia/.config/autostart/onboard.desktop b/config/chroot_local-includes/etc/skel/.config/autostart/onboard.desktop
index 6964ace..6964ace 100644
--- a/config/chroot_local-includes/home/amnesia/.config/autostart/onboard.desktop
+++ b/config/chroot_local-includes/etc/skel/.config/autostart/onboard.desktop
diff --git a/config/chroot_local-includes/home/amnesia/.config/autostart/security-check.desktop b/config/chroot_local-includes/etc/skel/.config/autostart/security-check.desktop
index c4753fa..c4753fa 100644
--- a/config/chroot_local-includes/home/amnesia/.config/autostart/security-check.desktop
+++ b/config/chroot_local-includes/etc/skel/.config/autostart/security-check.desktop
diff --git a/config/chroot_local-includes/home/amnesia/.config/autostart/vidalia.desktop b/config/chroot_local-includes/etc/skel/.config/autostart/vidalia.desktop
index e63a08b..e63a08b 100644
--- a/config/chroot_local-includes/home/amnesia/.config/autostart/vidalia.desktop
+++ b/config/chroot_local-includes/etc/skel/.config/autostart/vidalia.desktop
diff --git a/config/chroot_local-includes/home/amnesia/.profile b/config/chroot_local-includes/etc/skel/.profile
index 5e324d7..5e324d7 100644
--- a/config/chroot_local-includes/home/amnesia/.profile
+++ b/config/chroot_local-includes/etc/skel/.profile
diff --git a/config/chroot_local-includes/home/amnesia/.purple/accounts.xml b/config/chroot_local-includes/etc/skel/.purple/accounts.xml
index d61f86c..d61f86c 100644
--- a/config/chroot_local-includes/home/amnesia/.purple/accounts.xml
+++ b/config/chroot_local-includes/etc/skel/.purple/accounts.xml
diff --git a/config/chroot_local-includes/home/amnesia/.purple/blist.xml b/config/chroot_local-includes/etc/skel/.purple/blist.xml
index 8770e06..8770e06 100644
--- a/config/chroot_local-includes/home/amnesia/.purple/blist.xml
+++ b/config/chroot_local-includes/etc/skel/.purple/blist.xml
diff --git a/config/chroot_local-includes/home/amnesia/.purple/certificates/x509/tls_peers/irc.indymedia.org b/config/chroot_local-includes/etc/skel/.purple/certificates/x509/tls_peers/irc.indymedia.org
index 988a67b..988a67b 100644
--- a/config/chroot_local-includes/home/amnesia/.purple/certificates/x509/tls_peers/irc.indymedia.org
+++ b/config/chroot_local-includes/etc/skel/.purple/certificates/x509/tls_peers/irc.indymedia.org
diff --git a/config/chroot_local-includes/home/amnesia/.purple/certificates/x509/tls_peers/jabber.ccc.de b/config/chroot_local-includes/etc/skel/.purple/certificates/x509/tls_peers/jabber.ccc.de
index 8a44ce3..8a44ce3 100644
--- a/config/chroot_local-includes/home/amnesia/.purple/certificates/x509/tls_peers/jabber.ccc.de
+++ b/config/chroot_local-includes/etc/skel/.purple/certificates/x509/tls_peers/jabber.ccc.de
diff --git a/config/chroot_local-includes/home/amnesia/.purple/prefs.xml b/config/chroot_local-includes/etc/skel/.purple/prefs.xml
index 7ed1706..e6931ef 100644
--- a/config/chroot_local-includes/home/amnesia/.purple/prefs.xml
+++ b/config/chroot_local-includes/etc/skel/.purple/prefs.xml
@@ -81,11 +81,6 @@
<pref name='show_notice' type='bool' value='1'/>
<pref name='activate_online' type='bool' value='1'/>
</pref>
- <pref name='core-plugin_pack-autoaccept'>
- <pref name='path' type='string' value='/home/amnesia/.purple/autoaccept'/>
- <pref name='reject_stranger' type='bool' value='1'/>
- <pref name='notify' type='bool' value='1'/>
- </pref>
<pref name='core-plugin_pack-offlinemsg'>
<pref name='always' type='bool' value='0'/>
</pref>
diff --git a/config/chroot_local-includes/home/amnesia/.tor/control_auth_cookie b/config/chroot_local-includes/etc/skel/.tor/control_auth_cookie
index b84d7e5..b84d7e5 120000
--- a/config/chroot_local-includes/home/amnesia/.tor/control_auth_cookie
+++ b/config/chroot_local-includes/etc/skel/.tor/control_auth_cookie
diff --git a/config/chroot_local-includes/home/amnesia/.vidalia/vidalia.conf b/config/chroot_local-includes/etc/skel/.vidalia/vidalia.conf
index fb9b6dc..fb9b6dc 100644
--- a/config/chroot_local-includes/home/amnesia/.vidalia/vidalia.conf
+++ b/config/chroot_local-includes/etc/skel/.vidalia/vidalia.conf
diff --git a/config/chroot_local-includes/home/amnesia/Desktop/Report_a_Bug.desktop b/config/chroot_local-includes/etc/skel/Desktop/Report_a_Bug.desktop
index eb94c5d..eb94c5d 100644
--- a/config/chroot_local-includes/home/amnesia/Desktop/Report_a_Bug.desktop
+++ b/config/chroot_local-includes/etc/skel/Desktop/Report_a_Bug.desktop
diff --git a/config/chroot_local-includes/home/amnesia/Desktop/TAILS documentation.desktop b/config/chroot_local-includes/etc/skel/Desktop/TAILS documentation.desktop
index 6e4120a..6e4120a 100644
--- a/config/chroot_local-includes/home/amnesia/Desktop/TAILS documentation.desktop
+++ b/config/chroot_local-includes/etc/skel/Desktop/TAILS documentation.desktop
diff --git a/config/chroot_local-includes/lib/live/config/000-boot-profile b/config/chroot_local-includes/lib/live/config/000-boot-profile
new file mode 100755
index 0000000..442e080
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/000-boot-profile
@@ -0,0 +1,37 @@
+#!/bin/sh
+
+Boot_profile ()
+{
+ # Only start profiler when "profile" appears on kernel command line
+ grep -qw "profile" /proc/cmdline || return 0
+
+ echo -n " boot-profile"
+
+ Start_boot_profile
+}
+
+Start_boot_profile ()
+{
+
+ # Schedule stop script
+ cat <<EOF >"/home/${LIVE_USERNAME}/.config/autostart/end-profile.desktop"
+[Desktop Entry]
+Version=1.0
+Name=EndProfile
+GenericName=EndProfile
+Exec=/usr/local/bin/end-profile
+Terminal=false
+Type=Application
+EOF
+
+ echo 32768 >/proc/sys/fs/inotify/max_user_watches
+ /usr/local/sbin/boot-profile /var/log/boot-profile
+
+ # Put readahead list at the very begining
+ head -n 1 /usr/share/amnesia/readahead-list >/dev/null || true
+
+ # Creating state file
+ touch /var/lib/live/config/boot-profile
+}
+
+Boot_profile
diff --git a/config/chroot_local-includes/lib/live/config/000-readahead b/config/chroot_local-includes/lib/live/config/000-readahead
new file mode 100755
index 0000000..803e827
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/000-readahead
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+READAHEAD_LIST="/usr/share/amnesia/readahead-list"
+BACKGROUND_AT="^usr/bin/Xorg$"
+
+Readahead ()
+{
+
+ # Do not readahead when "profile" appears on kernel command line
+ grep -qw "profile" /proc/cmdline && return 0
+
+ test -e "$READAHEAD_LIST" || return
+
+ echo " readahead"
+ Start_readahead
+}
+
+Start_readahead ()
+{
+ FG_FILES="$(sed -n "\:$BACKGROUND_AT:q;p" "$READAHEAD_LIST")"
+ BG_FILES="$(sed -n "\:$BACKGROUND_AT:,\$p" "$READAHEAD_LIST")"
+ FG_SIZE=$(
+ cd /
+ echo "$FG_FILES" |
+ xargs du -c 2>/dev/null |
+ awk '$2 ~ /^total$/ { t = t + $1 } END { print t }')
+ (cd /
+ echo "$BG_FILES" |
+ xargs stat >/dev/null 2>/dev/null)
+ (cd /
+ echo "$FG_FILES" |
+ xargs cat 2>/dev/null |
+ pv -f -s ${FG_SIZE}k >/dev/null)
+ (cd /
+ echo "$BG_FILES" | xargs cat >/dev/null 2>&1) &
+
+ # Creating state file
+ touch /var/lib/live/config/readahead
+}
+
+Readahead
diff --git a/config/chroot_local-includes/lib/live/config/000-resolv-conf b/config/chroot_local-includes/lib/live/config/000-resolv-conf
new file mode 100755
index 0000000..7840b4f
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/000-resolv-conf
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+Configure_resolv_conf ()
+{
+
+ echo -n " resolv-conf"
+ rm -f /etc/resolv.conf
+ ln -s /etc/resolvconf/run/resolv.conf /etc/resolv.conf
+
+ # Creating state file
+ touch /var/lib/live/config/resolv-conf
+}
+
+Configure_resolv_conf
diff --git a/config/chroot_local-includes/lib/live/config/200-import-gnupg-key b/config/chroot_local-includes/lib/live/config/200-import-gnupg-key
new file mode 100755
index 0000000..f61fe3a
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/200-import-gnupg-key
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+Import_GnuPG_key ()
+{
+ echo -n "import-gnupg-key"
+ sudo -H -u "${LIVE_USERNAME}" gpg --batch --import /usr/share/doc/amnesia/amnesia.asc
+
+ # Creating state file
+ touch /var/lib/live/config/import-gnupg-key
+}
+
+Import_GnuPG_key
diff --git a/config/chroot_local-includes/lib/live/config/201-pidgin b/config/chroot_local-includes/lib/live/config/201-pidgin
new file mode 100755
index 0000000..0c444a4
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/201-pidgin
@@ -0,0 +1,28 @@
+#!/bin/sh
+
+# List of at least 2000 possible nicknames
+NICKS_LIST=/usr/share/amnesia/firstnames.txt
+
+Configure_pidgin ()
+{
+
+ echo -n " pidgin"
+
+ # 1 =< $NICK_NUMBER <= 2000
+ NICK_NUMBER="`/bin/bash -c 'echo $((${RANDOM} * 2000 / 32768 + 1))'`"
+
+ # 1 =< $NICK_SUFFIX <= 100
+ NICK_SUFFIX="`/bin/bash -c 'echo $((${RANDOM} * 100 / 32768 + 1))'`"
+
+ # Random nick picked from $NICKS_LIST, with $NICK_SUFFIX appended
+ NICK="`head -n ${NICK_NUMBER} ${NICKS_LIST} | tail -n 1 | tr '[:upper:]' '[:lower:]'`${NICK_SUFFIX}"
+
+ for file in accounts.xml blist.xml ; do
+ sudo -H -u "${LIVE_USERNAME}" sed -i'' "s,XXX_NICK_XXX,${NICK}," "/home/${LIVE_USERNAME}/.purple/${file}"
+ done
+
+ # Creating state file
+ touch /var/lib/live/config/pidgin
+}
+
+Configure_pidgin
diff --git a/config/chroot_local-includes/lib/live/config/202-localize b/config/chroot_local-includes/lib/live/config/202-localize
new file mode 100755
index 0000000..0ada299
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/202-localize
@@ -0,0 +1,48 @@
+#!/bin/sh
+
+Localize ()
+{
+ echo -n " localize"
+ # $LANG was set there by the FIXME live-config upstream script
+ . /etc/default/locale
+
+ LANGUAGE="`echo ${LANG} | head -c 2`"
+
+ ### Nautilus wipe script
+
+ if [ ! -d "/home/${LIVE_USERNAME}/.gnome2/nautilus-scripts/" ] ; then
+ mkdir -p "/home/${LIVE_USERNAME}/.gnome2/nautilus-scripts/"
+ fi
+
+ case "${LANGUAGE}" in
+ es)
+ NAME="Eliminar_de_forma_segura"
+ ;;
+ fr)
+ NAME="Effacer_definitivement"
+ ;;
+ *)
+ NAME="Securely_erase"
+ ;;
+ esac
+
+ if [ -x "/usr/local/bin/nautilus-wipe.${LANGUAGE}" ]; then
+ TARGET="/usr/local/bin/nautilus-wipe.${LANGUAGE}"
+ else
+ TARGET="/usr/local/bin/nautilus-wipe"
+ fi
+
+ ln -s "${TARGET}" "/home/${LIVE_USERNAME}/.gnome2/nautilus-scripts/${NAME}"
+
+ ### Scroogle
+
+ if [ -r "/usr/share/amnesia/iceweasel/searchplugins/scroogle-ssl-${LANGUAGE}.xml" ]; then
+ cp "/usr/share/amnesia/iceweasel/searchplugins/scroogle-ssl-${LANGUAGE}.xml" \
+ /usr/share/iceweasel/searchplugins/
+ fi
+
+ # Creating state file
+ touch /var/lib/live/config/localize
+}
+
+Localize
diff --git a/config/chroot_local-includes/lib/live/config/998-permissions b/config/chroot_local-includes/lib/live/config/998-permissions
new file mode 100755
index 0000000..ca70ab2
--- /dev/null
+++ b/config/chroot_local-includes/lib/live/config/998-permissions
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+Fix_permissions ()
+{
+ echo -n " permissions"
+ chown -R "${LIVE_USERNAME}":"${LIVE_USERNAME}" "/home/${LIVE_USERNAME}"
+
+ # Creating state file
+ touch /var/lib/live/config/permissions
+}
+
+Fix_permissions
diff --git a/config/chroot_local-includes/usr/local/bin/home-refresh b/config/chroot_local-includes/usr/local/bin/home-refresh
index 7d53684..4e60071 100755
--- a/config/chroot_local-includes/usr/local/bin/home-refresh
+++ b/config/chroot_local-includes/usr/local/bin/home-refresh
@@ -20,7 +20,7 @@ fi
### init variables
-DEST_DIR="config/chroot_local-includes/home/amnesia"
+DEST_DIR="config/chroot_local-includes/etc/skel"
if [ -z "$1" ]; then
SOURCE_DIR="${AMNESIA_REFRESH_HOME_SOURCE}"
else
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00boot_profile b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00boot_profile
deleted file mode 100755
index d664b71..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00boot_profile
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/bin/sh
-
-PREREQ=""
-
-prereqs() {
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-if [ -n "${NOUSER}" ]; then
- exit 0
-fi
-
-# Only start profiler when "profile" appears on kernel command line
-grep -qw "profile" /proc/cmdline || exit 0
-
-. /scripts/live-functions
-
-log_begin_msg "Starting boot profiler"
-
-# Schedule stop script
-cat <<EOF >/root/home/${USERNAME}/.config/autostart/end-profile.desktop
-[Desktop Entry]
-Version=1.0
-Name=EndProfile
-GenericName=EndProfile
-Exec=/usr/local/bin/end-profile
-Terminal=false
-Type=Application
-EOF
-
-echo 32768 >/proc/sys/fs/inotify/max_user_watches
-chroot /root /usr/local/sbin/boot-profile /var/log/boot-profile
-
-# Put readahead list at the very begining
-head -n 1 /root/usr/share/amnesia/readahead-list >/dev/null || true
-
-log_end_msg
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00readahead b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00readahead
deleted file mode 100755
index 0c7efa3..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00readahead
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/bin/sh
-
-PREREQ=""
-
-prereqs() {
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# Do not readahead when "profile" appears on kernel command line
-grep -qw "profile" /proc/cmdline && exit 0
-
-READAHEAD_LIST="/root/usr/share/amnesia/readahead-list"
-BACKGROUND_AT="^usr/bin/Xorg$"
-
-test -e "$READAHEAD_LIST" || exit 0
-
-. /scripts/live-functions
-
-log_begin_msg "Starting reading ahead boot files"
-
-FG_FILES="$(sed -n "\:$BACKGROUND_AT:q;p" "$READAHEAD_LIST")"
-BG_FILES="$(sed -n "\:$BACKGROUND_AT:,\$p" "$READAHEAD_LIST")"
-FG_SIZE=$(
- cd /root
- echo "$FG_FILES" |
- xargs du -c 2>/dev/null |
- awk '$2 ~ /^total$/ { t = t + $1 } END { print t }')
-(cd /root
- echo "$BG_FILES" |
- xargs stat >/dev/null 2>/dev/null)
-(cd /root
- echo "$FG_FILES" |
- xargs cat 2>/dev/null |
- pv -f -s ${FG_SIZE}k >/dev/null)
-(cd /root
- echo "$BG_FILES" | xargs cat >/dev/null 2>&1) &
-
-log_end_msg
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00resolv_conf b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00resolv_conf
deleted file mode 100755
index 2dd67bf..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/00resolv_conf
+++ /dev/null
@@ -1,32 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Configuring /etc/resolv.conf"
-
-# live-initramfs script
-
-chroot /root rm -f /etc/resolv.conf
-chroot /root ln -s /etc/resolvconf/run/resolv.conf /etc/resolv.conf
-
-log_end_msg
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/30import_gnupg_key b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/30import_gnupg_key
deleted file mode 100755
index 03b138f..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/30import_gnupg_key
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOUSER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Importing amnesia's GnuPG key into the live session user's keyring"
-
-# live-initramfs script
-
-chroot /root sudo -H -u "${USERNAME}" gpg --batch --import /usr/share/doc/amnesia/amnesia.asc
-
-log_end_msg
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/31pidgin b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/31pidgin
deleted file mode 100755
index b62cfff..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/31pidgin
+++ /dev/null
@@ -1,50 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOUSER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Randomizing Pidgin IRC nickname"
-
-# live-initramfs script
-
-# List of at least 2000 possible nicknames
-NICKS_LIST=/root/usr/share/amnesia/firstnames.txt
-
-# 1 =< $NICK_NUMBER <= 2000
-NICK_NUMBER="`chroot /root /bin/bash -c 'echo $((${RANDOM} * 2000 / 32768 + 1))'`"
-
-# 1 =< $NICK_SUFFIX <= 100
-NICK_SUFFIX="`chroot /root /bin/bash -c 'echo $((${RANDOM} * 100 / 32768 + 1))'`"
-
-# Random nick picked from $NICKS_LIST, with $NICK_SUFFIX appended
-NICK="`head -n ${NICK_NUMBER} ${NICKS_LIST} | tail -n 1 | chroot /root tr '[:upper:]' '[:lower:]'`${NICK_SUFFIX}"
-
-for file in accounts.xml blist.xml ; do
- chroot /root sudo -H -u "${USERNAME}" sed -i'' "s,XXX_NICK_XXX,${NICK}," "/home/${USERNAME}/.purple/${file}"
-done
-
-log_end_msg
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/32localize b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/32localize
deleted file mode 100755
index 1ce2723..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/32localize
+++ /dev/null
@@ -1,72 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOUSER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Localizing the Live user environment"
-
-# live-initramfs script
-
-# $LANG was set there by the 14locales live-initramfs upstream script
-. /root/etc/default/locale
-
-LANGUAGE="`echo ${LANG} | head -c 2`"
-
-### Nautilus wipe script
-
-if [ ! -d "/root/home/${USERNAME}/.gnome2/nautilus-scripts/" ] ; then
- mkdir -p "/root/home/${USERNAME}/.gnome2/nautilus-scripts/"
-fi
-
-case "${LANGUAGE}" in
- es)
- NAME="Eliminar_de_forma_segura"
- ;;
- fr)
- NAME="Effacer_definitivement"
- ;;
- *)
- NAME="Securely_erase"
- ;;
-esac
-
-if [ -x "/root/usr/local/bin/nautilus-wipe.${LANGUAGE}" ]; then
- TARGET="/usr/local/bin/nautilus-wipe.${LANGUAGE}"
-else
- TARGET="/usr/local/bin/nautilus-wipe"
-fi
-
-ln -s "${TARGET}" "/root/home/${USERNAME}/.gnome2/nautilus-scripts/${NAME}"
-
-### Scroogle
-
-if [ -r "/root/usr/share/amnesia/iceweasel/searchplugins/scroogle-ssl-${LANGUAGE}.xml" ]; then
- cp "/root/usr/share/amnesia/iceweasel/searchplugins/scroogle-ssl-${LANGUAGE}.xml" \
- /root/usr/share/iceweasel/searchplugins/
-fi
-
-log_end_msg
diff --git a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/98permissions b/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/98permissions
deleted file mode 100755
index 6a11e1a..0000000
--- a/config/chroot_local-includes/usr/share/initramfs-tools/scripts/live-bottom/98permissions
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOUSER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Fixing permissions on /home/${USERNAME}"
-
-# live-initramfs script
-
-chroot /root chown -R "${USERNAME}":"${USERNAME}" "/home/${USERNAME}"
-
-log_end_msg
diff --git a/config/chroot_local-preseed/live-boot b/config/chroot_local-preseed/live-boot
new file mode 100644
index 0000000..9e774ef
--- /dev/null
+++ b/config/chroot_local-preseed/live-boot
@@ -0,0 +1 @@
+live-boot live-boot/smem boolean true
diff --git a/config/chroot_local-preseed/live-initramfs b/config/chroot_local-preseed/live-initramfs
deleted file mode 100644
index ed0961b..0000000
--- a/config/chroot_local-preseed/live-initramfs
+++ /dev/null
@@ -1 +0,0 @@
-live-initramfs live-initramfs/smem boolean true