Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Remove spurious newline from Mac command results #1

Merged
merged 2 commits into from

3 participants

@jonallen

No description provided.

@barbie barbie merged commit c86511e into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 25, 2011
  1. @JJ-OpusVL
  2. @JJ-OpusVL

    Bump version number

    JJ-OpusVL authored
This page is out of date. Refresh to see the latest.
View
3  Changes
@@ -1,6 +1,9 @@
Revision history for Perl library Devel-Platform-Info
=====================================================
+0.09 25/05/2011
+ - remove trailing newlines from Mac command results (JJ)
+
0.08 01/04/2011
- added Scientific Linux distro (as suggested by Norbert Gruener).
View
2  lib/Devel/Platform/Info.pm
@@ -4,7 +4,7 @@ use strict;
use warnings;
use vars qw($VERSION);
-$VERSION = '0.08';
+$VERSION = '0.09';
#----------------------------------------------------------------------------
View
6 lib/Devel/Platform/Info/Mac.pm
@@ -4,7 +4,7 @@ use strict;
use warnings;
use vars qw($VERSION);
-$VERSION = '0.08';
+$VERSION = '0.09';
#-------------------------------------------------------------------------------
@@ -21,7 +21,7 @@ sub new {
sub get_info {
my $self = shift;
$self->{info}{osname} = 'Mac';
- $self->{info}{osflag} = $^O;
+ $self->{info}{osflag} = $^O;
my $uname_s = $self->_command('uname -s');
if ($uname_s =~ /Darwin/i) {
@@ -62,10 +62,10 @@ sub _command {
my $self = shift;
my $command = shift;
my $result = `$command`;
+ chomp $result;
$self->{info}{source}{$command} = $result;
- chomp $result;
return $result;
}
Something went wrong with that request. Please try again.