('blib/lib');
use Getopt::Long qw(:config no_ignore_case);
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator;
my $VERBOSITY = 0; # we
to dump current location." }
my $jsonstr = perl2json($geo);
if( ! defined $jsonstr ){ die perl2dump($geo)."$0 : failed to convert above Perl data structure to JSON." }
if( defined $OUTFILE ){
my $F
e "$0 : failed to open output file '$OUTFILE' for writing, $!";
print $FH $jsonstr;
close $FH;
} else { print STDOUT $jsonstr }
print STDOUT "$0 : done, success!".(defined($OUTFILE)?" Output writte
200 100
use 5.006;
use strict;
use warnings;
our $VERSION = '0.06';
use Mojo::Log;
use Config::JSON::Enhanced;
use File::Temp qw/tempfile/;
use Cwd;
use FindBin;
use Data::Roundtrip qw/perl2dump n
efined $ch ){ $log->error("${whoami} (via $parent), line ".__LINE__." : error, call to ".'Config::JSON::Enhanced::config2perl()'." has failed for configuration file '$infile'."); return undef }
# se
nfighash()'." has failed.\n"; return 1 }
} else {
# use default config
$confighash = Config::JSON::Enhanced::config2perl({
'string' => $_DEFAULT_CONFIG,
'commentstyle' => 'custom(</*)(*/>)'
('blib/lib');
use Getopt::Long qw(:config no_ignore_case);
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator;
my $VERBOSITY = 0; # we
('blib/lib');
use Getopt::Long qw(:config no_ignore_case);
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator;
my $VERBOSITY = 0; # we
sed and TO_JSON!
my $jsonstr = perl2json($apps, {terse=>1, pretty=>1, convert_blessed=>1});
if( ! defined $jsonstr ){ print STDERR "$0 : error, failed to convert perl data structure to JSON.\n"; exit
e "$0 : failed to open output file '$OUTFILE' for writing, $!";
print $FH $jsonstr;
close $FH;
} else { print STDOUT $jsonstr }
print STDOUT "$0 : done, success!".(defined($OUTFILE)?" Output writte
('blib/lib');
use Getopt::Long qw(:config no_ignore_case);
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator;
my $VERBOSITY = 0; # we
e, success!".(defined($OUTFILE)?" Output JSON written to file '$OUTFILE'.\n":"\n");
sub usage {
return "Usage $0 --configfile CONFIGFILE [--output procs.json] [--device DEVICE] [--verbosity v]\n"
l 'ps' output), optionally saving a JSON version of the parsed 'ps' output to file.\n"
. "\nExample:\n"
. "$0 --configfile config/myapp.conf --output procs.json\n"
. "\nProgram by Andreas Hadjip
('blib/lib');
use Getopt::Long qw(:config no_ignore_case);
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator;
my $VERBOSITY = 0; # we
200 100
use 5.006;
use strict;
use warnings;
our $VERSION = '0.06';
use Mojo::Log;
use Config::JSON::Enhanced;
# it requires v0.002 (which is with my modifications)
#use Android::ADB;
# issue filed
bXML;
use XML::LibXML::XPathContext;
use Text::ParseWords;
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator::DeviceProperties;
use And
running processes on device (using a `ps`),
# optionally can save the (parsed) `ps`
# results as JSON to the specified 'filename'.
# It needs that connect_device() to have been called prior to this c
200 100
use 5.006;
use strict;
use warnings;
our $VERSION = '0.04';
use Mojo::Log;
use Config::JSON::Enhanced;
use File::Temp qw/tempfile/;
use Cwd;
use FindBin;
use Data::Roundtrip qw/perl2dump n
efined $ch ){ $log->error("${whoami} (via $parent), line ".__LINE__." : error, call to ".'Config::JSON::Enhanced::config2perl()'." has failed for configuration file '$infile'."); return undef }
# se
nfighash()'." has failed.\n"; return 1 }
} else {
# use default config
$confighash = Config::JSON::Enhanced::config2perl({
'string' => $_DEFAULT_CONFIG,
'commentstyle' => 'custom(</*)(*/>)'
Layout;
use 5.006;
use strict;
use warnings;
our $VERSION = '0.06';
use Mojo::Log;
use Config::JSON::Enhanced;
use XML::XPath;
use XML::LibXML;
use Data::Roundtrip qw/perl2dump no-unicode-escape-p
return perl2dump($_[0]->{'data'}, {terse=>1,pretty=>1});
}
sub toJSON { return perl2json($_[0]->{'data'}, {pretty=>1}); }
sub TO_JSON { return $_[0]->{'data'} }
sub log { return $_[0]->{'_private'}-
erties;
use 5.006;
use strict;
use warnings;
our $VERSION = '0.06';
use Mojo::Log;
use Config::JSON::Enhanced;
use XML::XPath;
use XML::LibXML;
use Data::Roundtrip qw/perl2dump no-unicode-escape-p
return perl2dump($_[0]->{'data'}, {terse=>1,pretty=>1});
}
sub toJSON { return perl2json($_[0]->{'data'}, {pretty=>1}); }
sub TO_JSON { return $_[0]->{'data'} }
sub log { return $_[0]->{'_private'}-
erties;
use 5.006;
use strict;
use warnings;
our $VERSION = '0.06';
use Mojo::Log;
use Config::JSON::Enhanced;
use XML::XPath;
use XML::LibXML;
use Data::Roundtrip qw/perl2dump no-unicode-escape-p
? $v : '['.join(',', @$v).']')."\n";
# }
# return $ret;
}
sub toJSON { return perl2json($_[0]->{'data'}, {pretty=>1}); }
sub TO_JSON { return $_[0]->{'data'} }
sub log { return $_[0]->{'_private'}
('blib/lib');
use Getopt::Long qw(:config no_ignore_case);
use Data::Roundtrip qw/perl2dump perl2json no-unicode-escape-permanently/;
use Android::ElectricSheep::Automator;
my $VERBOSITY = 0; # we