Modify

Ticket #272 (new enhancement)

Opened 6 years ago

Last modified 4 years ago

Figure out the email address from username + hostname

Reported by: anonymous Owned by: thomas
Priority: major Milestone:
Component: moap Version: TRUNK
Keywords: Cc:

Description

My copy of prepare-ChangeLog?.pl had code to determine the email address using the username and the hostname.

The perl version was:

((getlogin
getpwuid($<)) . "@" . hostname)

which correctly generates my email address. I do not like setting an email address in an environment variable when it can be figured out. A configuration option might be ok / more logical.

Attachments

Change History

comment:1 Changed 6 years ago by thomas

  • Milestone 0.2.6 deleted

Hm, I would think it's very rare for the username and hostname to actually match up with your email address.... I know it was different in the uni days, but figuring it out automatically today definately sounds wrong. Especially since then people will get this nonsensical email address in the usual case and won't know how to change it - at least now tye know.

I wouldn't be against being able to set it from a config file though, but so far I've not decided yet how to implement it. Any suggestions ?

comment:2 Changed 6 years ago by anonymous

Python has standard modules to parse config files. Just use $HOME/.moaprc (or something).

This with the syntax: email = 'foo@…'

Another possibility, perhaps to test the email address you could check if the hostname has a MX set?

comment:3 Changed 4 years ago by anonymous

My copy of prepare-ChangeLog??.pl had code to determine the email address using the username and the hostname.

The perl version was:

((getlogin getpwuid($<)) . "@" . hostname)

which correctly generates my email address. I do not like setting an email address in an environment variable when it can be figured out. A configuration option might be ok / more logical.

Hm, I would think it's very rare for the username and hostname to actually match up with your email address.... I know it was different in the uni days, but figuring it out automatically today definately sounds wrong. Especially since then people will get this nonsensical email address in the usual case and won't know how to change it - at least now tye know.

I wouldn't be against being able to set it from a config file though, but so far I've not decided yet how to implement it. Any suggestions ?

I'm closing it according to the last comment.
----------
 nike air yeezy

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as new
as The resolution will be set. Next status will be 'closed'
to The owner will be changed from thomas. Next status will be 'new'
The owner will be changed from thomas to anonymous. Next status will be 'assigned'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.