Support .netrc for github password/token
perlpunk opened this issue · 2 comments
perlpunk commented
People might want to store their github password and/or token in a netrc file.
This file is a good place to store all your passwords if you need them
to be read automatically.
netrc files can also be encrypted, if the netrc loader supports that.
For reading netrc there's already the perl core module Net::Netrc
machine github.com login gh-login password topsecret
machine api.github.com login gh-login password api-token
use Net::Netrc;
my $cred = Net::Netrc->lookup("api.github.com", $user);
my $token = $cred->password;dolmen commented
Yes, of course. That will be easier for malwares to find interesting credentials.