summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authors19n <mailbox@s19n.net>2016-03-31 16:48:45 +0200
committerAlexander Sulfrian <alexander.sulfrian@fu-berlin.de>2017-03-09 21:42:29 +0100
commit4c50a40d9a6fc5eda93186e86f24cf515afe837f (patch)
treebac678bc33853aa134d13bf2979637fc79934366
parent26944da6adc79a14783fee84112a0ae31cbf6d62 (diff)
downloadbcfg2-4c50a40d9a6fc5eda93186e86f24cf515afe837f.tar.gz
bcfg2-4c50a40d9a6fc5eda93186e86f24cf515afe837f.tar.bz2
bcfg2-4c50a40d9a6fc5eda93186e86f24cf515afe837f.zip
Fix multiline scripts in bcfg2-info debug mode
-rw-r--r--src/lib/Bcfg2/Server/Info.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/lib/Bcfg2/Server/Info.py b/src/lib/Bcfg2/Server/Info.py
index 418d984a1..bf23dc4cb 100644
--- a/src/lib/Bcfg2/Server/Info.py
+++ b/src/lib/Bcfg2/Server/Info.py
@@ -143,9 +143,7 @@ class Debug(InfoCmd):
if setup.cmd_list:
console = InteractiveConsole(locals())
for command in setup.cmd_list.readlines():
- command = command.strip()
- if command:
- console.push(command)
+ console.push(command.rstrip())
if not setup.non_interactive:
print("Dropping to interpreter; press ^D to resume")
self.interpreters[setup.interpreter](self.core.get_locals())