From b57213f61cd7d161f6a5cfd9da62f7df74fb2de8 Mon Sep 17 00:00:00 2001 From: Cyryl Plotnicki-Chudyk Date: Sun, 19 Jul 2015 10:34:30 +0200 Subject: [PATCH] use the 'dont ask' prefix for system upgrade as well --- ubuntu/configure_fresh_system | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/ubuntu/configure_fresh_system b/ubuntu/configure_fresh_system index 59e0386e..bee8327b 100755 --- a/ubuntu/configure_fresh_system +++ b/ubuntu/configure_fresh_system @@ -1,16 +1,18 @@ #!/bin/bash -sudo apt-get update -sudo apt-get dist-upgrade -y - # detect if building inside a CI system, like Travis if [ -z ${IN_CI+x} ]; then - INSTALL_COMMAND="sudo DEBIAN_FRONTEND=noninteractive apt-get -y -o Dpkg::Options::=\"--force-confdef\" -o Dpkg::Options::=\"--force-confnew\" install"; + COMMAND_PREFIX="DEBIAN_FRONTEND=noninteractive apt-get -y -o Dpkg::Options::=\"--force-confdef\" -o Dpkg::Options::=\"--force-confnew\""; else - INSTALL_COMMAND="sudo apt-get install -y"; + COMMAND_PREFIX="apt-get -y"; fi -$INSTALL_COMMAND="$INSTALL_COMMAND meld whois zsh tmux vim atop aria2 curl pv pixz gajim tor torsocks nodejs npm terminator gsmartcontrol python-pip mesa-utils mesa-utils-extra aptitude p7zip-full p7zip-rar thunderbird mercurial kdiff3 gnupg2 python3-setuptools aircrack-ng macchanger" +sudo apt-get update +UPGRADE_COMMAND="sudo $COMMAND_PREFIX dist-upgrade" +eval ${UPGRADE_COMMAND} + +$INSTALL_COMMAND="$COMMAND_PREFIX install meld whois zsh tmux vim atop aria2 curl pv pixz gajim tor torsocks nodejs npm terminator gsmartcontrol python-pip mesa-utils mesa-utils-extra aptitude p7zip-full p7zip-rar thunderbird mercurial kdiff3 gnupg2 python3-setuptools aircrack-ng macchanger" eval ${INSTALL_COMMAND} + DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" DIR="$DIR/../" DIR="$DIR" $DIR/common/configure_fresh_system