As previously written, only the first address was found. The key is
that the Email::Address::XS library was misused previously. Based on
what is returned by Mail::Header->header_hashref(), it's clear that
we should use Email::Address::XS->parse_email_groups() first to
extract all addresses first.
While it may not be ideal here to rely on Perl's -T, since the
`man perlfunc` says that -T uses heuristic, and maybe the better
option would be to call `/usr/bin/file` and parse its output to see
if such conversion is needed, this solution should be close enough.
It turns out that File::Copy->move() does *not* follow POSIX mv's
semantics when doing `mv DIRECTORY_1 DIRECTORY_2`. It's quite clear
that it will do somethine like `mv DIRECTORY_1/* DIRECTORY_2`.
As such, while I'd prefer not to use the system-dependent rename()
Perl function here, that has the semantics I want.
In the process, error handling for the clals to move(), copy() and
make_path are improved. I thought autodie was catching these, but
it's not.
Since no privileged docs should go into the production, copy those
over to a completely different file hierarchy so when the production
is put into an archive file, those privileged documents are sure to
not be included.
The UTF-8 strings, when not decoded from the MIME header in the
'Subject' field, were making very long file names. Fix both the
UTF-8 strings to actually be decoded (which makes them shorter anyway
when processed here), but also set a 128 character limit on the
amount of the subject line of emails that go into the filenames.
Note that due to the fact that Git::Repository calls System::Command,
you have to be careful about when you install the child signal handler.
You only want it in the parent, after the parent has done its operations
with Git commands, and note that the child must also disable the handler.
* Process command line arguments more appropriately.
* Begin function to handle central commit solution.
* ProcessCommit a bit documented and additional argument.