Permalink
Browse files

use File::HomeDir

This will fix an issue on Windows 7. Bump version to 0.0.3
  • Loading branch information...
1 parent 4d38cc9 commit 35cf097f2c5d4b01cdf562eee38b4dbf33edf12a @FROGGS committed Jan 8, 2013
Showing with 15 additions and 10 deletions.
  1. +1 −0 Build.PL
  2. +3 −0 CHANGELOG
  3. +4 −3 META.json
  4. +4 −3 META.yml
  5. +2 −3 bin/bubble-breaker.pl
  6. +1 −1 lib/Games/BubbleBreaker.pm
View
@@ -9,6 +9,7 @@ my $build = Module::Build->new(
license => 'perl',
requires => {
'File::ShareDir' => '0',
+ 'File::HomeDir' => '0',
'File::Spec' => '0',
'Time::HiRes' => '0',
'SDL' => '2.532',
View
@@ -1,5 +1,8 @@
Revision history for Perl module Games::BubbleBreaker
+0.03 Tue Jan 08 2013
+ - use File::HomeDir (thanks to Mithaldu)
+
0.02 Fri Jun 24 2011
- better tests
View
@@ -4,7 +4,7 @@
"Tobias Leich <froggs@cpan.org>"
],
"dynamic_config" : 1,
- "generated_by" : "Module::Build version 0.38, CPAN::Meta::Converter version 2.110930",
+ "generated_by" : "Module::Build version 0.4001, CPAN::Meta::Converter version 2.110440",
"license" : [
"perl_5"
],
@@ -26,6 +26,7 @@
},
"runtime" : {
"requires" : {
+ "File::HomeDir" : 0,
"File::ShareDir" : "1.00",
"File::Spec" : 0,
"SDL" : "2.532",
@@ -36,7 +37,7 @@
"provides" : {
"Games::BubbleBreaker" : {
"file" : "lib/Games/BubbleBreaker.pm",
- "version" : "0.02"
+ "version" : "0.03"
}
},
"release_status" : "stable",
@@ -48,5 +49,5 @@
"url" : "http://github.com/FROGGS/Games-BubbleBreaker"
}
},
- "version" : "0.02"
+ "version" : "0.03"
}
View
@@ -7,7 +7,7 @@ build_requires:
configure_requires:
Module::Build: 0.38
dynamic_config: 1
-generated_by: 'Module::Build version 0.38, CPAN::Meta::Converter version 2.110930'
+generated_by: 'Module::Build version 0.4001, CPAN::Meta::Converter version 2.110440'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -16,13 +16,14 @@ name: Games-BubbleBreaker
provides:
Games::BubbleBreaker:
file: lib/Games/BubbleBreaker.pm
- version: 0.02
+ version: 0.03
requires:
+ File::HomeDir: 0
File::ShareDir: 1.00
File::Spec: 0
SDL: 2.532
Time::HiRes: 0
resources:
license: http://dev.perl.org/licenses/
repository: http://github.com/FROGGS/Games-BubbleBreaker
-version: 0.02
+version: 0.03
@@ -5,6 +5,7 @@
use Time::HiRes;
use File::ShareDir qw(dist_dir);
+use File::HomeDir;
use File::Spec::Functions qw(splitpath catpath catdir catfile);
use SDL;
@@ -43,9 +44,7 @@
depth => 32, title => "BubbleBreaker", color => 0x000000FF,
flags => SDL_SWSURFACE|SDL_DOUBLEBUF|SDL_NOFRAME,
init => 0, eoq => 1, delay => 20 );
-my $HOME = $^O eq 'MSWin32'
- ? catpath($ENV{HOMEDRIVE}, catdir($ENV{HOMEPATH}, '.bubble-breaker'))
- : "$ENV{HOME}/.bubble-breaker";
+my $HOME = File::HomeDir->my_home . "/.bubble-breaker";
mkdir($HOME) unless -d $HOME;
my ($v, $p, $f) = splitpath(__FILE__);
my $SHARE = -e catpath($v, catdir($p, '..', 'share'), 'background.png')
@@ -1,6 +1,6 @@
package Games::BubbleBreaker;
-our $VERSION = '0.02';
+our $VERSION = '0.03';
1;

0 comments on commit 35cf097

Please sign in to comment.