summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2014-02-12 09:23:20 +0100
committerMichael Vogt <mvo@debian.org>2014-02-12 09:23:20 +0100
commit183d522362c95309d70baa418b54096599c17653 (patch)
tree9f0c12dc542c3ec627d7cc384ec55838ae9e63fc
parentce55512d4924b52c985276c62a0c69ac13e203cd (diff)
parent8f3594c3487800edc2a97af1f3290049776dc556 (diff)
Merge remote-tracking branch 'mvo/debian/sid' into debian/sid
Conflicts: test/integration/test-apt-get-download
-rw-r--r--apt-private/private-output.cc3
-rw-r--r--cmdline/apt-get.cc4
-rw-r--r--cmdline/apt.cc2
-rwxr-xr-xtest/integration/test-apt-cli-upgrade6
-rwxr-xr-xtest/integration/test-apt-get-download5
5 files changed, 10 insertions, 10 deletions
diff --git a/apt-private/private-output.cc b/apt-private/private-output.cc
index 2ae112af4..420ca14d5 100644
--- a/apt-private/private-output.cc
+++ b/apt-private/private-output.cc
@@ -30,6 +30,9 @@ unsigned int ScreenWidth = 80 - 1; /* - 1 for the cursor */
bool InitOutput() /*{{{*/
{
+ if (!isatty(STDOUT_FILENO) && _config->FindI("quiet", -1) == -1)
+ _config->Set("quiet","1");
+
c0out.rdbuf(cout.rdbuf());
c1out.rdbuf(cout.rdbuf());
c2out.rdbuf(cout.rdbuf());
diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc
index 2a9964722..4d609104c 100644
--- a/cmdline/apt-get.cc
+++ b/cmdline/apt-get.cc
@@ -1736,10 +1736,6 @@ int main(int argc,const char *argv[]) /*{{{*/
// see if we are in simulate mode
CheckSimulateMode(CmdL);
- // Deal with stdout not being a tty
- if (!isatty(STDOUT_FILENO) && _config->FindI("quiet", -1) == -1)
- _config->Set("quiet","1");
-
// Setup the output streams
InitOutput();
diff --git a/cmdline/apt.cc b/cmdline/apt.cc
index 6fe25e3f3..6ad470faa 100644
--- a/cmdline/apt.cc
+++ b/cmdline/apt.cc
@@ -156,8 +156,6 @@ int main(int argc, const char *argv[]) /*{{{*/
<< std::endl
<< std::endl;
}
- if (!isatty(STDOUT_FILENO) && _config->FindI("quiet", -1) == -1)
- _config->Set("quiet","1");
// See if the help should be shown
if (_config->FindB("help") == true ||
diff --git a/test/integration/test-apt-cli-upgrade b/test/integration/test-apt-cli-upgrade
index 163a55576..21ce69413 100755
--- a/test/integration/test-apt-cli-upgrade
+++ b/test/integration/test-apt-cli-upgrade
@@ -16,8 +16,7 @@ setupaptarchive
APTARCHIVE=$(readlink -f ./aptarchive)
# default is to allow new dependencies
-testequal "Calculating upgrade... Done
-The following NEW packages will be installed:
+testequal "The following NEW packages will be installed:
foo-new-dependency
The following packages will be upgraded:
foo
@@ -28,7 +27,6 @@ Conf foo-new-dependency (2.0 unstable [all])
Conf foo (2.0 unstable [all])" apt upgrade -qq -s
# ensure
-testequal "Calculating upgrade... Done
-The following packages have been kept back:
+testequal "The following packages have been kept back:
foo
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded." apt upgrade -qq -s --no-new-pkgs
diff --git a/test/integration/test-apt-get-download b/test/integration/test-apt-get-download
index ec809e0ce..7cce6ef29 100755
--- a/test/integration/test-apt-get-download
+++ b/test/integration/test-apt-get-download
@@ -44,3 +44,8 @@ rm -f apt_1.0_all.deb apt_2.0_all.deb
# deb:738103
testsuccess aptget download apt apt apt/unstable apt=2.0
testsuccess test -s apt_2.0_all.deb
+
+# deb:738103 - apt-get download foo foo fails
+rm -f apt_*.deb
+aptget download apt apt
+testsuccess test -s apt_2.0_all.deb