Skip to content

Instantly share code, notes, and snippets.

@kujhawk94
Forked from callahad/lenny-to-wheezy.sh
Created July 19, 2013 16:40
Show Gist options
  • Save kujhawk94/6040572 to your computer and use it in GitHub Desktop.
Save kujhawk94/6040572 to your computer and use it in GitHub Desktop.
#!/bin/bash
# -- Set up environment variables for unattended installation of packages
export DEBIAN_FRONTEND=noninteractive
export DEBIAN_PRIORITY=critical
# -- Update to a newer debian-archive-keyring
aptitude update
aptitude -q -y install debian-archive-keyring
# -- Change the APT repositories
cat > /etc/apt/sources.list <<EOF
deb http://ftp.us.debian.org/debian/ testing main
deb-src http://ftp.us.debian.org/debian/ testing main
EOF
# -- Update the package cache and do a full upgrade
aptitude update
aptitude -q -y -o DPKG::Options::=--force-confnew safe-upgrade
aptitude -q -y -o DPKG::Options::=--force-confnew full-upgrade
# -- Set up locales
debconf-set-selections <<EOF
locales locales/locales_to_be_generated multiselect en_US.UTF-8 UTF-8
locales locales/default_environment_locale select en_US.UTF-8
EOF
aptitude -q -y install locales
# -- Reboot
shutdown -r now
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment