Last active
November 4, 2023 13:53
-
-
Save perforb/5030512 to your computer and use it in GitHub Desktop.
Easily import the settings in Perl.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+{ | |
mysql => { | |
user => 'volt', | |
password => 'voltisfast', | |
}, | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use strict; | |
use warnings; | |
use feature qw(say); | |
my $file = './development.pl'; | |
my $config = do $file or die "$!"; | |
say $config->{mysql}->{user}; | |
say $config->{mysql}->{password}; | |
__END__ | |
volt | |
voltisfast |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment