From 53bee19a99389e06f53edb7491083d616d5aa5e6 Mon Sep 17 00:00:00 2001 From: Lord Anton Hvornum Date: Fri, 13 Apr 2018 06:54:22 +0200 Subject: More debugging --- archinstall.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'archinstall.py') diff --git a/archinstall.py b/archinstall.py index 5929de13..1966ea6e 100644 --- a/archinstall.py +++ b/archinstall.py @@ -45,7 +45,8 @@ def get_local_MACs(): def run(cmd, echo=False, opts=None, *args, **kwargs): if not opts: opts = {} - #print('[!] {}'.format(cmd)) + if echo or 'debug' in opts: + print('[!] {}'.format(cmd)) handle = Popen(cmd, shell='True', stdout=PIPE, stderr=STDOUT, **kwargs) output = b'' while handle.poll() is None: @@ -334,3 +335,7 @@ if __name__ == '__main__': o = run('reboot now') else: print('Done. "umount -R /mnt; reboot" when you\'re done tinkering.') + + + +'su - postgres -c "psql -c \'CREATE USER pdns WITH PASSWORD \\\'SomePassword\\\';\'"' -- cgit v1.2.3-70-g09d2