diff options
author | Michael Vogt <mvo@ubuntu.com> | 2014-04-01 11:30:00 +0200 |
---|---|---|
committer | Michael Vogt <mvo@ubuntu.com> | 2014-04-01 12:16:03 +0200 |
commit | e5b7e019232f89a97e8ba3cbffa295595daa0351 (patch) | |
tree | 41a84963fb19fc8bc6d9b73bd424390027e8fa8c /apt-pkg/contrib/fileutl.cc | |
parent | 21b3eac8f9ab8e12b43fa8998a5aa5465f29adc5 (diff) |
Add new Debug::RunScripts option
This debug option will display all scripts that are run
by apts RunScripts and RunScriptsWithPkgs helpers.
Diffstat (limited to 'apt-pkg/contrib/fileutl.cc')
-rw-r--r-- | apt-pkg/contrib/fileutl.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/apt-pkg/contrib/fileutl.cc b/apt-pkg/contrib/fileutl.cc index 69406a9bf..188bb87ee 100644 --- a/apt-pkg/contrib/fileutl.cc +++ b/apt-pkg/contrib/fileutl.cc @@ -104,7 +104,11 @@ bool RunScripts(const char *Cnf) { if (Opts->Value.empty() == true) continue; - + + if(_config->FindB("Debug::RunScripts", false) == true) + std::clog << "Running external script: '" + << Opts->Value << "'" << std::endl; + if (system(Opts->Value.c_str()) != 0) _exit(100+Count); } |