package Shell::EnvImporter::Result - Results of a Shell::EnvImporter run
use Shell::EnvImporter; my $sourcer = Shell::EnvImporter->new( command => $command, ) or die "$@"; my $result = $sourcer->result; if ($result->succeeded()) { print "Variables imported: ", join(", ", $result->imported), "\n"; } else { print "Command failed! with ", $result->command_status, " status\n"; print "STDERR: ", $result->stderr, "\n"; }
Shell::EnvImporter allows you to import environment variable changes exported by an external script or command into the current environment. The Shell::EnvImporter::Shell object provides more control over interaction with the shell.
Summary status. Returns true if any of the shell status, user command status, or 'env' command status are nonzero, and returns false otherwise.
Summary status. Returns true if the shell status, user command status, and 'env' command status are all zero, and returns false otherwise.
Status of the shell - zero if the shell was successfully spawned, nonzero otherwise.
Output produced by the shell when spawning (e.g. output from startup scripts).
Status of the user command.
Output produced by the user command.
Status of the 'env' command.
Standard error output produced by the shell, the user command, and/or the 'env' command.
List of variables imported by the shell.
David Faraldo, <dfaraldo@cpan.org>
Copyright (C) 2005-2006 by Dave Faraldo This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. No warranty is expressed or implied.
1 POD Error
The following errors were encountered while parsing the POD:
You forgot a '=back' before '=head1'
To install Shell::EnvImporter, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Shell::EnvImporter
CPAN shell
perl -MCPAN -e shell install Shell::EnvImporter
For more information on module installation, please visit the detailed CPAN module installation guide.