better discovery of localenv status

Squashed commit of the following:

commit 6ca234759e27bb7e9e598eaf468d4ea6a0043867
Author: Oliver Gorwits <oliver@cpan.org>
Date:   Tue Jun 11 13:38:19 2013 +0100

    version bump

commit c90ce039899b9a07e2ad833c753d0805e68d8bef
Author: Oliver Gorwits <oliver@cpan.org>
Date:   Tue Jun 11 13:29:11 2013 +0100

    better discovery of localenv status
This commit is contained in:
Oliver Gorwits
2013-06-11 18:10:54 +01:00
parent 3dd69c2063
commit 0bff56f729
7 changed files with 16 additions and 14 deletions

View File

@@ -1,3 +1,9 @@
2.008001 - 2013-06-11
[BUG FIXES]
* more fixes for localenv discovery in scripts
2.008000 - 2013-06-09
[BUG FIXES]

View File

@@ -60,4 +60,4 @@ resources:
homepage: http://netdisco.org/
license: http://opensource.org/licenses/bsd-license.php
repository: git://git.code.sf.net/p/netdisco/netdisco-ng
version: 2.008000
version: 2.008001

View File

@@ -6,11 +6,10 @@ use warnings FATAL => 'all';
our $home;
BEGIN {
# try really hard to find a localenv if one isn't already in place.
# try to find a localenv if one isn't already in place.
$home = ($ENV{NETDISCO_HOME} || $ENV{HOME});
eval "require App::Netdisco::Util::Noop";
if ($@) {
if (!exists $ENV{PERL_LOCAL_LIB_ROOT}) {
use File::Spec;
my $localenv = File::Spec->catfile($FindBin::RealBin, 'localenv');
exec($localenv, $0, @ARGV) if -f $localenv;

View File

@@ -5,9 +5,8 @@ our $home;
BEGIN {
# try really hard to find a localenv if one isn't already in place.
$home = ($ENV{NETDISCO_HOME} || $ENV{HOME});
eval "require App::Netdisco::Util::Noop";
if ($@) {
if (!exists $ENV{PERL_LOCAL_LIB_ROOT}) {
use File::Spec;
my $localenv = File::Spec->catfile($FindBin::RealBin, 'localenv');
exec($localenv, $0, @ARGV) if -f $localenv;

View File

@@ -3,11 +3,10 @@
our $home;
BEGIN {
# try really hard to find a localenv if one isn't already in place.
# try to find a localenv if one isn't already in place.
$home = ($ENV{NETDISCO_HOME} || $ENV{HOME});
eval "require App::Netdisco::Util::Noop";
if ($@) {
if (!exists $ENV{PERL_LOCAL_LIB_ROOT}) {
use File::Spec;
my $localenv = File::Spec->catfile($FindBin::RealBin, 'localenv');
exec($localenv, $0, @ARGV) if -f $localenv;
@@ -119,7 +118,7 @@ exit ($status eq 'done' ? 0 : 1);
=head1 NAME
netdisco-do - Run any Netdisco poller job from the command-line.
netdisco-do - Run any Netdisco job from the command-line.
=head1 USAGE

View File

@@ -6,11 +6,10 @@ use warnings FATAL => 'all';
our $home;
BEGIN {
# try really hard to find a localenv if one isn't already in place.
# try to find a localenv if one isn't already in place.
$home = ($ENV{NETDISCO_HOME} || $ENV{HOME});
eval "require App::Netdisco::Util::Noop";
if ($@) {
if (!exists $ENV{PERL_LOCAL_LIB_ROOT}) {
use File::Spec;
my $localenv = File::Spec->catfile($FindBin::RealBin, 'localenv');
exec($localenv, $0, @ARGV) if -f $localenv;

View File

@@ -7,7 +7,7 @@ use 5.010_000;
use File::ShareDir 'dist_dir';
use Path::Class;
our $VERSION = '2.008000';
our $VERSION = '2.008001';
BEGIN {
if (not length ($ENV{DANCER_APPDIR} || '')