X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;ds=inline;f=dak%2Ftransitions.py;h=a214337e5a0288d3e8f1ee46d04e3798d747b47e;hb=b612f3da207fa0d75a5d3b204ac8f02bb244231a;hp=00348f2dc842c1e50978b07a4046d19864e0f4d3;hpb=1d800d8d6b8bcdd246ab9da3b33d9e13b38b13d7;p=dak.git diff --git a/dak/transitions.py b/dak/transitions.py index 00348f2d..a214337e 100755 --- a/dak/transitions.py +++ b/dak/transitions.py @@ -85,9 +85,7 @@ def init(): if Options["help"]: usage() - whoami = os.getuid() - whoamifull = pwd.getpwuid(whoami) - username = whoamifull[0] + username = utils.getusername() if username != "dak": print "Non-dak user: %s" % username Options["sudo"] = "y" @@ -452,8 +450,9 @@ def check_transitions(transitions): elif answer == 'y': print "Committing" subst = {} + subst['__SUBJECT__'] = "Transitions completed: " + ", ".join(sorted(to_remove)) subst['__TRANSITION_MESSAGE__'] = "The following transitions were removed:\n" - for remove in to_remove: + for remove in sorted(to_remove): subst['__TRANSITION_MESSAGE__'] += info[remove] + '\n' del transitions[remove]