def signoff(self): try: import pwd user = pwd.getpwuid(os.getuid()).pw_name except ImportError: user = os.getenv('USER', N_('unknown')) name = _config.get('user.name', user) email = _config.get('user.email', '%s@%s' % (user, core.node())) return '\nSigned-off-by: %s <%s>' % (name, email)
def signoff(self): try: import pwd user = pwd.getpwuid(os.getuid()).pw_name except ImportError: user = os.getenv("USER", N_("unknown")) cfg = gitcfg.current() name = cfg.get("user.name", user) email = cfg.get("user.email", "%s@%s" % (user, core.node())) return "\nSigned-off-by: %s <%s>" % (name, email)